Class: Net::LDAP

Inherits:
Object
  • Object
show all
Defined in:
lib/rex/proto/ldap.rb

Overview

Update Net::LDAP’s initialize and new_connection method to honor a tracking proxies setting

Direct Known Subclasses

Rex::Proto::LDAP::Client

Constant Summary collapse

WhoamiOid =
'1.3.6.1.4.1.4203.1.11.3'.freeze

Instance Method Summary collapse

Constructor Details

#initialize(args = {}) ⇒ LDAP

Original Source: github.com/ruby-ldap/ruby-net-ldap/blob/95cec3822cd2f60787971e19714f74fd5999595c/lib/net/ldap.rb#L548 Additionally tracks proxies configuration, used when making a new_connection



23
24
25
26
# File 'lib/rex/proto/ldap.rb', line 23

def initialize(args = {})
  _old_initialize(args)
  @proxies = args[:proxies]
end

Instance Method Details

#_old_initializeObject

Reference the old initialize method, and ensure ‘reload_lib -a` doesn’t attempt to refine the method



18
# File 'lib/rex/proto/ldap.rb', line 18

alias_method :_old_initialize, :initialize