File tree 2 files changed +3
-2
lines changed
2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -4,6 +4,8 @@ module Net
4
4
class LDAP
5
5
class AuthAdapter
6
6
class Sasl < Net ::LDAP ::AuthAdapter
7
+ MAX_SASL_CHALLENGES = 10
8
+
7
9
#--
8
10
# Required parameters: :mechanism, :initial_credential and
9
11
# :challenge_response
@@ -47,7 +49,7 @@ def bind(auth)
47
49
end
48
50
49
51
return pdu unless pdu . result_code == Net ::LDAP ::ResultCodeSaslBindInProgress
50
- raise Net ::LDAP ::SASLChallengeOverflowError , "sasl-challenge overflow" if ( ( n += 1 ) > MaxSaslChallenges )
52
+ raise Net ::LDAP ::SASLChallengeOverflowError , "sasl-challenge overflow" if ( ( n += 1 ) > MAX_SASL_CHALLENGES )
51
53
52
54
cred = chall . call ( pdu . result_server_sasl_creds )
53
55
end
Original file line number Diff line number Diff line change @@ -7,7 +7,6 @@ class Net::LDAP::Connection #:nodoc:
7
7
DefaultConnectTimeout = 5
8
8
9
9
LdapVersion = 3
10
- MaxSaslChallenges = 10
11
10
12
11
# Initialize a connection to an LDAP server
13
12
#
You can’t perform that action at this time.
0 commit comments