Philip Washington
2006-Jan-18 01:00 UTC
[Samba] Single sign on with SambaPDC and web server
We are using SambaPDC-LDAP and we have a Web Interface using PHP to our database. I have asked our developer to come up with a way to use the password stored in LDAP so we would have the same login throughout our site. He told me that after a day of looking he couldn't figure out how to translate the Username and Password into the SambaNTPassword or the LM password on the LDAP server. I was wondering if anyone here could point me in the direction for howto's on this. I thought it was a fairly simple md5 hash of the username and password but apparently not. Thanks in advance.
On Tue, 2006-01-17 at 19:01 -0600, Philip Washington wrote:> We are using SambaPDC-LDAP and we have a Web Interface using PHP to our > database. I have asked our developer to come up with a way to use the > password stored in LDAP so we would have the same login throughout our > site. He told me that after a day of looking he couldn't figure out how > to translate the Username and Password into the SambaNTPassword or the > LM password on the LDAP server. I was wondering if anyone here could > point me in the direction for howto's on this. > I thought it was a fairly simple md5 hash of the username and password > but apparently not. >---- I'm quite sure that you can find the code in phpldapadmin as that is capable of creating the hashed password. Also - a google for mkntpasswd would likely give you a 'c' program to do the same Craig
The smbldap-tools contains smbpasswd which will change all 3 paswords. That is probably the best and easiest way to work with the passwords. Philip Washington wrote:> We are using SambaPDC-LDAP and we have a Web Interface using PHP to our > database. I have asked our developer to come up with a way to use the > password stored in LDAP so we would have the same login throughout our > site. He told me that after a day of looking he couldn't figure out how > to translate the Username and Password into the SambaNTPassword or the > LM password on the LDAP server. I was wondering if anyone here could > point me in the direction for howto's on this. I thought it was a fairly > simple md5 hash of the username and password but apparently not. > > Thanks in advance.-- -Michael George Ideal Solutions, LLC