[Samba] Automatically running a script on Samba PDC when Windows user changes his password

Felip Manyé apaxeros at gmail.com
Thu Aug 23 14:21:05 GMT 2007


Hello,

I've installed a Samba 3 PDC using LDAP authentication, along with the
smbldap tools, on Ubuntu GNU/Linux. Everything works fine and (XP Pro)
Windows clients can join my domain.
I would like Samba to automatically run a (home made) script on the PDC
server when the user changes his password on his machine in order to update
it on other servers (for instance our mail server uses another LDAP for
authentication, but there are still many accounts of this kind), so that the
user has to remember only one password for all these applications.
I've already had a look at the "passwd program" line in my smb.conf file. By
default it was commented like this:

#passwd program = /usr/sbin/smbldap-passwd ?u %u

and "ldap passwd sync" is set to Yes (which seems quite sensible since I use
LDAP authentication).
The matter is that I was unable to use this line to automatically run a
script as explained above. As an example I've tried to create a file (in a
directory with 777 permissions) with the "touch" command (passwd program =
touch mydirectory/myfile), but it has no effect. I may not have correctly
understood this feature, or maybe it cannot be used with LDAP
authentication.
Do you know whether this kind of trick is possible, and if so how to achieve
it ?

Thanks in advance,

Felip.


More information about the samba mailing list