LdapFluff::FreeIPA::MemberService

handles the naughty bits of posix ldap

Public Class Methods

new(ldap, config) click to toggle source
# File lib/ldap_fluff/freeipa_member_service.rb, line 6
def initialize(ldap, config)
  @attr_login = (config.attr_login || 'uid')
  super
end

Public Instance Methods

find_user_groups(uid) click to toggle source

return an ldap user with groups attached note : this method is not particularly fast for large ldap systems

# File lib/ldap_fluff/freeipa_member_service.rb, line 13
def find_user_groups(uid)
  user = find_user(uid)
  # if group data is missing, they aren't querying with a user
  # with enough privileges
  raise InsufficientQueryPrivilegesException if user.size <= 1
  get_groups(user[1][:memberof])
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.