Inserting NT-Passwords in MySQL database
Hello once again, Please how can I insert into MySQL database, encrypted passwords for radius users. In an earlier mail I posted to the list, Phil suggested NT hash (MD4 of little-endian UTF-16 form password) since it was *not possible to do* *MD5 with mschap. * I have tried to do: insert into radcheck(userName,Attribute,op,value) values ('test','NT-Password',':=',NT-hash( 'password' )); but it failed because I guess it doesn't exist. I edited ntlm_auth module to specify the path for ntlm_auth like this #######/ etc/raddb/modules/ntlm_auth ###### exec ntlm_auth { wait = yes program = "/usr/bin/ntlm_auth --request-nt-key --domain=MYDOMAIN --username=%{mschap:User-Name} --password=%{User-Password}" } I dont know how to apply ntlm_auth to cleartext passwords to insert into MySQl database. How can I achieve encrypting password for radius users in MySQL using NT-Password. Thank You.
pamela pomary wrote:
Please how can I insert into MySQL database, encrypted passwords for radius users.
You use SQL inserts?
In an earlier mail I posted to the list, Phil suggested NT hash (MD4 of little-endian UTF-16 form password) since it was *not possible to do* *MD5 with mschap. * I have tried to do:
insert into radcheck(userName,Attribute,op,value) values ('test','NT-Password',':=',NT-hash( 'password' )); but it failed because I guess it doesn't exist.
Uh... does the SQL documentation say that "NT-Hash" will work?
I dont know how to apply ntlm_auth to cleartext passwords to insert into MySQl database.
You don't. You use the smbpasswd program. This is included with FreeRADIUS.
How can I achieve encrypting password for radius users in MySQL using NT-Password.
You use smbpassword to create the correct form of the password. You then put the 32 hex digits into SQL using SQL inserts. Alan DeKok.
Hi, i dont think your SQL is correct - NT hash is required in the insert. you can test this manually by using the 'smbencrypt' tool eg smbencrypt password will print out 2 values, an LM has and an NT hash eg LM Hash NT Hash -------------------------------- -------------------------------- E52CAC67419A9A224A3B108F3FA6CB6D 8846F7EAEE8FB117AD06BDD830B7586C stick the NT hash version into your SQL table for testing... alan
participants (3)
-
Alan Buxey -
Alan DeKok -
pamela pomary