I usually do this:
for user in db(db.auth_user).select():
auth.email_reset_password(user)
and it emails each of them a password reset link.
On Friday, 13 June 2014 12:45:25 UTC-5, Michael Beller wrote:
>
> Thanks Massimo, Is there a method to force a user to change their
> password, e.g., after uploading a list of users?
>
> On Friday, June 13, 2014 1:07:32 PM UTC-4, Massimo Di Pierro wrote:
>>
>> Good question.
>>
>> registration_id is used by web2py with federated authentication to map a
>> local user to the federated id. For example the id could be a google id or
>> an openid of a cas is.
>>
>> registration_key is a random key assigned to the user when they register
>> if the registration requires verification. It is user to authenticate user
>> in the verify function until the email is verified. Once the email is
>> verified, the registration_key is set to "".
>> if the registration requires approval, after email verification, the
>> registration_key is set to "pending" and the administrator has to manually
>> deleted to approve the user.
>>
>> At any point the administrator can set a user registration_key to
>> "blocked" to prevent the user from logging in.
>>
>> The password_reset_key is the uuid used to identify a user when they ask
>> for a password reset link. the uuid appears in the link and expires when
>> the user resets the password.
>>
>>
>> On Friday, 13 June 2014 09:50:48 UTC-5, Michael Beller wrote:
>>>
>>> Also, what is the "password reset key" used for?
>>>
>>> I see in some posts information about "registration key" but not
>>> "registration identifier" - what is the identifier used for?
>>>
>>> if registration_key=='' : user can login
>>>
>>> if registration_key=='blocked' : user account is blocked
>>>
>>> if registration_key=='pending' : user account requires approval
>>>
>>> if registration_key==<uuid> : user account requires email verification
>>>
>>
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
---
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.