zergio
2004-Jun-02 13:22 UTC
[Samba] Unable to execute program from smbldap-passwd.pl om samba 3.0.4
Hello! Recently I've migrated from samba 2.2.8a to 3.0.4. I use ldap as user database backend. To synchronize unix password the smbldap-passwd.pl script is used. But I need to sync virtual mail passwords as well. That is why I added to the script few lines of code. Mainly I call external programs. The code is like this: system("/etc/cron.hourly/sqwebmail-cron-cleancache"); When I run smbldap-passwd.pl script from command line it works just fine, however when samba calls it, unix and samba passwords got changed. But my code, which I added, looks like never been called at all. samba 2.2.8a worked fine. I suspect the samba restrict execution of external programs by passwd program. If it so, is there any workaround? Thank you in advance.
Jérôme Tournier
2004-Jun-02 14:17 UTC
[Samba] Unable to execute program from smbldap-passwd.pl om samba 3.0.4
Le Wed, Jun 02, 2004 at 04:21:59PM +0300, zergio a ecrit:> When I run smbldap-passwd.pl script from command line it works just > fine, however when samba calls it, unix and samba passwords got changed. > But my code, which I added, looks like never been called at all.for smbldap-passwd.pl to be called, you need to add in smb.conf : 'unix password sync = Yes' I know this is strange for ldap backend, but the man page said that. Next, you need to patch smbldap-passwd.pl (in 3 different places) so that you have only the <STDIN> between "stty -echo" and "stty echo". For example: system "stty -echo"; chomp($pass=<STDIN>); system "stty echo"; print "\n"; and not system "stty -echo"; chomp($pass=<STDIN>); print "\n"; system "stty echo"; i am sorry, i can't send a patch because i don't have old sources with me :-( -- J?r?me
Apparently Analagous Threads
- samba 3.0.2a (ported from 2.2.8a) with LDAP failed to add machine account
- Re: [sqwebmail] vpopmail+mysql and sqwebmail authentication problems]
- smbldap-tools, setting password on command line?
- smbldap-tools and joining workstation to domain
- [PATCH V3 6/8] Cleancache: btrfs hooks for cleancache