You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Added default response to cancellation
* Added flag to stop ConcurrentModificationError when stopping ua
* update.
* Changed logger type to the parent class
* Added the ability to supply a custom logger.
Co-authored-by: Perondas <[email protected]>
Co-authored-by: Perondas <[email protected]>
Co-authored-by: cloudwebrtc <[email protected]>
Copy file name to clipboardExpand all lines: lib/src/digest_authentication.dart
+11-12Lines changed: 11 additions & 12 deletions
Original file line number
Diff line number
Diff line change
@@ -57,8 +57,7 @@ class DigestAuthentication {
57
57
return _ha1;
58
58
59
59
default:
60
-
logger
61
-
.error('get() | cannot get '+ parameter.toString() +' parameter');
60
+
logger.e('get() | cannot get '+ parameter.toString() +' parameter');
62
61
63
62
returnnull;
64
63
}
@@ -79,7 +78,7 @@ class DigestAuthentication {
79
78
80
79
if (_algorithm !=null) {
81
80
if (_algorithm !='MD5') {
82
-
logger.error(
81
+
logger.e(
83
82
'authenticate() | challenge with Digest algorithm different than "MD5", authentication aborted');
84
83
85
84
returnfalse;
@@ -89,14 +88,14 @@ class DigestAuthentication {
89
88
}
90
89
91
90
if (_nonce ==null) {
92
-
logger.error(
91
+
logger.e(
93
92
'authenticate() | challenge without Digest nonce, authentication aborted');
94
93
95
94
returnfalse;
96
95
}
97
96
98
97
if (_realm ==null) {
99
-
logger.error(
98
+
logger.e(
100
99
'authenticate() | challenge without Digest realm, authentication aborted');
101
100
102
101
returnfalse;
@@ -106,15 +105,15 @@ class DigestAuthentication {
106
105
if (_credentials.password ==null) {
107
106
// If ha1 is not provided we cannot authenticate.
108
107
if (_credentials.ha1 ==null) {
109
-
logger.error(
108
+
logger.e(
110
109
'authenticate() | no plain SIP password nor ha1 provided, authentication aborted');
111
110
112
111
returnfalse;
113
112
}
114
113
115
114
// If the realm does not match the stored realm we cannot authenticate.
116
115
if (_credentials.realm != _realm) {
117
-
logger.error(
116
+
logger.e(
118
117
'authenticate() | no plain SIP password, and stored "realm" does not match the given "realm", cannot authenticate [stored:"${_credentials.realm}", given:"$_realm"]');
119
118
120
119
returnfalse;
@@ -129,7 +128,7 @@ class DigestAuthentication {
129
128
_qop ='auth';
130
129
} else {
131
130
// Otherwise 'qop' is present but does not contain 'auth' or 'auth-int', so abort here.
132
-
logger.error(
131
+
logger.e(
133
132
'authenticate() | challenge without Digest qop different than "auth" or "auth-int", authentication aborted');
134
133
135
134
returnfalse;
@@ -175,7 +174,7 @@ class DigestAuthentication {
175
174
a2 ='${SipMethodHelper.getName(_method)}:$_uri';
176
175
ha2 = utils.calculateMD5(a2);
177
176
178
-
logger.debug('authenticate() | using qop=auth [a2:$a2]');
177
+
logger.d('authenticate() | using qop=auth [a2:$a2]');
0 commit comments