wrap net_ldap_extensions in a zeitwerk compatible module
closes FOO-2448 flag=none invoke module at consumption point TEST PLAN: 1) all specs still pass Change-Id: I2356f70c119dfb78d8a874a2ed21f4c5e9bac60d Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/275414 Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com> Reviewed-by: Cody Cutrer <cody@instructure.com> QA-Review: Ethan Vizitei <evizitei@instructure.com> Product-Review: Ethan Vizitei <evizitei@instructure.com>
This commit is contained in:
parent
7bb64cc73f
commit
556831d8e3
|
@ -20,6 +20,7 @@
|
|||
|
||||
require 'net-ldap'
|
||||
require 'net_ldap_extensions'
|
||||
NetLdapExtensions.apply
|
||||
|
||||
class AuthenticationProvider < ActiveRecord::Base
|
||||
include Workflow
|
||||
|
|
|
@ -17,56 +17,60 @@
|
|||
# You should have received a copy of the GNU Affero General Public License along
|
||||
# with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
Net::LDAP::ResultStrings.merge!({
|
||||
0 => "Success Hi",
|
||||
1 => "Operation Error",
|
||||
2 => "Protocol Error",
|
||||
3 => "Time Limit Exceeded",
|
||||
4 => "Size Limit Exceeded",
|
||||
5 => "Compare False",
|
||||
6 => "Compare True",
|
||||
7 => "Auth Method Not Supported",
|
||||
8 => "Strong Auth Required",
|
||||
9 => "Ldap Partial Results",
|
||||
10 => "Referral (ldap V3)",
|
||||
11 => "Admin Limit Exceeded (ldap V3)",
|
||||
12 => "Unavailable Critical Extension (ldap V3)",
|
||||
13 => "Confidentiality Required (ldap V3)",
|
||||
14 => "Sasl Bind In Progress",
|
||||
16 => "No Such Attribute",
|
||||
17 => "Undefined Attribute Type",
|
||||
18 => "Inappropriate Matching",
|
||||
19 => "Constraint Violation",
|
||||
20 => "Attribute Or Value Exists",
|
||||
21 => "Invalid Attribute Syntax",
|
||||
32 => "No Such Object",
|
||||
33 => "Alias Problem",
|
||||
34 => "Invalid Dn Syntax",
|
||||
35 => "Is Leaf",
|
||||
36 => "Alias Dereferencing Problem",
|
||||
48 => "Inappropriate Authentication",
|
||||
49 => "Invalid Credentials",
|
||||
50 => "Insufficient Access Rights",
|
||||
51 => "Busy",
|
||||
52 => "Unavailable",
|
||||
53 => "Unwilling To Perform",
|
||||
54 => "Loop Defect",
|
||||
64 => "Naming Violation",
|
||||
65 => "Object Class Violation",
|
||||
66 => "Not Allowed On Nonleaf",
|
||||
67 => "Not Allowed On Rdn",
|
||||
68 => "Entry Already Exists",
|
||||
69 => "Object Class Mods Prohibited",
|
||||
71 => "Affects Multiple Dsas (ldap V3)",
|
||||
80 => "Other",
|
||||
81 => "Server Down",
|
||||
85 => "Ldap Timeout",
|
||||
89 => "Param Error",
|
||||
91 => "Connect Error",
|
||||
92 => "Ldap Not Supported",
|
||||
93 => "Control Not Found",
|
||||
94 => "No Results Returned",
|
||||
95 => "More Results To Return",
|
||||
96 => "Client Loop",
|
||||
97 => "Referral Limit Exceeded",
|
||||
})
|
||||
module NetLdapExtensions
|
||||
def self.apply
|
||||
Net::LDAP::ResultStrings.merge!({
|
||||
0 => "Success Hi",
|
||||
1 => "Operation Error",
|
||||
2 => "Protocol Error",
|
||||
3 => "Time Limit Exceeded",
|
||||
4 => "Size Limit Exceeded",
|
||||
5 => "Compare False",
|
||||
6 => "Compare True",
|
||||
7 => "Auth Method Not Supported",
|
||||
8 => "Strong Auth Required",
|
||||
9 => "Ldap Partial Results",
|
||||
10 => "Referral (ldap V3)",
|
||||
11 => "Admin Limit Exceeded (ldap V3)",
|
||||
12 => "Unavailable Critical Extension (ldap V3)",
|
||||
13 => "Confidentiality Required (ldap V3)",
|
||||
14 => "Sasl Bind In Progress",
|
||||
16 => "No Such Attribute",
|
||||
17 => "Undefined Attribute Type",
|
||||
18 => "Inappropriate Matching",
|
||||
19 => "Constraint Violation",
|
||||
20 => "Attribute Or Value Exists",
|
||||
21 => "Invalid Attribute Syntax",
|
||||
32 => "No Such Object",
|
||||
33 => "Alias Problem",
|
||||
34 => "Invalid Dn Syntax",
|
||||
35 => "Is Leaf",
|
||||
36 => "Alias Dereferencing Problem",
|
||||
48 => "Inappropriate Authentication",
|
||||
49 => "Invalid Credentials",
|
||||
50 => "Insufficient Access Rights",
|
||||
51 => "Busy",
|
||||
52 => "Unavailable",
|
||||
53 => "Unwilling To Perform",
|
||||
54 => "Loop Defect",
|
||||
64 => "Naming Violation",
|
||||
65 => "Object Class Violation",
|
||||
66 => "Not Allowed On Nonleaf",
|
||||
67 => "Not Allowed On Rdn",
|
||||
68 => "Entry Already Exists",
|
||||
69 => "Object Class Mods Prohibited",
|
||||
71 => "Affects Multiple Dsas (ldap V3)",
|
||||
80 => "Other",
|
||||
81 => "Server Down",
|
||||
85 => "Ldap Timeout",
|
||||
89 => "Param Error",
|
||||
91 => "Connect Error",
|
||||
92 => "Ldap Not Supported",
|
||||
93 => "Control Not Found",
|
||||
94 => "No Results Returned",
|
||||
95 => "More Results To Return",
|
||||
96 => "Client Loop",
|
||||
97 => "Referral Limit Exceeded",
|
||||
})
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue