# File lib/puppet/util/ldap/manager.rb, line 87 87: def entry2provider(entry) 88: raise ArgumentError, "Could not get dn from ldap entry" unless entry["dn"] 89: 90: # DN is always a single-entry array. Strip off the bits before the 91: # first comma, then the bits after the remaining equal sign. This is the 92: # name. 93: name = entry["dn"].dup.pop.split(",").shift.split("=").pop 94: 95: result = {:name => name} 96: 97: @ldap2puppet.each do |ldap, puppet| 98: result[puppet] = entry[ldap.to_s] || :absent 99: end 100: 101: result 102: end