first version of ldap server role
This commit is contained in:
parent
2804d730c9
commit
89aa8eb0ef
11 changed files with 2008 additions and 0 deletions
3
roles/ldap/server/defaults/main.yml
Normal file
3
roles/ldap/server/defaults/main.yml
Normal file
|
@ -0,0 +1,3 @@
|
|||
---
|
||||
ldap_server_cert: "{% if ldap_master is defined %}ldap01.foo.sh{% else %}\
|
||||
ldap.foo.sh{% endif %}"
|
8
roles/ldap/server/files/check_password.conf
Normal file
8
roles/ldap/server/files/check_password.conf
Normal file
|
@ -0,0 +1,8 @@
|
|||
# OpenLDAP pwdChecker library configuration
|
||||
|
||||
useCracklib 1
|
||||
minPoints 2
|
||||
minUpper 0
|
||||
minLower 2
|
||||
minDigit 2
|
||||
minPunct 0
|
726
roles/ldap/server/files/kerberos.schema
Normal file
726
roles/ldap/server/files/kerberos.schema
Normal file
|
@ -0,0 +1,726 @@
|
|||
# Novell Kerberos Schema Definitions
|
||||
# Novell Inc.
|
||||
# 1800 South Novell Place
|
||||
# Provo, UT 84606
|
||||
#
|
||||
# VeRsIoN=1.0
|
||||
# CoPyRiGhT=(c) Copyright 2006, Novell, Inc. All rights reserved
|
||||
#
|
||||
# OIDs:
|
||||
# joint-iso-ccitt(2)
|
||||
# country(16)
|
||||
# us(840)
|
||||
# organization(1)
|
||||
# Novell(113719)
|
||||
# applications(1)
|
||||
# kerberos(301)
|
||||
# Kerberos Attribute Type(4) attr# version#
|
||||
# specific attribute definitions
|
||||
# Kerberos Attribute Syntax(5)
|
||||
# specific syntax definitions
|
||||
# Kerberos Object Class(6) class# version#
|
||||
# specific class definitions
|
||||
#
|
||||
# iso(1)
|
||||
# member-body(2)
|
||||
# United States(840)
|
||||
# mit (113554)
|
||||
# infosys(1)
|
||||
# ldap(4)
|
||||
# attributeTypes(1)
|
||||
# Kerberos(6)
|
||||
|
||||
########################################################################
|
||||
|
||||
|
||||
########################################################################
|
||||
# Attribute Type Definitions #
|
||||
########################################################################
|
||||
|
||||
##### This is the principal name in the RFC 1964 specified format
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.1.1
|
||||
NAME 'krbPrincipalName'
|
||||
EQUALITY caseExactIA5Match
|
||||
SUBSTR caseExactSubstringsMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26)
|
||||
|
||||
##### If there are multiple krbPrincipalName values for an entry, this
|
||||
##### is the canonical principal name in the RFC 1964 specified
|
||||
##### format. (If this attribute does not exist, then all
|
||||
##### krbPrincipalName values are treated as canonical.)
|
||||
|
||||
attributetype ( 1.2.840.113554.1.4.1.6.1
|
||||
NAME 'krbCanonicalName'
|
||||
EQUALITY caseExactIA5Match
|
||||
SUBSTR caseExactSubstringsMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26
|
||||
SINGLE-VALUE)
|
||||
|
||||
##### This specifies the type of the principal, the types could be any of
|
||||
##### the types mentioned in section 6.2 of RFC 4120
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.3.1
|
||||
NAME 'krbPrincipalType'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### This flag is used to find whether directory User Password has to be used
|
||||
##### as kerberos password.
|
||||
##### TRUE, if User Password is to be used as the kerberos password.
|
||||
##### FALSE, if User Password and the kerberos password are different.
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.5.1
|
||||
NAME 'krbUPEnabled'
|
||||
DESC 'Boolean'
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.7
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### The time at which the principal expires
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.6.1
|
||||
NAME 'krbPrincipalExpiration'
|
||||
EQUALITY generalizedTimeMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.24
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### The krbTicketFlags attribute holds information about the kerberos flags for a principal
|
||||
##### The values (0x00000001 - 0x00800000) are reserved for standards and
|
||||
##### values (0x01000000 - 0x80000000) can be used for proprietary extensions.
|
||||
##### The flags and values as per RFC 4120 and MIT implementation are,
|
||||
##### DISALLOW_POSTDATED 0x00000001
|
||||
##### DISALLOW_FORWARDABLE 0x00000002
|
||||
##### DISALLOW_TGT_BASED 0x00000004
|
||||
##### DISALLOW_RENEWABLE 0x00000008
|
||||
##### DISALLOW_PROXIABLE 0x00000010
|
||||
##### DISALLOW_DUP_SKEY 0x00000020
|
||||
##### DISALLOW_ALL_TIX 0x00000040
|
||||
##### REQUIRES_PRE_AUTH 0x00000080
|
||||
##### REQUIRES_HW_AUTH 0x00000100
|
||||
##### REQUIRES_PWCHANGE 0x00000200
|
||||
##### DISALLOW_SVR 0x00001000
|
||||
##### PWCHANGE_SERVICE 0x00002000
|
||||
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.8.1
|
||||
NAME 'krbTicketFlags'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### The maximum ticket lifetime for a principal in seconds
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.9.1
|
||||
NAME 'krbMaxTicketLife'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### Maximum renewable lifetime for a principal's ticket in seconds
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.10.1
|
||||
NAME 'krbMaxRenewableAge'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### Forward reference to the Realm object.
|
||||
##### (FDN of the krbRealmContainer object).
|
||||
##### Example: cn=ACME.COM, cn=Kerberos, cn=Security
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.14.1
|
||||
NAME 'krbRealmReferences'
|
||||
EQUALITY distinguishedNameMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.12)
|
||||
|
||||
|
||||
##### List of LDAP servers that kerberos servers can contact.
|
||||
##### The attribute holds data in the ldap uri format,
|
||||
##### Examples: acme.com#636, 164.164.164.164#1636, ldaps://acme.com:636
|
||||
#####
|
||||
##### The values of this attribute need to be updated, when
|
||||
##### the LDAP servers listed here are renamed, moved or deleted.
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.15.1
|
||||
NAME 'krbLdapServers'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
|
||||
|
||||
|
||||
##### A set of forward references to the KDC Service objects.
|
||||
##### (FDNs of the krbKdcService objects).
|
||||
##### Example: cn=kdc - server 1, ou=uvw, o=xyz
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.17.1
|
||||
NAME 'krbKdcServers'
|
||||
EQUALITY distinguishedNameMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.12)
|
||||
|
||||
|
||||
##### A set of forward references to the Password Service objects.
|
||||
##### (FDNs of the krbPwdService objects).
|
||||
##### Example: cn=kpasswdd - server 1, ou=uvw, o=xyz
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.18.1
|
||||
NAME 'krbPwdServers'
|
||||
EQUALITY distinguishedNameMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.12)
|
||||
|
||||
|
||||
##### This attribute holds the Host Name or the ip address,
|
||||
##### transport protocol and ports of the kerberos service host
|
||||
##### The format is host_name-or-ip_address#protocol#port
|
||||
##### Protocol can be 0 or 1. 0 is for UDP. 1 is for TCP.
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.24.1
|
||||
NAME 'krbHostServer'
|
||||
EQUALITY caseExactIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26)
|
||||
|
||||
|
||||
##### This attribute holds the scope for searching the principals
|
||||
##### under krbSubTree attribute of krbRealmContainer
|
||||
##### The value can either be 1 (ONE) or 2 (SUB_TREE).
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.25.1
|
||||
NAME 'krbSearchScope'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### FDNs pointing to Kerberos principals
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.26.1
|
||||
NAME 'krbPrincipalReferences'
|
||||
EQUALITY distinguishedNameMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.12)
|
||||
|
||||
|
||||
##### This attribute specifies which attribute of the user objects
|
||||
##### be used as the principal name component for Kerberos.
|
||||
##### The allowed values are cn, sn, uid, givenname, fullname.
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.28.1
|
||||
NAME 'krbPrincNamingAttr'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### A set of forward references to the Administration Service objects.
|
||||
##### (FDNs of the krbAdmService objects).
|
||||
##### Example: cn=kadmindd - server 1, ou=uvw, o=xyz
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.29.1
|
||||
NAME 'krbAdmServers'
|
||||
EQUALITY distinguishedNameMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.12)
|
||||
|
||||
|
||||
##### Maximum lifetime of a principal's password
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.30.1
|
||||
NAME 'krbMaxPwdLife'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### Minimum lifetime of a principal's password
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.31.1
|
||||
NAME 'krbMinPwdLife'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### Minimum number of character clases allowed in a password
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.32.1
|
||||
NAME 'krbPwdMinDiffChars'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### Minimum length of the password
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.33.1
|
||||
NAME 'krbPwdMinLength'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### Number of previous versions of passwords that are stored
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.34.1
|
||||
NAME 'krbPwdHistoryLength'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### Number of consecutive pre-authentication failures before lockout
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.5322.21.2.1
|
||||
NAME 'krbPwdMaxFailure'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### Period after which bad preauthentication count will be reset
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.5322.21.2.2
|
||||
NAME 'krbPwdFailureCountInterval'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### Period in which lockout is enforced
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.5322.21.2.3
|
||||
NAME 'krbPwdLockoutDuration'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### Policy attribute flags
|
||||
|
||||
attributetype ( 1.2.840.113554.1.4.1.6.2
|
||||
NAME 'krbPwdAttributes'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### Policy maximum ticket lifetime
|
||||
|
||||
attributetype ( 1.2.840.113554.1.4.1.6.3
|
||||
NAME 'krbPwdMaxLife'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### Policy maximum ticket renewable lifetime
|
||||
|
||||
attributetype ( 1.2.840.113554.1.4.1.6.4
|
||||
NAME 'krbPwdMaxRenewableLife'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### Allowed enctype:salttype combinations for key changes
|
||||
|
||||
attributetype ( 1.2.840.113554.1.4.1.6.5
|
||||
NAME 'krbPwdAllowedKeysalts'
|
||||
EQUALITY caseIgnoreIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### FDN pointing to a Kerberos Password Policy object
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.36.1
|
||||
NAME 'krbPwdPolicyReference'
|
||||
EQUALITY distinguishedNameMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.12
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### The time at which the principal's password expires
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.37.1
|
||||
NAME 'krbPasswordExpiration'
|
||||
EQUALITY generalizedTimeMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.24
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### This attribute holds the principal's key (krbPrincipalKey) that is encrypted with
|
||||
##### the master key (krbMKey).
|
||||
##### The attribute is ASN.1 encoded.
|
||||
#####
|
||||
##### The format of the value for this attribute is explained below,
|
||||
##### KrbKeySet ::= SEQUENCE {
|
||||
##### attribute-major-vno [0] UInt16,
|
||||
##### attribute-minor-vno [1] UInt16,
|
||||
##### kvno [2] UInt32,
|
||||
##### mkvno [3] UInt32 OPTIONAL,
|
||||
##### keys [4] SEQUENCE OF KrbKey,
|
||||
##### ...
|
||||
##### }
|
||||
#####
|
||||
##### KrbKey ::= SEQUENCE {
|
||||
##### salt [0] KrbSalt OPTIONAL,
|
||||
##### key [1] EncryptionKey,
|
||||
##### s2kparams [2] OCTET STRING OPTIONAL,
|
||||
##### ...
|
||||
##### }
|
||||
#####
|
||||
##### KrbSalt ::= SEQUENCE {
|
||||
##### type [0] Int32,
|
||||
##### salt [1] OCTET STRING OPTIONAL
|
||||
##### }
|
||||
#####
|
||||
##### EncryptionKey ::= SEQUENCE {
|
||||
##### keytype [0] Int32,
|
||||
##### keyvalue [1] OCTET STRING
|
||||
##### }
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.39.1
|
||||
NAME 'krbPrincipalKey'
|
||||
EQUALITY octetStringMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.40)
|
||||
|
||||
|
||||
##### FDN pointing to a Kerberos Ticket Policy object.
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.40.1
|
||||
NAME 'krbTicketPolicyReference'
|
||||
EQUALITY distinguishedNameMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.12
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### Forward reference to an entry that starts sub-trees
|
||||
##### where principals and other kerberos objects in the realm are configured.
|
||||
##### Example: ou=acme, ou=pq, o=xyz
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.41.1
|
||||
NAME 'krbSubTrees'
|
||||
EQUALITY distinguishedNameMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.12)
|
||||
|
||||
|
||||
##### Holds the default encryption/salt type combinations of principals for
|
||||
##### the Realm. Stores in the form of key:salt strings. This will be
|
||||
##### subset of the supported encryption/salt types.
|
||||
##### Example: des-cbc-crc:normal
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.42.1
|
||||
NAME 'krbDefaultEncSaltTypes'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
|
||||
|
||||
|
||||
##### Holds the supported encryption/salt type combinations of principals for
|
||||
##### the Realm. Stores in the form of key:salt strings.
|
||||
##### The supported encryption types are mentioned in RFC 3961
|
||||
##### The supported salt types are,
|
||||
##### NORMAL
|
||||
##### V4
|
||||
##### NOREALM
|
||||
##### ONLYREALM
|
||||
##### SPECIAL
|
||||
##### AFS3
|
||||
##### Example: des-cbc-crc:normal
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.43.1
|
||||
NAME 'krbSupportedEncSaltTypes'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
|
||||
|
||||
|
||||
##### This attribute holds the principal's old keys (krbPwdHistory) that is encrypted with
|
||||
##### the kadmin/history key.
|
||||
##### The attribute is ASN.1 encoded.
|
||||
#####
|
||||
##### The format of the value for this attribute is explained below,
|
||||
##### KrbKeySet ::= SEQUENCE {
|
||||
##### attribute-major-vno [0] UInt16,
|
||||
##### attribute-minor-vno [1] UInt16,
|
||||
##### kvno [2] UInt32,
|
||||
##### mkvno [3] UInt32 OPTIONAL -- actually kadmin/history key,
|
||||
##### keys [4] SEQUENCE OF KrbKey,
|
||||
##### ...
|
||||
##### }
|
||||
#####
|
||||
##### KrbKey ::= SEQUENCE {
|
||||
##### salt [0] KrbSalt OPTIONAL,
|
||||
##### key [1] EncryptionKey,
|
||||
##### s2kparams [2] OCTET STRING OPTIONAL,
|
||||
##### ...
|
||||
##### }
|
||||
#####
|
||||
##### KrbSalt ::= SEQUENCE {
|
||||
##### type [0] Int32,
|
||||
##### salt [1] OCTET STRING OPTIONAL
|
||||
##### }
|
||||
#####
|
||||
##### EncryptionKey ::= SEQUENCE {
|
||||
##### keytype [0] Int32,
|
||||
##### keyvalue [1] OCTET STRING
|
||||
##### }
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.44.1
|
||||
NAME 'krbPwdHistory'
|
||||
EQUALITY octetStringMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.40)
|
||||
|
||||
|
||||
##### The time at which the principal's password last password change happened.
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.45.1
|
||||
NAME 'krbLastPwdChange'
|
||||
EQUALITY generalizedTimeMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.24
|
||||
SINGLE-VALUE)
|
||||
|
||||
##### The time at which the principal was last administratively unlocked.
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.5322.21.2.5
|
||||
NAME 'krbLastAdminUnlock'
|
||||
EQUALITY generalizedTimeMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.24
|
||||
SINGLE-VALUE)
|
||||
|
||||
##### This attribute holds the kerberos master key.
|
||||
##### This can be used to encrypt principal keys.
|
||||
##### This attribute has to be secured in directory.
|
||||
#####
|
||||
##### This attribute is ASN.1 encoded.
|
||||
##### The format of the value for this attribute is explained below,
|
||||
##### KrbMKey ::= SEQUENCE {
|
||||
##### kvno [0] UInt32,
|
||||
##### key [1] MasterKey
|
||||
##### }
|
||||
#####
|
||||
##### MasterKey ::= SEQUENCE {
|
||||
##### keytype [0] Int32,
|
||||
##### keyvalue [1] OCTET STRING
|
||||
##### }
|
||||
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.46.1
|
||||
NAME 'krbMKey'
|
||||
EQUALITY octetStringMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.40)
|
||||
|
||||
|
||||
##### This stores the alternate principal names for the principal in the RFC 1964 specified format
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.47.1
|
||||
NAME 'krbPrincipalAliases'
|
||||
EQUALITY caseExactIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26)
|
||||
|
||||
|
||||
##### The time at which the principal's last successful authentication happened.
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.48.1
|
||||
NAME 'krbLastSuccessfulAuth'
|
||||
EQUALITY generalizedTimeMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.24
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### The time at which the principal's last failed authentication happened.
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.49.1
|
||||
NAME 'krbLastFailedAuth'
|
||||
EQUALITY generalizedTimeMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.24
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
##### This attribute stores the number of failed authentication attempts
|
||||
##### happened for the principal since the last successful authentication.
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.50.1
|
||||
NAME 'krbLoginFailedCount'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE)
|
||||
|
||||
|
||||
|
||||
##### This attribute holds the application specific data.
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.51.1
|
||||
NAME 'krbExtraData'
|
||||
EQUALITY octetStringMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.40)
|
||||
|
||||
|
||||
##### This attributes holds references to the set of directory objects.
|
||||
##### This stores the DNs of the directory objects to which the
|
||||
##### principal object belongs to.
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.52.1
|
||||
NAME 'krbObjectReferences'
|
||||
EQUALITY distinguishedNameMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.12)
|
||||
|
||||
|
||||
##### This attribute holds references to a Container object where
|
||||
##### the additional principal objects and stand alone principal
|
||||
##### objects (krbPrincipal) can be created.
|
||||
|
||||
attributetype ( 2.16.840.1.113719.1.301.4.53.1
|
||||
NAME 'krbPrincContainerRef'
|
||||
EQUALITY distinguishedNameMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.12)
|
||||
|
||||
|
||||
##### A list of authentication indicator strings, one of which must be satisfied
|
||||
##### to authenticate to the principal as a service.
|
||||
##### FreeIPA OID:
|
||||
##### joint-iso-ccitt(3) country(16) us(840) organization(1) netscape(113730)
|
||||
##### ldap(3) freeipa(8) krb5(15) attributes(2)
|
||||
attributetype ( 2.16.840.1.113730.3.8.15.2.1
|
||||
NAME 'krbPrincipalAuthInd'
|
||||
EQUALITY caseExactMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15)
|
||||
|
||||
|
||||
##### A list of services to which a service principal can delegate.
|
||||
attributetype ( 1.3.6.1.4.1.5322.21.2.4
|
||||
NAME 'krbAllowedToDelegateTo'
|
||||
EQUALITY caseExactIA5Match
|
||||
SUBSTR caseExactSubstringsMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26)
|
||||
|
||||
########################################################################
|
||||
########################################################################
|
||||
# Object Class Definitions #
|
||||
########################################################################
|
||||
|
||||
#### This is a kerberos container for all the realms in a tree.
|
||||
|
||||
objectclass ( 2.16.840.1.113719.1.301.6.1.1
|
||||
NAME 'krbContainer'
|
||||
SUP top
|
||||
STRUCTURAL
|
||||
MUST ( cn ) )
|
||||
|
||||
|
||||
##### The krbRealmContainer is created per realm and holds realm specific data.
|
||||
|
||||
objectclass ( 2.16.840.1.113719.1.301.6.2.1
|
||||
NAME 'krbRealmContainer'
|
||||
SUP top
|
||||
STRUCTURAL
|
||||
MUST ( cn )
|
||||
MAY ( krbMKey $ krbUPEnabled $ krbSubTrees $ krbSearchScope $ krbLdapServers $ krbSupportedEncSaltTypes $ krbDefaultEncSaltTypes $ krbTicketPolicyReference $ krbKdcServers $ krbPwdServers $ krbAdmServers $ krbPrincNamingAttr $ krbPwdPolicyReference $ krbPrincContainerRef ) )
|
||||
|
||||
|
||||
##### An instance of a class derived from krbService is created per
|
||||
##### kerberos authentication or administration server in an realm and holds
|
||||
##### references to the realm objects. These references is used to further read
|
||||
##### realm specific data to service AS/TGS requests. Additionally this object
|
||||
##### contains some server specific data like pathnames and ports that the
|
||||
##### server uses. This is the identity the kerberos server logs in with. A key
|
||||
##### pair for the same is created and the kerberos server logs in with the same.
|
||||
#####
|
||||
##### krbKdcService, krbAdmService and krbPwdService derive from this class.
|
||||
|
||||
objectclass ( 2.16.840.1.113719.1.301.6.3.1
|
||||
NAME 'krbService'
|
||||
SUP top
|
||||
ABSTRACT
|
||||
MUST ( cn )
|
||||
MAY ( krbHostServer $ krbRealmReferences ) )
|
||||
|
||||
|
||||
##### Representative object for the KDC server to bind into a LDAP directory
|
||||
##### and have a connection to access Kerberos data with the required
|
||||
##### access rights.
|
||||
|
||||
objectclass ( 2.16.840.1.113719.1.301.6.4.1
|
||||
NAME 'krbKdcService'
|
||||
SUP krbService
|
||||
STRUCTURAL )
|
||||
|
||||
|
||||
##### Representative object for the Kerberos Password server to bind into a LDAP directory
|
||||
##### and have a connection to access Kerberos data with the required
|
||||
##### access rights.
|
||||
|
||||
objectclass ( 2.16.840.1.113719.1.301.6.5.1
|
||||
NAME 'krbPwdService'
|
||||
SUP krbService
|
||||
STRUCTURAL )
|
||||
|
||||
|
||||
###### The principal data auxiliary class. Holds principal information
|
||||
###### and is used to store principal information for Person, Service objects.
|
||||
|
||||
objectclass ( 2.16.840.1.113719.1.301.6.8.1
|
||||
NAME 'krbPrincipalAux'
|
||||
SUP top
|
||||
AUXILIARY
|
||||
MAY ( krbPrincipalName $ krbCanonicalName $ krbUPEnabled $ krbPrincipalKey $ krbTicketPolicyReference $ krbPrincipalExpiration $ krbPasswordExpiration $ krbPwdPolicyReference $ krbPrincipalType $ krbPwdHistory $ krbLastPwdChange $ krbLastAdminUnlock $ krbPrincipalAliases $ krbLastSuccessfulAuth $ krbLastFailedAuth $ krbLoginFailedCount $ krbExtraData $ krbAllowedToDelegateTo $ krbPrincipalAuthInd ) )
|
||||
|
||||
|
||||
###### This class is used to create additional principals and stand alone principals.
|
||||
|
||||
objectclass ( 2.16.840.1.113719.1.301.6.9.1
|
||||
NAME 'krbPrincipal'
|
||||
SUP top
|
||||
MUST ( krbPrincipalName )
|
||||
MAY ( krbObjectReferences ) )
|
||||
|
||||
|
||||
###### The principal references auxiliary class. Holds all principals referred
|
||||
###### from a service
|
||||
|
||||
objectclass ( 2.16.840.1.113719.1.301.6.11.1
|
||||
NAME 'krbPrincRefAux'
|
||||
SUP top
|
||||
AUXILIARY
|
||||
MAY krbPrincipalReferences )
|
||||
|
||||
|
||||
##### Representative object for the Kerberos Administration server to bind into a LDAP directory
|
||||
##### and have a connection Id to access Kerberos data with the required access rights.
|
||||
|
||||
objectclass ( 2.16.840.1.113719.1.301.6.13.1
|
||||
NAME 'krbAdmService'
|
||||
SUP krbService
|
||||
STRUCTURAL )
|
||||
|
||||
|
||||
##### The krbPwdPolicy object is a template password policy that
|
||||
##### can be applied to principals when they are created.
|
||||
##### These policy attributes will be in effect, when the Kerberos
|
||||
##### passwords are different from users' passwords (UP).
|
||||
|
||||
objectclass ( 2.16.840.1.113719.1.301.6.14.1
|
||||
NAME 'krbPwdPolicy'
|
||||
SUP top
|
||||
MUST ( cn )
|
||||
MAY ( krbMaxPwdLife $ krbMinPwdLife $ krbPwdMinDiffChars $ krbPwdMinLength $ krbPwdHistoryLength $ krbPwdMaxFailure $ krbPwdFailureCountInterval $ krbPwdLockoutDuration $ krbPwdAttributes $ krbPwdMaxLife $ krbPwdMaxRenewableLife $ krbPwdAllowedKeysalts ) )
|
||||
|
||||
|
||||
##### The krbTicketPolicyAux holds Kerberos ticket policy attributes.
|
||||
##### This class can be attached to a principal object or realm object.
|
||||
|
||||
objectclass ( 2.16.840.1.113719.1.301.6.16.1
|
||||
NAME 'krbTicketPolicyAux'
|
||||
SUP top
|
||||
AUXILIARY
|
||||
MAY ( krbTicketFlags $ krbMaxTicketLife $ krbMaxRenewableAge ) )
|
||||
|
||||
|
||||
##### The krbTicketPolicy object is an effective ticket policy that is associated with a realm or a principal
|
||||
|
||||
objectclass ( 2.16.840.1.113719.1.301.6.17.1
|
||||
NAME 'krbTicketPolicy'
|
||||
SUP top
|
||||
MUST ( cn ) )
|
||||
|
19
roles/ldap/server/files/openssh-lpk.schema
Normal file
19
roles/ldap/server/files/openssh-lpk.schema
Normal file
|
@ -0,0 +1,19 @@
|
|||
#
|
||||
# LDAP Public Key Patch schema for use with openssh-ldappubkey
|
||||
# Author: Eric AUGE <eau@phear.org>
|
||||
#
|
||||
# Based on the proposal of : Mark Ruijter
|
||||
#
|
||||
|
||||
|
||||
# octetString SYNTAX
|
||||
attributetype ( 1.3.6.1.4.1.24552.500.1.1.1.13 NAME 'sshPublicKey'
|
||||
DESC 'MANDATORY: OpenSSH Public key'
|
||||
EQUALITY octetStringMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.40 )
|
||||
|
||||
# printableString SYNTAX yes|no
|
||||
objectclass ( 1.3.6.1.4.1.24552.500.1.1.2.0 NAME 'ldapPublicKey' SUP top AUXILIARY
|
||||
DESC 'MANDATORY: OpenSSH LPK objectclass'
|
||||
MAY ( sshPublicKey $ uid )
|
||||
)
|
310
roles/ldap/server/files/rfc2307bis.schema
Normal file
310
roles/ldap/server/files/rfc2307bis.schema
Normal file
|
@ -0,0 +1,310 @@
|
|||
###
|
||||
# Extracted from: http://tools.ietf.org/html/draft-howard-rfc2307bis-02
|
||||
###
|
||||
|
||||
# Builtin
|
||||
#attributeType ( 1.3.6.1.1.1.1.0 NAME 'uidNumber'
|
||||
# DESC 'An integer uniquely identifying a user in an
|
||||
# administrative domain'
|
||||
# EQUALITY integerMatch
|
||||
# ORDERING integerOrderingMatch
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
# SINGLE-VALUE )
|
||||
|
||||
# Builtin
|
||||
#attributeType ( 1.3.6.1.1.1.1.1 NAME 'gidNumber'
|
||||
# DESC 'An integer uniquely identifying a group in an
|
||||
# administrative domain'
|
||||
# EQUALITY integerMatch
|
||||
# ORDERING integerOrderingMatch
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
# SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.2 NAME 'gecos'
|
||||
DESC 'The GECOS field; the common name'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SUBSTR caseIgnoreSubstringsMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.3 NAME 'homeDirectory'
|
||||
DESC 'The absolute path to the home directory'
|
||||
EQUALITY caseExactIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.4 NAME 'loginShell'
|
||||
DESC 'The path to the login shell'
|
||||
EQUALITY caseExactIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.5 NAME 'shadowLastChange'
|
||||
EQUALITY integerMatch
|
||||
ORDERING integerOrderingMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.6 NAME 'shadowMin'
|
||||
EQUALITY integerMatch
|
||||
ORDERING integerOrderingMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.7 NAME 'shadowMax'
|
||||
EQUALITY integerMatch
|
||||
ORDERING integerOrderingMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.8 NAME 'shadowWarning'
|
||||
EQUALITY integerMatch
|
||||
ORDERING integerOrderingMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.9 NAME 'shadowInactive'
|
||||
EQUALITY integerMatch
|
||||
ORDERING integerOrderingMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.10 NAME 'shadowExpire'
|
||||
EQUALITY integerMatch
|
||||
ORDERING integerOrderingMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.11 NAME 'shadowFlag'
|
||||
EQUALITY integerMatch
|
||||
ORDERING integerOrderingMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.12 NAME 'memberUid'
|
||||
EQUALITY caseExactMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.13 NAME 'memberNisNetgroup'
|
||||
EQUALITY caseExactMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.14 NAME 'nisNetgroupTriple'
|
||||
DESC 'Netgroup triple'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SUBSTR caseIgnoreSubstringsMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.15 NAME 'ipServicePort'
|
||||
DESC 'Service port number'
|
||||
EQUALITY integerMatch
|
||||
ORDERING integerOrderingMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.16 NAME 'ipServiceProtocol'
|
||||
DESC 'Service protocol name'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.17 NAME 'ipProtocolNumber'
|
||||
DESC 'IP protocol number'
|
||||
EQUALITY integerMatch
|
||||
ORDERING integerOrderingMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.18 NAME 'oncRpcNumber'
|
||||
DESC 'ONC RPC number'
|
||||
EQUALITY integerMatch
|
||||
ORDERING integerOrderingMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.19 NAME 'ipHostNumber'
|
||||
DESC 'IPv4 addresses as a dotted decimal omitting leading
|
||||
zeros or IPv6 addresses as defined in RFC2373'
|
||||
EQUALITY caseIgnoreIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.20 NAME 'ipNetworkNumber'
|
||||
DESC 'IP network omitting leading zeros, eg. 192.168'
|
||||
EQUALITY caseIgnoreIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.21 NAME 'ipNetmaskNumber'
|
||||
DESC 'IP netmask omitting leading zeros, eg. 255.255.255.0'
|
||||
EQUALITY caseIgnoreIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.22 NAME 'macAddress'
|
||||
DESC 'MAC address in maximal, colon separated hex
|
||||
notation, eg. 00:00:92:90:ee:e2'
|
||||
EQUALITY caseIgnoreIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.23 NAME 'bootParameter'
|
||||
DESC 'rpc.bootparamd parameter'
|
||||
EQUALITY caseExactIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.24 NAME 'bootFile'
|
||||
DESC 'Boot image name'
|
||||
EQUALITY caseExactIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.26 NAME 'nisMapName'
|
||||
DESC 'Name of a generic NIS map'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{64} )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.27 NAME 'nisMapEntry'
|
||||
DESC 'A generic NIS entry'
|
||||
EQUALITY caseExactMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{1024}
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.28 NAME 'nisPublicKey'
|
||||
DESC 'NIS public key'
|
||||
EQUALITY octetStringMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.40
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.29 NAME 'nisSecretKey'
|
||||
DESC 'NIS secret key'
|
||||
EQUALITY octetStringMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.40
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.30 NAME 'nisDomain'
|
||||
DESC 'NIS domain'
|
||||
EQUALITY caseIgnoreIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{256} )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.31 NAME 'automountMapName'
|
||||
DESC 'automount Map Name'
|
||||
EQUALITY caseExactMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.32 NAME 'automountKey'
|
||||
DESC 'Automount Key value'
|
||||
EQUALITY caseExactMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
|
||||
SINGLE-VALUE )
|
||||
|
||||
attributeType ( 1.3.6.1.1.1.1.33 NAME 'automountInformation'
|
||||
DESC 'Automount information'
|
||||
EQUALITY caseExactMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15
|
||||
SINGLE-VALUE )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.0 NAME 'posixAccount' SUP top AUXILIARY
|
||||
DESC 'Abstraction of an account with POSIX attributes'
|
||||
MUST ( cn $ uid $ uidNumber $ gidNumber $ homeDirectory )
|
||||
MAY ( userPassword $ loginShell $ gecos $
|
||||
description ) )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.1 NAME 'shadowAccount' SUP top AUXILIARY
|
||||
DESC 'Additional attributes for shadow passwords'
|
||||
MUST uid
|
||||
MAY ( userPassword $ description $
|
||||
shadowLastChange $ shadowMin $ shadowMax $
|
||||
shadowWarning $ shadowInactive $
|
||||
shadowExpire $ shadowFlag ) )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.2 NAME 'posixGroup' SUP top AUXILIARY
|
||||
DESC 'Abstraction of a group of accounts'
|
||||
MUST gidNumber
|
||||
MAY ( userPassword $ memberUid $
|
||||
description ) )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.3 NAME 'ipService' SUP top STRUCTURAL
|
||||
DESC 'Abstraction an Internet Protocol service.
|
||||
Maps an IP port and protocol (such as tcp or udp)
|
||||
to one or more names; the distinguished value of
|
||||
the cn attribute denotes the services canonical
|
||||
name'
|
||||
MUST ( cn $ ipServicePort $ ipServiceProtocol )
|
||||
MAY description )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.4 NAME 'ipProtocol' SUP top STRUCTURAL
|
||||
DESC 'Abstraction of an IP protocol. Maps a protocol number
|
||||
to one or more names. The distinguished value of the cn
|
||||
attribute denotes the protocol canonical name'
|
||||
MUST ( cn $ ipProtocolNumber )
|
||||
MAY description )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.5 NAME 'oncRpc' SUP top STRUCTURAL
|
||||
DESC 'Abstraction of an Open Network Computing (ONC)
|
||||
[RFC1057] Remote Procedure Call (RPC) binding.
|
||||
This class maps an ONC RPC number to a name.
|
||||
The distinguished value of the cn attribute denotes
|
||||
the RPC service canonical name'
|
||||
MUST ( cn $ oncRpcNumber )
|
||||
MAY description )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.6 NAME 'ipHost' SUP top AUXILIARY
|
||||
DESC 'Abstraction of a host, an IP device. The distinguished
|
||||
value of the cn attribute denotes the hosts canonical
|
||||
name. Device SHOULD be used as a structural class'
|
||||
MUST ( cn $ ipHostNumber )
|
||||
MAY ( userPassword $ l $ description $
|
||||
manager ) )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.7 NAME 'ipNetwork' SUP top STRUCTURAL
|
||||
DESC 'Abstraction of a network. The distinguished value of
|
||||
the cn attribute denotes the network canonical name'
|
||||
MUST ipNetworkNumber
|
||||
MAY ( cn $ ipNetmaskNumber $ l $ description $ manager ) )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.8 NAME 'nisNetgroup' SUP top STRUCTURAL
|
||||
DESC 'Abstraction of a netgroup. May refer to other
|
||||
netgroups'
|
||||
MUST cn
|
||||
MAY ( nisNetgroupTriple $ memberNisNetgroup $ description ) )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.9 NAME 'nisMap' SUP top STRUCTURAL
|
||||
DESC 'A generic abstraction of a NIS map'
|
||||
MUST nisMapName
|
||||
MAY description )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.10 NAME 'nisObject' SUP top STRUCTURAL
|
||||
DESC 'An entry in a NIS map'
|
||||
MUST ( cn $ nisMapEntry $ nisMapName ) )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.11 NAME 'ieee802Device' SUP top AUXILIARY
|
||||
DESC 'A device with a MAC address; device SHOULD be
|
||||
used as a structural class'
|
||||
MAY macAddress )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.12 NAME 'bootableDevice' SUP top AUXILIARY
|
||||
DESC 'A device with boot parameters; device SHOULD be
|
||||
used as a structural class'
|
||||
MAY ( bootFile $ bootParameter ) )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.14 NAME 'nisKeyObject' SUP top AUXILIARY
|
||||
DESC 'An object with a public and secret key'
|
||||
MUST ( cn $ nisPublicKey $ nisSecretKey )
|
||||
MAY ( uidNumber $ description ) )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.15 NAME 'nisDomainObject' SUP top AUXILIARY
|
||||
DESC 'Associates a NIS domain with a naming context'
|
||||
MUST nisDomain )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.16 NAME 'automountMap' SUP top STRUCTURAL
|
||||
MUST ( automountMapName )
|
||||
MAY description )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.17 NAME 'automount' SUP top STRUCTURAL
|
||||
DESC 'Automount information'
|
||||
MUST ( automountKey $ automountInformation )
|
||||
MAY description )
|
||||
|
||||
objectClass ( 1.3.6.1.1.1.2.18 NAME 'groupOfMembers' SUP top STRUCTURAL
|
||||
DESC 'A group with members (DNs)'
|
||||
MUST cn
|
||||
MAY ( businessCategory $ seeAlso $ owner $ ou $ o $
|
||||
description $ member ) )
|
644
roles/ldap/server/files/samba.schema
Normal file
644
roles/ldap/server/files/samba.schema
Normal file
|
@ -0,0 +1,644 @@
|
|||
##
|
||||
## schema file for OpenLDAP 2.x
|
||||
## Schema for storing Samba user accounts and group maps in LDAP
|
||||
## OIDs are owned by the Samba Team
|
||||
##
|
||||
## Prerequisite schemas - uid (cosine.schema)
|
||||
## - displayName (inetorgperson.schema)
|
||||
## - gidNumber (nis.schema)
|
||||
##
|
||||
## 1.3.6.1.4.1.7165.2.1.x - attributetypes
|
||||
## 1.3.6.1.4.1.7165.2.2.x - objectclasses
|
||||
##
|
||||
## Printer support
|
||||
## 1.3.6.1.4.1.7165.2.3.1.x - attributetypes
|
||||
## 1.3.6.1.4.1.7165.2.3.2.x - objectclasses
|
||||
##
|
||||
## Samba4
|
||||
## 1.3.6.1.4.1.7165.4.1.x - attributetypes
|
||||
## 1.3.6.1.4.1.7165.4.2.x - objectclasses
|
||||
## 1.3.6.1.4.1.7165.4.3.x - LDB/LDAP Controls
|
||||
## 1.3.6.1.4.1.7165.4.4.x - LDB/LDAP Extended Operations
|
||||
## 1.3.6.1.4.1.7165.4.255.x - mapped OIDs due to conflicts between AD and standards-track
|
||||
##
|
||||
## External projects
|
||||
## 1.3.6.1.4.1.7165.655.x
|
||||
## 1.3.6.1.4.1.7165.655.1.x - GSS-NTLMSSP
|
||||
##
|
||||
## ----- READ THIS WHEN ADDING A NEW ATTRIBUTE OR OBJECT CLASS ------
|
||||
##
|
||||
## Run the 'get_next_oid' bash script in this directory to find the
|
||||
## next available OID for attribute type and object classes.
|
||||
##
|
||||
## $ ./get_next_oid
|
||||
## attributetype ( 1.3.6.1.4.1.7165.2.1.XX NAME ....
|
||||
## objectclass ( 1.3.6.1.4.1.7165.2.2.XX NAME ....
|
||||
##
|
||||
## Also ensure that new entries adhere to the declaration style
|
||||
## used throughout this file
|
||||
##
|
||||
## <attributetype|objectclass> ( 1.3.6.1.4.1.7165.2.XX.XX NAME ....
|
||||
## ^ ^ ^
|
||||
##
|
||||
## The spaces are required for the get_next_oid script (and for
|
||||
## readability).
|
||||
##
|
||||
## ------------------------------------------------------------------
|
||||
|
||||
# objectIdentifier SambaRoot 1.3.6.1.4.1.7165
|
||||
# objectIdentifier Samba3 SambaRoot:2
|
||||
# objectIdentifier Samba3Attrib Samba3:1
|
||||
# objectIdentifier Samba3ObjectClass Samba3:2
|
||||
# objectIdentifier Samba4 SambaRoot:4
|
||||
|
||||
########################################################################
|
||||
## HISTORICAL ##
|
||||
########################################################################
|
||||
|
||||
##
|
||||
## Password hashes
|
||||
##
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.1 NAME 'lmPassword'
|
||||
# DESC 'LanManager Passwd'
|
||||
# EQUALITY caseIgnoreIA5Match
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{32} SINGLE-VALUE )
|
||||
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.2 NAME 'ntPassword'
|
||||
# DESC 'NT Passwd'
|
||||
# EQUALITY caseIgnoreIA5Match
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{32} SINGLE-VALUE )
|
||||
|
||||
##
|
||||
## Account flags in string format ([UWDX ])
|
||||
##
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.4 NAME 'acctFlags'
|
||||
# DESC 'Account Flags'
|
||||
# EQUALITY caseIgnoreIA5Match
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{16} SINGLE-VALUE )
|
||||
|
||||
##
|
||||
## Password timestamps & policies
|
||||
##
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.3 NAME 'pwdLastSet'
|
||||
# DESC 'NT pwdLastSet'
|
||||
# EQUALITY integerMatch
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.5 NAME 'logonTime'
|
||||
# DESC 'NT logonTime'
|
||||
# EQUALITY integerMatch
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.6 NAME 'logoffTime'
|
||||
# DESC 'NT logoffTime'
|
||||
# EQUALITY integerMatch
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.7 NAME 'kickoffTime'
|
||||
# DESC 'NT kickoffTime'
|
||||
# EQUALITY integerMatch
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.8 NAME 'pwdCanChange'
|
||||
# DESC 'NT pwdCanChange'
|
||||
# EQUALITY integerMatch
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.9 NAME 'pwdMustChange'
|
||||
# DESC 'NT pwdMustChange'
|
||||
# EQUALITY integerMatch
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
##
|
||||
## string settings
|
||||
##
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.10 NAME 'homeDrive'
|
||||
# DESC 'NT homeDrive'
|
||||
# EQUALITY caseIgnoreIA5Match
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{4} SINGLE-VALUE )
|
||||
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.11 NAME 'scriptPath'
|
||||
# DESC 'NT scriptPath'
|
||||
# EQUALITY caseIgnoreIA5Match
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{255} SINGLE-VALUE )
|
||||
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.12 NAME 'profilePath'
|
||||
# DESC 'NT profilePath'
|
||||
# EQUALITY caseIgnoreIA5Match
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{255} SINGLE-VALUE )
|
||||
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.13 NAME 'userWorkstations'
|
||||
# DESC 'userWorkstations'
|
||||
# EQUALITY caseIgnoreIA5Match
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{255} SINGLE-VALUE )
|
||||
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.17 NAME 'smbHome'
|
||||
# DESC 'smbHome'
|
||||
# EQUALITY caseIgnoreIA5Match
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{128} )
|
||||
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.18 NAME 'domain'
|
||||
# DESC 'Windows NT domain to which the user belongs'
|
||||
# EQUALITY caseIgnoreIA5Match
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{128} )
|
||||
|
||||
##
|
||||
## user and group RID
|
||||
##
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.14 NAME 'rid'
|
||||
# DESC 'NT rid'
|
||||
# EQUALITY integerMatch
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
#attributetype ( 1.3.6.1.4.1.7165.2.1.15 NAME 'primaryGroupID'
|
||||
# DESC 'NT Group RID'
|
||||
# EQUALITY integerMatch
|
||||
# SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
##
|
||||
## The smbPasswordEntry objectclass has been depreciated in favor of the
|
||||
## sambaAccount objectclass
|
||||
##
|
||||
#objectclass ( 1.3.6.1.4.1.7165.2.2.1 NAME 'smbPasswordEntry' SUP top AUXILIARY
|
||||
# DESC 'Samba smbpasswd entry'
|
||||
# MUST ( uid $ uidNumber )
|
||||
# MAY ( lmPassword $ ntPassword $ pwdLastSet $ acctFlags ))
|
||||
|
||||
#objectclass ( 1.3.6.1.4.1.7165.2.2.2 NAME 'sambaAccount' SUP top STRUCTURAL
|
||||
# DESC 'Samba Account'
|
||||
# MUST ( uid $ rid )
|
||||
# MAY ( cn $ lmPassword $ ntPassword $ pwdLastSet $ logonTime $
|
||||
# logoffTime $ kickoffTime $ pwdCanChange $ pwdMustChange $ acctFlags $
|
||||
# displayName $ smbHome $ homeDrive $ scriptPath $ profilePath $
|
||||
# description $ userWorkstations $ primaryGroupID $ domain ))
|
||||
|
||||
#objectclass ( 1.3.6.1.4.1.7165.2.2.3 NAME 'sambaAccount' SUP top AUXILIARY
|
||||
# DESC 'Samba Auxiliary Account'
|
||||
# MUST ( uid $ rid )
|
||||
# MAY ( cn $ lmPassword $ ntPassword $ pwdLastSet $ logonTime $
|
||||
# logoffTime $ kickoffTime $ pwdCanChange $ pwdMustChange $ acctFlags $
|
||||
# displayName $ smbHome $ homeDrive $ scriptPath $ profilePath $
|
||||
# description $ userWorkstations $ primaryGroupID $ domain ))
|
||||
|
||||
########################################################################
|
||||
## END OF HISTORICAL ##
|
||||
########################################################################
|
||||
|
||||
#######################################################################
|
||||
## Attributes used by Samba 3.0 schema ##
|
||||
#######################################################################
|
||||
|
||||
##
|
||||
## Password hashes
|
||||
##
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.24 NAME 'sambaLMPassword'
|
||||
DESC 'LanManager Password'
|
||||
EQUALITY caseIgnoreIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{32} SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.25 NAME 'sambaNTPassword'
|
||||
DESC 'MD4 hash of the unicode password'
|
||||
EQUALITY caseIgnoreIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{32} SINGLE-VALUE )
|
||||
|
||||
##
|
||||
## Account flags in string format ([UWDX ])
|
||||
##
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.26 NAME 'sambaAcctFlags'
|
||||
DESC 'Account Flags'
|
||||
EQUALITY caseIgnoreIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{16} SINGLE-VALUE )
|
||||
|
||||
##
|
||||
## Password timestamps & policies
|
||||
##
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.27 NAME 'sambaPwdLastSet'
|
||||
DESC 'Timestamp of the last password update'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.28 NAME 'sambaPwdCanChange'
|
||||
DESC 'Timestamp of when the user is allowed to update the password'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.29 NAME 'sambaPwdMustChange'
|
||||
DESC 'Timestamp of when the password will expire'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.30 NAME 'sambaLogonTime'
|
||||
DESC 'Timestamp of last logon'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.31 NAME 'sambaLogoffTime'
|
||||
DESC 'Timestamp of last logoff'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.32 NAME 'sambaKickoffTime'
|
||||
DESC 'Timestamp of when the user will be logged off automatically'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.48 NAME 'sambaBadPasswordCount'
|
||||
DESC 'Bad password attempt count'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.49 NAME 'sambaBadPasswordTime'
|
||||
DESC 'Time of the last bad password attempt'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.55 NAME 'sambaLogonHours'
|
||||
DESC 'Logon Hours'
|
||||
EQUALITY caseIgnoreIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{42} SINGLE-VALUE )
|
||||
|
||||
##
|
||||
## string settings
|
||||
##
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.33 NAME 'sambaHomeDrive'
|
||||
DESC 'Driver letter of home directory mapping'
|
||||
EQUALITY caseIgnoreIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{4} SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.34 NAME 'sambaLogonScript'
|
||||
DESC 'Logon script path'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{255} SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.35 NAME 'sambaProfilePath'
|
||||
DESC 'Roaming profile path'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{255} SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.36 NAME 'sambaUserWorkstations'
|
||||
DESC 'List of user workstations the user is allowed to logon to'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{255} SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.37 NAME 'sambaHomePath'
|
||||
DESC 'Home directory UNC path'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{128} )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.38 NAME 'sambaDomainName'
|
||||
DESC 'Windows NT domain to which the user belongs'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{128} )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.47 NAME 'sambaMungedDial'
|
||||
DESC 'Base64 encoded user parameter string'
|
||||
EQUALITY caseExactMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{1050} )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.54 NAME 'sambaPasswordHistory'
|
||||
DESC 'Concatenated MD5 hashes of the salted NT passwords used on this account'
|
||||
EQUALITY caseIgnoreIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{32} )
|
||||
|
||||
##
|
||||
## SID, of any type
|
||||
##
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.20 NAME 'sambaSID'
|
||||
DESC 'Security ID'
|
||||
EQUALITY caseIgnoreIA5Match
|
||||
SUBSTR caseExactIA5SubstringsMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{64} SINGLE-VALUE )
|
||||
|
||||
##
|
||||
## Primary group SID, compatible with ntSid
|
||||
##
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.23 NAME 'sambaPrimaryGroupSID'
|
||||
DESC 'Primary Group Security ID'
|
||||
EQUALITY caseIgnoreIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{64} SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.51 NAME 'sambaSIDList'
|
||||
DESC 'Security ID List'
|
||||
EQUALITY caseIgnoreIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{64} )
|
||||
|
||||
##
|
||||
## group mapping attributes
|
||||
##
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.19 NAME 'sambaGroupType'
|
||||
DESC 'NT Group Type'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
##
|
||||
## Store info on the domain
|
||||
##
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.21 NAME 'sambaNextUserRid'
|
||||
DESC 'Next NT rid to give our for users'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.22 NAME 'sambaNextGroupRid'
|
||||
DESC 'Next NT rid to give out for groups'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.39 NAME 'sambaNextRid'
|
||||
DESC 'Next NT rid to give out for anything'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.40 NAME 'sambaAlgorithmicRidBase'
|
||||
DESC 'Base at which the samba RID generation algorithm should operate'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.41 NAME 'sambaShareName'
|
||||
DESC 'Share Name'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.42 NAME 'sambaOptionName'
|
||||
DESC 'Option Name'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SUBSTR caseIgnoreSubstringsMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{256} )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.43 NAME 'sambaBoolOption'
|
||||
DESC 'A boolean option'
|
||||
EQUALITY booleanMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.7 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.44 NAME 'sambaIntegerOption'
|
||||
DESC 'An integer option'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.45 NAME 'sambaStringOption'
|
||||
DESC 'A string option'
|
||||
EQUALITY caseExactIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.46 NAME 'sambaStringListOption'
|
||||
DESC 'A string list option'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15 )
|
||||
|
||||
|
||||
##attributetype ( 1.3.6.1.4.1.7165.2.1.50 NAME 'sambaPrivName'
|
||||
## SUP name )
|
||||
|
||||
##attributetype ( 1.3.6.1.4.1.7165.2.1.52 NAME 'sambaPrivilegeList'
|
||||
## DESC 'Privileges List'
|
||||
## EQUALITY caseIgnoreIA5Match
|
||||
## SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{64} )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.53 NAME 'sambaTrustFlags'
|
||||
DESC 'Trust Password Flags'
|
||||
EQUALITY caseIgnoreIA5Match
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 )
|
||||
|
||||
# "min password length"
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.58 NAME 'sambaMinPwdLength'
|
||||
DESC 'Minimal password length (default: 5)'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
# "password history"
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.59 NAME 'sambaPwdHistoryLength'
|
||||
DESC 'Length of Password History Entries (default: 0 => off)'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
# "user must logon to change password"
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.60 NAME 'sambaLogonToChgPwd'
|
||||
DESC 'Force Users to logon for password change (default: 0 => off, 2 => on)'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
# "maximum password age"
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.61 NAME 'sambaMaxPwdAge'
|
||||
DESC 'Maximum password age, in seconds (default: -1 => never expire passwords)'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
# "minimum password age"
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.62 NAME 'sambaMinPwdAge'
|
||||
DESC 'Minimum password age, in seconds (default: 0 => allow immediate password change)'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
# "lockout duration"
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.63 NAME 'sambaLockoutDuration'
|
||||
DESC 'Lockout duration in minutes (default: 30, -1 => forever)'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
# "reset count minutes"
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.64 NAME 'sambaLockoutObservationWindow'
|
||||
DESC 'Reset time after lockout in minutes (default: 30)'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
# "bad lockout attempt"
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.65 NAME 'sambaLockoutThreshold'
|
||||
DESC 'Lockout users after bad logon attempts (default: 0 => off)'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
# "disconnect time"
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.66 NAME 'sambaForceLogoff'
|
||||
DESC 'Disconnect Users outside logon hours (default: -1 => off, 0 => on)'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
# "refuse machine password change"
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.67 NAME 'sambaRefuseMachinePwdChange'
|
||||
DESC 'Allow Machine Password changes (default: 0 => off)'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
#
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.68 NAME 'sambaClearTextPassword'
|
||||
DESC 'Clear text password (used for trusted domain passwords)'
|
||||
EQUALITY octetStringMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.40 )
|
||||
|
||||
#
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.69 NAME 'sambaPreviousClearTextPassword'
|
||||
DESC 'Previous clear text password (used for trusted domain passwords)'
|
||||
EQUALITY octetStringMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.40 )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.70 NAME 'sambaTrustType'
|
||||
DESC 'Type of trust'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.71 NAME 'sambaTrustAttributes'
|
||||
DESC 'Trust attributes for a trusted domain'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.72 NAME 'sambaTrustDirection'
|
||||
DESC 'Direction of a trust'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.73 NAME 'sambaTrustPartner'
|
||||
DESC 'Fully qualified name of the domain with which a trust exists'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{128} )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.74 NAME 'sambaFlatName'
|
||||
DESC 'NetBIOS name of a domain'
|
||||
EQUALITY caseIgnoreMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{128} )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.75 NAME 'sambaTrustAuthOutgoing'
|
||||
DESC 'Authentication information for the outgoing portion of a trust'
|
||||
EQUALITY caseExactMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{1050} )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.76 NAME 'sambaTrustAuthIncoming'
|
||||
DESC 'Authentication information for the incoming portion of a trust'
|
||||
EQUALITY caseExactMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{1050} )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.77 NAME 'sambaSecurityIdentifier'
|
||||
DESC 'SID of a trusted domain'
|
||||
EQUALITY caseIgnoreIA5Match SUBSTR caseExactIA5SubstringsMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26{64} SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.78 NAME 'sambaTrustForestTrustInfo'
|
||||
DESC 'Forest trust information for a trusted domain object'
|
||||
EQUALITY caseExactMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{1050} )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.79 NAME 'sambaTrustPosixOffset'
|
||||
DESC 'POSIX offset of a trust'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
attributetype ( 1.3.6.1.4.1.7165.2.1.80 NAME 'sambaSupportedEncryptionTypes'
|
||||
DESC 'Supported encryption types of a trust'
|
||||
EQUALITY integerMatch
|
||||
SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE )
|
||||
|
||||
#######################################################################
|
||||
## objectClasses used by Samba 3.0 schema ##
|
||||
#######################################################################
|
||||
|
||||
## The X.500 data model (and therefore LDAPv3) says that each entry can
|
||||
## only have one structural objectclass. OpenLDAP 2.0 does not enforce
|
||||
## this currently but will in v2.1
|
||||
|
||||
##
|
||||
## added new objectclass (and OID) for 3.0 to help us deal with backwards
|
||||
## compatibility with 2.2 installations (e.g. ldapsam_compat) --jerry
|
||||
##
|
||||
objectclass ( 1.3.6.1.4.1.7165.2.2.6 NAME 'sambaSamAccount' SUP top AUXILIARY
|
||||
DESC 'Samba 3.0 Auxilary SAM Account'
|
||||
MUST ( uid $ sambaSID )
|
||||
MAY ( cn $ sambaLMPassword $ sambaNTPassword $ sambaPwdLastSet $
|
||||
sambaLogonTime $ sambaLogoffTime $ sambaKickoffTime $
|
||||
sambaPwdCanChange $ sambaPwdMustChange $ sambaAcctFlags $
|
||||
displayName $ sambaHomePath $ sambaHomeDrive $ sambaLogonScript $
|
||||
sambaProfilePath $ description $ sambaUserWorkstations $
|
||||
sambaPrimaryGroupSID $ sambaDomainName $ sambaMungedDial $
|
||||
sambaBadPasswordCount $ sambaBadPasswordTime $
|
||||
sambaPasswordHistory $ sambaLogonHours))
|
||||
|
||||
##
|
||||
## Group mapping info
|
||||
##
|
||||
objectclass ( 1.3.6.1.4.1.7165.2.2.4 NAME 'sambaGroupMapping' SUP top AUXILIARY
|
||||
DESC 'Samba Group Mapping'
|
||||
MUST ( gidNumber $ sambaSID $ sambaGroupType )
|
||||
MAY ( displayName $ description $ sambaSIDList ))
|
||||
|
||||
##
|
||||
## Trust password for trust relationships (any kind)
|
||||
##
|
||||
objectclass ( 1.3.6.1.4.1.7165.2.2.14 NAME 'sambaTrustPassword' SUP top STRUCTURAL
|
||||
DESC 'Samba Trust Password'
|
||||
MUST ( sambaDomainName $ sambaNTPassword $ sambaTrustFlags )
|
||||
MAY ( sambaSID $ sambaPwdLastSet ))
|
||||
|
||||
##
|
||||
## Trust password for trusted domains
|
||||
## (to be stored beneath the trusting sambaDomain object in the DIT)
|
||||
##
|
||||
objectclass ( 1.3.6.1.4.1.7165.2.2.15 NAME 'sambaTrustedDomainPassword' SUP top STRUCTURAL
|
||||
DESC 'Samba Trusted Domain Password'
|
||||
MUST ( sambaDomainName $ sambaSID $
|
||||
sambaClearTextPassword $ sambaPwdLastSet )
|
||||
MAY ( sambaPreviousClearTextPassword ))
|
||||
|
||||
##
|
||||
## Whole-of-domain info
|
||||
##
|
||||
objectclass ( 1.3.6.1.4.1.7165.2.2.5 NAME 'sambaDomain' SUP top STRUCTURAL
|
||||
DESC 'Samba Domain Information'
|
||||
MUST ( sambaDomainName $
|
||||
sambaSID )
|
||||
MAY ( sambaNextRid $ sambaNextGroupRid $ sambaNextUserRid $
|
||||
sambaAlgorithmicRidBase $
|
||||
sambaMinPwdLength $ sambaPwdHistoryLength $ sambaLogonToChgPwd $
|
||||
sambaMaxPwdAge $ sambaMinPwdAge $
|
||||
sambaLockoutDuration $ sambaLockoutObservationWindow $ sambaLockoutThreshold $
|
||||
sambaForceLogoff $ sambaRefuseMachinePwdChange ))
|
||||
|
||||
##
|
||||
## used for idmap_ldap module
|
||||
##
|
||||
objectclass ( 1.3.6.1.4.1.7165.2.2.7 NAME 'sambaUnixIdPool' SUP top AUXILIARY
|
||||
DESC 'Pool for allocating UNIX uids/gids'
|
||||
MUST ( uidNumber $ gidNumber ) )
|
||||
|
||||
|
||||
objectclass ( 1.3.6.1.4.1.7165.2.2.8 NAME 'sambaIdmapEntry' SUP top AUXILIARY
|
||||
DESC 'Mapping from a SID to an ID'
|
||||
MUST ( sambaSID )
|
||||
MAY ( uidNumber $ gidNumber ) )
|
||||
|
||||
objectclass ( 1.3.6.1.4.1.7165.2.2.9 NAME 'sambaSidEntry' SUP top STRUCTURAL
|
||||
DESC 'Structural Class for a SID'
|
||||
MUST ( sambaSID ) )
|
||||
|
||||
objectclass ( 1.3.6.1.4.1.7165.2.2.10 NAME 'sambaConfig' SUP top AUXILIARY
|
||||
DESC 'Samba Configuration Section'
|
||||
MAY ( description ) )
|
||||
|
||||
objectclass ( 1.3.6.1.4.1.7165.2.2.11 NAME 'sambaShare' SUP top STRUCTURAL
|
||||
DESC 'Samba Share Section'
|
||||
MUST ( sambaShareName )
|
||||
MAY ( description ) )
|
||||
|
||||
objectclass ( 1.3.6.1.4.1.7165.2.2.12 NAME 'sambaConfigOption' SUP top STRUCTURAL
|
||||
DESC 'Samba Configuration Option'
|
||||
MUST ( sambaOptionName )
|
||||
MAY ( sambaBoolOption $ sambaIntegerOption $ sambaStringOption $
|
||||
sambaStringListoption $ description ) )
|
||||
|
||||
|
||||
## retired during privilege rewrite
|
||||
##objectclass ( 1.3.6.1.4.1.7165.2.2.13 NAME 'sambaPrivilege' SUP top AUXILIARY
|
||||
## DESC 'Samba Privilege'
|
||||
## MUST ( sambaSID )
|
||||
## MAY ( sambaPrivilegeList ) )
|
||||
|
||||
##
|
||||
## used for IPA_ldapsam
|
||||
##
|
||||
objectclass ( 1.3.6.1.4.1.7165.2.2.16 NAME 'sambaTrustedDomain' SUP top STRUCTURAL
|
||||
DESC 'Samba Trusted Domain Object'
|
||||
MUST ( cn )
|
||||
MAY ( sambaTrustType $ sambaTrustAttributes $ sambaTrustDirection $
|
||||
sambaTrustPartner $ sambaFlatName $ sambaTrustAuthOutgoing $
|
||||
sambaTrustAuthIncoming $ sambaSecurityIdentifier $
|
||||
sambaTrustForestTrustInfo $ sambaTrustPosixOffset $
|
||||
sambaSupportedEncryptionTypes) )
|
15
roles/ldap/server/files/slapd.sysconfig
Normal file
15
roles/ldap/server/files/slapd.sysconfig
Normal file
|
@ -0,0 +1,15 @@
|
|||
# OpenLDAP server configuration
|
||||
# see 'man slapd' for additional information
|
||||
|
||||
# Where the server will run (-h option)
|
||||
# - ldapi:/// is required for on-the-fly configuration using client tools
|
||||
# (use SASL with EXTERNAL mechanism for authentication)
|
||||
# - default: ldapi:/// ldap:///
|
||||
# - example: ldapi:/// ldap://127.0.0.1/ ldap://10.0.0.1:1389/ ldaps:///
|
||||
SLAPD_URLS="ldapi:/// ldaps:///"
|
||||
|
||||
# Any custom options
|
||||
SLAPD_OPTIONS="-f /etc/openldap/slapd.conf"
|
||||
|
||||
# Keytab location for GSSAPI Kerberos authentication
|
||||
KRB5_KTNAME="FILE:/etc/openldap/ldap.keytab"
|
5
roles/ldap/server/handlers/main.yml
Normal file
5
roles/ldap/server/handlers/main.yml
Normal file
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
- name: restart slapd
|
||||
service:
|
||||
name: slapd
|
||||
state: restarted
|
5
roles/ldap/server/meta/main.yml
Normal file
5
roles/ldap/server/meta/main.yml
Normal file
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
|
||||
dependencies:
|
||||
- {role: ldap/client}
|
||||
- {role: saslauthd}
|
139
roles/ldap/server/tasks/main.yml
Normal file
139
roles/ldap/server/tasks/main.yml
Normal file
|
@ -0,0 +1,139 @@
|
|||
---
|
||||
- name: install packages
|
||||
package:
|
||||
name: openldap-servers
|
||||
state: installed
|
||||
|
||||
- name: fix selinux context from ldap data directory
|
||||
sefcontext:
|
||||
path: /export/ldap(/.*)?
|
||||
setype: slapd_db_t
|
||||
|
||||
- name: create ldap data directory
|
||||
file:
|
||||
path: /export/ldap
|
||||
state: directory
|
||||
mode: 0700
|
||||
owner: ldap
|
||||
group: ldap
|
||||
|
||||
- name: link ldap data directory
|
||||
file:
|
||||
path: /srv/ldap
|
||||
src: /export/ldap
|
||||
state: link
|
||||
owner: root
|
||||
group: root
|
||||
follow: false
|
||||
|
||||
- name: remove nss cert databases
|
||||
file:
|
||||
path: "/etc/openldap/certs/{{ item }}"
|
||||
state: absent
|
||||
with_items:
|
||||
- cert8.db
|
||||
- key3.db
|
||||
- password
|
||||
- secmod.db
|
||||
|
||||
- name: copy ldap server certificates
|
||||
copy:
|
||||
dest: "{{ tls_certs }}/{{ ldap_server_cert }}.crt"
|
||||
src: "/srv/letsencrypt/live/{{ ldap_server_cert }}/cert.pem"
|
||||
mode: 0644
|
||||
owner: root
|
||||
group: "{{ ansible_wheel }}"
|
||||
notify: restart slapd
|
||||
- name: copy ldap server key
|
||||
copy:
|
||||
dest: "{{ tls_private }}/{{ ldap_server_cert }}.key"
|
||||
src: "/srv/letsencrypt/live/{{ ldap_server_cert }}/privkey.pem"
|
||||
mode: 0640
|
||||
owner: root
|
||||
group: ldap
|
||||
notify: restart slapd
|
||||
- name: copy ldap server certificate chain
|
||||
copy:
|
||||
dest: "{{ tls_certs }}/{{ ldap_server_cert }}-chain.crt"
|
||||
src: "/srv/letsencrypt/live/{{ ldap_server_cert }}/chain.pem"
|
||||
mode: 0644
|
||||
owner: root
|
||||
group: "{{ ansible_wheel }}"
|
||||
notify: restart slapd
|
||||
- name: get ldap server chain hash
|
||||
command: "openssl x509 -in /srv/letsencrypt/live/{{ ldap_server_cert }}/chain.pem -noout -hash"
|
||||
delegate_to: localhost
|
||||
register: result
|
||||
changed_when: false
|
||||
- name: link server chain certificate
|
||||
file:
|
||||
path: "/etc/openldap/certs/{{ result.stdout }}.0"
|
||||
src: "{{ tls_certs }}/{{ ldap_server_cert }}-chain.crt"
|
||||
owner: root
|
||||
group: "{{ ansible_wheel }}"
|
||||
follow: false
|
||||
state: link
|
||||
- name: link local ca certificate
|
||||
file:
|
||||
path: "/etc/openldap/certs/{{ pki_cacert_hash }}.0"
|
||||
src: "{{ tls_certs }}/ca.crt"
|
||||
owner: root
|
||||
group: "{{ ansible_wheel }}"
|
||||
follow: false
|
||||
state: link
|
||||
|
||||
- name: create slapd sysconfig file
|
||||
copy:
|
||||
dest: /etc/sysconfig/slapd
|
||||
src: slapd.sysconfig
|
||||
mode: 0644
|
||||
owner: root
|
||||
group: "{{ ansible_wheel }}"
|
||||
notify: restart slapd
|
||||
|
||||
- name: add custom schema files
|
||||
copy:
|
||||
dest: "/etc/openldap/schema/{{ item }}"
|
||||
src: "{{ item }}"
|
||||
mode: 0644
|
||||
owner: root
|
||||
group: "{{ ansible_wheel }}"
|
||||
with_items:
|
||||
- kerberos.schema # centos krb5-server-ldap 1.15.1
|
||||
- openssh-lpk.schema # via google, no original source found
|
||||
- rfc2307bis.schema # rfc2307bis version 2
|
||||
- samba.schema # centos samba 4.8.3
|
||||
notify: restart slapd
|
||||
|
||||
- name: copy check password config
|
||||
copy:
|
||||
dest: /etc/openldap/check_password.conf
|
||||
src: check_password.conf
|
||||
mode: 0644
|
||||
owner: root
|
||||
group: "{{ ansible_wheel }}"
|
||||
|
||||
- name: create slapd main config
|
||||
template:
|
||||
dest: /etc/openldap/slapd.conf
|
||||
src: slapd.conf.j2
|
||||
mode: 0640
|
||||
owner: root
|
||||
group: ldap
|
||||
notify: restart slapd
|
||||
|
||||
- name: add ldap aliases for root
|
||||
blockinfile:
|
||||
path: /root/.bash_profile
|
||||
block: |
|
||||
# use slapd.conf by default for slap commands
|
||||
alias slapadd='echo "run as user ldap"'
|
||||
alias slapcat='slapcat -f /etc/openldap/slapd.conf'
|
||||
alias slapindex='echo "run as user ldap"'
|
||||
alias slaptest='slaptest -f /etc/openldap/slapd.conf'
|
||||
|
||||
- name: enable slapd service
|
||||
service:
|
||||
name: slapd
|
||||
state: started
|
||||
enabled: true
|
134
roles/ldap/server/templates/slapd.conf.j2
Normal file
134
roles/ldap/server/templates/slapd.conf.j2
Normal file
|
@ -0,0 +1,134 @@
|
|||
#
|
||||
# See slapd.conf(5) for details on configuration options.
|
||||
# This file should NOT be world readable.
|
||||
#
|
||||
|
||||
# schema configs in different file
|
||||
include /etc/openldap/schema/core.schema
|
||||
include /etc/openldap/schema/cosine.schema
|
||||
include /etc/openldap/schema/inetorgperson.schema
|
||||
include /etc/openldap/schema/kerberos.schema
|
||||
include /etc/openldap/schema/openssh-lpk.schema
|
||||
include /etc/openldap/schema/ppolicy.schema
|
||||
include /etc/openldap/schema/rfc2307bis.schema
|
||||
include /etc/openldap/schema/samba.schema
|
||||
|
||||
# disable logging (TODO: check different levels)
|
||||
loglevel none
|
||||
|
||||
# allow ldap version 2 binds
|
||||
allow bind_v2
|
||||
|
||||
# require modern ciphers for access
|
||||
localSSF 128
|
||||
security ssf=128
|
||||
|
||||
# use random id based on hostname
|
||||
serverID {{ 4095 | random(seed=inventory_hostname) }}
|
||||
|
||||
# limit search result sizes without hard limit
|
||||
sizelimit size.soft=500
|
||||
sizelimit size.hard=none
|
||||
|
||||
# pid and args files
|
||||
pidfile /run/openldap/slapd.pid
|
||||
argsfile /run/openldap/slapd.args
|
||||
|
||||
# overlay modules to load
|
||||
modulepath /usr/lib64/openldap
|
||||
moduleload ppolicy.la
|
||||
moduleload syncprov.la
|
||||
#moduleload smbkrb5pwd.la
|
||||
moduleload constraint.la
|
||||
|
||||
# certificates and ciphers (unfortunately modern cipher suite didn't work)
|
||||
TLSCertificateFile {{ tls_certs }}/{{ ldap_server_cert }}.crt
|
||||
TLSCertificateKeyFile {{ tls_private }}/{{ ldap_server_cert }}.key
|
||||
TLSCACertificatePath /etc/openldap/certs
|
||||
TLSVerifyClient try
|
||||
TLSECName prime256v1
|
||||
TLSCipherSuite {{ tls_ciphers }}
|
||||
TLSProtocolMin 3.3
|
||||
|
||||
#####################################################################
|
||||
# database dc=foo,dc=sh configurations
|
||||
#####################################################################
|
||||
|
||||
database mdb
|
||||
# 1GB i guess we don't go beyond this
|
||||
maxsize 1073741824
|
||||
|
||||
suffix "dc=foo,dc=sh"
|
||||
rootdn "cn=manager,dc=foo,dc=sh"
|
||||
|
||||
overlay ppolicy
|
||||
ppolicy_default cn=pwdPolicy,ou=System,dc=foo,dc=sh
|
||||
ppolicy_hash_cleartext
|
||||
ppolicy_use_lockout
|
||||
password-hash {CRYPT}
|
||||
password-crypt-salt-format "$6$.8s"
|
||||
|
||||
overlay syncprov
|
||||
syncprov-checkpoint 100 10
|
||||
syncprov-sessionlog 100
|
||||
|
||||
overlay constraint
|
||||
constraint_attribute loginShell regex ^/bin/(bash|tcsh|zsh)$
|
||||
constraint_attribute uniqueMember uri ldap:///ou=People,dc=foo,dc=sh?entryDN?one?(objectClass=inetOrgPerson)
|
||||
|
||||
# database directory
|
||||
# chmod 700 so ldap:ldap can create encrypted backups with group readable
|
||||
# access without access to clear text data
|
||||
directory /srv/ldap
|
||||
|
||||
# for syncrepl
|
||||
index entryCSN,entryUUID,objectClass eq
|
||||
|
||||
# map root user to manager when authenticating via socket
|
||||
authz-regexp
|
||||
"gidNumber=0\\\+uidNumber=0,cn=peercred,cn=external,cn=auth"
|
||||
"cn=manager,dc=foo,dc=sh"
|
||||
# map rest of users authenticating via socket to correct ldap entries
|
||||
authz-regexp
|
||||
"gidNumber=([0-9]\+)\\\+uidNumber=([0-9]\+),cn=peercred,cn=external,cn=auth"
|
||||
"ldap:///dc=foo,dc=sh??sub?(&(uidNumber=$2)(objectClass=posixAccount))"
|
||||
|
||||
# require authentication for authenticated users that don't match above
|
||||
access to *
|
||||
by dn.children="cn=peercred,cn=external,cn=auth" auth
|
||||
by anonymous auth
|
||||
by * break
|
||||
|
||||
# allow self to change password
|
||||
access to attrs=userPassword
|
||||
by self write
|
||||
by * compare
|
||||
|
||||
# allow group owners to edit members
|
||||
access to dn.one=ou=Groups,dc=foo,dc=sh filter="(objectClass=groupOfUniqueNames)" attrs=owner,uniqueMember
|
||||
by dnattr=owner write
|
||||
by users read
|
||||
by * none
|
||||
|
||||
# allow self to change login shell
|
||||
access to dn.one=ou=People,dc=foo,dc=sh attrs=loginShell
|
||||
by self write
|
||||
by users read
|
||||
by * none
|
||||
|
||||
# block rest of queries to ou=System tree
|
||||
access to dn.sub=ou=System,dc=foo,dc=sh
|
||||
by * none
|
||||
|
||||
# for the rest allow users to read and block rest
|
||||
access to *
|
||||
by users read
|
||||
by * none
|
||||
|
||||
#####################################################################
|
||||
# database for monitoring (allow only access through local socket)
|
||||
#####################################################################
|
||||
database monitor
|
||||
access to *
|
||||
by sockurl=ldapi:/// read
|
||||
by * none
|
Loading…
Add table
Add a link
Reference in a new issue