syncronize Samba password with Unix(Ldap) password

Agnaldo Freitas afreitas at sei.ba.gov.br
Wed Feb 7 20:29:39 GMT 2007


Hi,

When i use smbldap-passwd from the prompt it is ok, but when i use /bin/passwd, although the password is changed it ask for the current user password. It should ask just the new password. Why ?!

root at netuno1 ~]# passwd samuel
Changing password for user samuel.
Enter login(LDAP) password:

If i use ldap passwd sync = yes, it shows(after CTRL+ALT+DEL) a message  telling "the passwords are diferent", and when i use:

unix password sync = yes, password program= ...smbldap-passwd and password chat = ...  

... you don't have permission.

obs: 1 -  I am use "pam password crypt" on ldap.conf      (with exop i had problem)

        2 - FDS with Simple Bind and crypt .

smb.conf

        ...  

        ldap passwd sync = no
        unix password sync = yes

        passwd program = /opt/IDEALX/sbin/smbldap-passwd -u %u
        passwd chat = "Changing password for*\nNew password*" %n\n "*Retype new password*" %n\n"
        ...

Log with (pam password change= yes in smb.conf):

I need  this solution to put the server on prodution.root at netuno1 ~]# cat /var/log/samba/coinf14.log |grep samuel|more
  smbldap_search: base => [dc=sei,dc=intranet], filter => [(&(uid=samuel)(objectclass=sambaSamAccount))], scope
=> [2]
  init_sam_from_ldap: Entry found for user: samuel
  pdb_set_username: setting username samuel, was
  pdb_set_nt_username: setting nt username samuel, was
  Looking up login cache for user samuel
  pdb_set_username: setting username samuel, was
  pdb_set_nt_username: setting nt username samuel, was
  Finding user samuel
  Trying _Get_Pwnam(), username as lowercase is samuel
  Get_Pwnam_internals did find user [samuel]!
  chgpasswd: Password change (as_root=Yes) for user: samuel
  smb_pam_start: PAM: Init user: samuel
  smb_pam_start: PAM: Init passed for user: samuel
  smb_pam_chauthtok: PAM: Password Change for User: samuel
  smb_pam_passchange: PAM: Password Change Failed for user samuel!


Log with (pam password change = no in smb.conf):

  smbldap_search: base => [dc=sei,dc=intranet], filter => [(&(uid=samuel)(objectclass=sambaSamAccount))], scope
=> [2]
  init_sam_from_ldap: Entry found for user: samuel
  pdb_set_username: setting username samuel, was
  pdb_set_nt_username: setting nt username samuel, was
  Looking up login cache for user samuel
  pdb_set_username: setting username samuel, was
  pdb_set_nt_username: setting nt username samuel, was
  Finding user samuel
  Trying _Get_Pwnam(), username as lowercase is samuel
  Get_Pwnam_internals did find user [samuel]!
  chgpasswd: Password change (as_root=Yes) for user: samuel
  chat_with_program: Dochild for user samuel (uid=0,gid=0) (as_root = Yes)
  Invoking '/opt/IDEALX/sbin/smbldap-passwd -u samuel' as password change program.
  New password*] received [Changing UNIX password for samuel
  chat_with_program: Child failed to change password: samuel




thanks,

Agnaldo







More information about the samba-technical mailing list