MCPcopy Create free account
hub / github.com/CodeFox-Repo/codefox / createRefreshToken

Method createRefreshToken

backend/src/auth/auth.service.ts:228–240  ·  view source on GitHub ↗
(user: User)

Source from the content-addressed store, hash-verified

226 /**
227 * Finish a reset.
228 *
229 * Single use falls out of how the token is signed: the key includes the
230 * current password hash, so the moment this saves a new one every link
231 * issued against the old password stops verifying. Nothing to store, and
232 * nothing to clean up.
233 */
234 async resetPassword(
235 token: string,
236 newPassword: string,
237 ): Promise<EmailConfirmationResponse> {
238 const bad = {
239 message: 'This reset link is invalid or has expired. Request a new one.',
240 success: false,
241 };
242
243 const parsed = parseResetToken(token);

Callers 2

loginMethod · 0.95
handleGoogleCallbackMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected