Project

General

Profile

« Previous | Next » 

Revision 6d235fb6

Added by Marc Dequènes about 14 years ago

  • ID 6d235fb6a566acaa0da7fc1704f820be1d02ecc1

[fix] ensure DNs outside the current base DN are handled properly

View differences:

lib/ldap_shadows.rb
require 'ldap_shadows/lang_additions'
require 'ldap_shadows/exceptions'
require 'ldap_shadows/config'
require 'ldap_shadows/shadow'
require 'gettext'
require 'pp'
lib/ldap_shadows/config.rb
#++
require 'ldap_shadows/config_setup'
require 'ldap_shadows/shadow'
require 'singleton'
require 'yaml'
require 'kwalify'
......
@world_config
end
# needs 'ldap_shadows/shadow' for this feature to work
def load_shadow(shadow_name = nil)
shadow_name = self.world_config[:default_shadow] if shadow_name.nil?
if shadow_name.nil?
lib/ldap_shadows/elements/object.rb
Hash[rel_data.compact]
end
end
class ExternalLdapObject < ActiveLdap::Base
self.base = ''
end
end
end
lib/ldap_shadows/manipulation_helper.rb
def self.interpret_field_value(shadow, syntax, val)
case syntax
when "1.3.6.1.4.1.1466.115.121.1.12"
raw_item = ActiveLdap::Base.find(:first, :base => val, :scope => :base)
raw_item = Elements::ExternalLdapObject.find(:first, :base => val, :scope => :base)
LdapShadows::Manipulation.raw_item_info(shadow, raw_item, val.to_s)[:name]
else
val

Also available in: Unified diff