| 97 | |
| 98 | The certificate returned by the challenge is signed by the testbed. |
| 99 | |
| 100 | === Password Changes === |
| 101 | |
| 102 | The password is a unique user feature that is not in the profile because of its role in authentication. When a user needs to change their password there are two API calls that can be used. |
| 103 | |
| 104 | If the user knows their current (or expired) password, they can authenticate using the standard challenge response protocol and then call |
| 105 | |
| 106 | * '''Service:''' Users |
| 107 | * '''Operation:''' changePassword |
| 108 | * '''Input Parameters:''' |
| 109 | * uid - the userid to change (note that an admin may change others passwords) |
| 110 | * newPass - the new passowrd |
| 111 | * '''Return Values''': |
| 112 | * a boolean, true if successful, but most errors will throw a fault |
| 113 | |
| 114 | We expect that the web interface will handle issues like confirming user input to a password change page. The changePassword call just makes the change directly. |
| 115 | |
| 116 | If a user has forgotten their password, the user can request a password challenge, sent to them at their profile e-mail address. The challenge is a 64-bit number that can be used to call changePasswordChallenge without logging in. To request a challenge, the web interface calls: |
| 117 | |
| 118 | * '''Service:''' Users |
| 119 | * '''Operation:''' requestPasswordReset |
| 120 | * '''Input Parameters:''' |
| 121 | * uid - the userid to change |
| 122 | * urlPrefix - a string prefixed to the challenge ID in the mail sent to the user |
| 123 | * '''Return Values''': |
| 124 | * a boolean, true if successful, but most errors will throw a fault |
| 125 | |
| 126 | Again, we expect this call to generally be made from a web interface that will then want to present an input form to the in order to reset their password. The urlPrefix field provides that hook. A web interface running on !https://niftydeter.com might call requestPasswordReset with parameters 'forgetfuluser' and '!https://niftydeter.com/reset.html?challenge='. After that call forgetfuluser will get e-mail asking him or her to access the web page at !https://niftydeter.com/reset.html?challenge=1283548127541824, allowing {{{niftydeter.com}}} to present their password change interface, and do error checking, ete. on the new password. |
| 127 | |
| 128 | Each challenge is valid for 2 hours, and they are rate limited so only a few can be outstanding. |
| 129 | |
| 130 | With a valid challenge in hand, the web interface can call |
| 131 | |
| 132 | * '''Service:''' Users |
| 133 | * '''Operation:''' changePasswordChallenge |
| 134 | * '''Input Parameters:''' |
| 135 | * challengeID - the 64-bit number from the e-mail |
| 136 | * newPass - the new passowrd |
| 137 | * '''Return Values''': |
| 138 | * a boolean, true if successful, but most errors will throw a fault |
| 139 | |