Samba has changed its LDAP usage between Etch and Lenny. Some new attributes where added. For the users updating from Etch to Lenny we need to provide an script which adds the needed attributes automatically.

New attributes

A diff between a LDAP tree of an Etch (terra) install of Debian Edu and a Lenny system where Samba modified the LDAP tree freely. The modifications where done on a convert from dbsam to ldap by pdbedit -i tdbsam -e ldapsam.

Only the attributes not found on Edu Etch are listed:

Key (attribute)

Value on the Lenny system

Description of the key

Proposed value for convert

sambaLogonTime

0

Timestamp of the last time the user loged into the domain

0

sambaLogoffTime

2147483647

Timestamp of the last time the user loged out of the domain (or a computer in the domain)

0

sambaKickoffTime

2147483647

Timestamp of the (next) automatic logoff

0

sambaPwdCanChange

1130714645

Timestamp of when the user is first allowed to change his/her password

0

sambaPwdMustChange

2147483647

Timestmap of when the password will expire

0

sambaPasswordHistory

64 zeros

Hashes of old passwords, not updated on default

64 zeros

sambaPwdLastSet

1130714645

Timestamp of when the password was last changed

4294967295 (do not expire password)

sambaLogonHours

42 capital Fes

Times when the user is allowed to login in GMT timezone

42 F

sambaBadPasswordCount

0

How often a wrong password was tried

0

sambaBadPasswordTime

0

Timestamp of when the last attempt was

0

Update script of Etch -> Lenny updates

This is about a proposed update script, which needs to be written.

One way to add the ' sambaPwdLastSet ' attribute to all Samba users is:

 ldapsearch -xZLLLWD 'cn=admin,ou=People,dc=skole,dc=skolelinux,dc=no' \
            -b 'ou=People,dc=skole,dc=skolelinux,dc=no' \
            -s one '(&(objectClass=sambaSamAccount)(!(sambaPwdLastSet=*)))' dn \
  | sed '/.\+/a\changetype: modify\nadd:sambaPwdLastSet\nsambaPwdLastSet: 2\n-' \
  > /etc/ldap/fixamba.ldif

 ldapmodify -xZWD 'cn=admin,ou=People,dc=skole,dc=skolelinux,dc=no' \
            -f /etc/ldap/fixamba.ldif

Official docs

This section lists issues and solutions appearing in the samba official documents.