aldaketa izen ematean

This commit is contained in:
Aitzol 2023-11-28 09:42:46 +01:00
parent 249b0009a3
commit 5f3bbd0ff4
2 changed files with 2 additions and 1 deletions

3
app.py
View File

@ -655,7 +655,8 @@ def register(conf, username, firstname, surname, password, email, isFake, device
firstname, 'sn': surname, 'uid' : username, 'mail': email, 'active': False, 'fakeCn': isFake, firstname, 'sn': surname, 'uid' : username, 'mail': email, 'active': False, 'fakeCn': isFake,
'devices':device, 'ip':request.environ.get('HTTP_X_REAL_IP', request.remote_addr), 'lastLogin': ts, 'devices':device, 'ip':request.environ.get('HTTP_X_REAL_IP', request.remote_addr), 'lastLogin': ts,
'secureAuth': False} 'secureAuth': False}
new_user_dn = "cn="+firstname+" "+surname+" - "+username+",cn=users,"+conf['base'] #new_user_dn = "cn="+firstname+" "+surname+" - "+username+",cn=users,"+conf['base']
new_user_dn = "cn="+firstname+" "+surname+",cn=users,"+conf['base']
c.add(dn=new_user_dn,object_class=OBJECT_CLASS, attributes=attributes) c.add(dn=new_user_dn,object_class=OBJECT_CLASS, attributes=attributes)
#create/change user password #create/change user password
c.extend.standard.modify_password(new_user_dn, '', password) c.extend.standard.modify_password(new_user_dn, '', password)

Binary file not shown.