Sha256: a6529fe7055d98816fa32eb236a8f0ef0e7c15d2b674242331d9259d22d342f1

Contents?: true

Size: 625 Bytes

Versions: 8

Compression:

Stored size: 625 Bytes

Contents

module GitHub
  class Ldap
    class VirtualGroup < Group
      def members
        @ldap.search(filter: members_of_group(@entry.dn, membership_attribute))
      end

      def subgroups
        @ldap.search(filter: subgroups_of_group(@entry.dn, membership_attribute))
      end

      def is_member(user_dn)
        @ldap.search(filter: is_member_of_group(user_dn, @entry.dn, membership_attribute))
      end

      # Internal - Get the attribute to use for membership filtering.
      #
      # Returns a string.
      def membership_attribute
        @ldap.virual_attributes.virtual_membership
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
github-ldap-1.2.1 lib/github/ldap/virtual_group.rb
github-ldap-1.2.0 lib/github/ldap/virtual_group.rb
github-ldap-1.1.5 lib/github/ldap/virtual_group.rb
github-ldap-1.1.4 lib/github/ldap/virtual_group.rb
github-ldap-1.1.3 lib/github/ldap/virtual_group.rb
github-ldap-1.1.2 lib/github/ldap/virtual_group.rb
github-ldap-1.1.1 lib/github/ldap/virtual_group.rb
github-ldap-1.1.0 lib/github/ldap/virtual_group.rb