[{"data":1,"prerenderedAt":444},["ShallowReactive",2],{"navigation":3,"\u002Fguides\u002Freset-password":203,"\u002Fguides\u002Freset-password-surround":439},[4,33,96,114,177],{"title":5,"path":6,"stem":7,"children":8,"icon":32},"Get started","\u002Fgetting-started","1.getting-started\u002F1.index",[9,12,17,22,27],{"title":10,"path":6,"stem":7,"icon":11},"Introduction","i-lucide-house",{"title":13,"path":14,"stem":15,"icon":16},"Install AuthEndpoints","\u002Fgetting-started\u002Finstallation","1.getting-started\u002F2.installation","i-lucide-download",{"title":18,"path":19,"stem":20,"icon":21},"Quick start","\u002Fgetting-started\u002Fquick-start","1.getting-started\u002F3.quick-start","i-lucide-play",{"title":23,"path":24,"stem":25,"icon":26},"Choose a sign-in stack","\u002Fgetting-started\u002Fchoose-a-sign-in-stack","1.getting-started\u002F4.choose-a-sign-in-stack","i-lucide-signpost",{"title":28,"path":29,"stem":30,"icon":31},"Use the AuthEndpoints skill with coding agents","\u002Fgetting-started\u002Fai-agents","1.getting-started\u002F5.ai-agents","i-lucide-bot","i-lucide-rocket",{"title":34,"path":35,"stem":36,"children":37,"icon":95},"Guides","\u002Fguides","2.guides\u002F01.index",[38,40,45,50,55,60,65,70,75,80,85,90],{"title":34,"path":35,"stem":36,"icon":39},"i-lucide-list-checks",{"title":41,"path":42,"stem":43,"icon":44},"Register users","\u002Fguides\u002Fregistration","2.guides\u002F02.registration","i-lucide-user-plus",{"title":46,"path":47,"stem":48,"icon":49},"Sign users in","\u002Fguides\u002Fsign-in","2.guides\u002F03.sign-in","i-lucide-log-in",{"title":51,"path":52,"stem":53,"icon":54},"Sign users out","\u002Fguides\u002Fsign-out","2.guides\u002F04.sign-out","i-lucide-log-out",{"title":56,"path":57,"stem":58,"icon":59},"Turn on two-factor authentication","\u002Fguides\u002Ftwo-factor","2.guides\u002F05.two-factor","i-lucide-smartphone",{"title":61,"path":62,"stem":63,"icon":64},"Reset a forgotten password","\u002Fguides\u002Freset-password","2.guides\u002F06.reset-password","i-lucide-key-round",{"title":66,"path":67,"stem":68,"icon":69},"Change a user's email or password","\u002Fguides\u002Fmanage-account","2.guides\u002F07.manage-account","i-lucide-user-cog",{"title":71,"path":72,"stem":73,"icon":74},"Add, rename, and remove passkeys","\u002Fguides\u002Fmanage-passkeys","2.guides\u002F08.manage-passkeys","i-lucide-scan-face",{"title":76,"path":77,"stem":78,"icon":79},"Link and unlink GitHub or Google accounts","\u002Fguides\u002Flink-external-accounts","2.guides\u002F09.link-external-accounts","i-lucide-link",{"title":81,"path":82,"stem":83,"icon":84},"Require step-up before sensitive actions","\u002Fguides\u002Fstep-up","2.guides\u002F10.step-up","i-lucide-shield-check",{"title":86,"path":87,"stem":88,"icon":89},"Call the API from a browser","\u002Fguides\u002Fbrowser-clients","2.guides\u002F11.browser-clients","i-lucide-globe",{"title":91,"path":92,"stem":93,"icon":94},"Prepare for production","\u002Fguides\u002Fproduction","2.guides\u002F12.production","i-lucide-factory","i-lucide-waypoints",{"title":97,"path":98,"stem":99,"children":100,"icon":113},"Composable endpoints","\u002Fcomposables","3.composables\u002F1.index",[101,104,108],{"title":102,"path":98,"stem":99,"icon":103},"How composition works","i-lucide-layout-grid",{"title":105,"path":106,"stem":107,"icon":39},"Composition requirements","\u002Fcomposables\u002Frequirements","3.composables\u002F2.requirements",{"title":109,"path":110,"stem":111,"icon":112},"Compose a custom auth stack","\u002Fcomposables\u002Frecipes","3.composables\u002F3.recipes","i-lucide-book-marked","i-lucide-blocks",{"title":115,"icon":116,"path":117,"stem":118,"children":119,"page":176},"Reference","i-lucide-book-open","\u002Fmodules","4.modules",[120,125,129,134,139,144,148,153,157,162,166,171],{"title":121,"path":122,"stem":123,"icon":124},"Endpoint reference","\u002Fmodules\u002Fendpoints","4.modules\u002F01.endpoints","i-lucide-route",{"title":126,"path":127,"stem":128,"icon":69},"Identity management module","\u002Fmodules\u002Fidentity-management","4.modules\u002F02.identity-management",{"title":130,"path":131,"stem":132,"icon":133},"Cookie sign-in module","\u002Fmodules\u002Fcookie-auth","4.modules\u002F03.cookie-auth","i-lucide-cookie",{"title":135,"path":136,"stem":137,"icon":138},"Identity bearer sign-in module","\u002Fmodules\u002Fbearer-auth","4.modules\u002F04.bearer-auth","i-lucide-key",{"title":140,"path":141,"stem":142,"icon":143},"JWT module","\u002Fmodules\u002Fjwt","4.modules\u002F05.jwt","i-lucide-fingerprint",{"title":145,"path":146,"stem":147,"icon":74},"Passkeys module","\u002Fmodules\u002Fpasskeys","4.modules\u002F06.passkeys",{"title":149,"path":150,"stem":151,"icon":152},"ReAuth module","\u002Fmodules\u002Freauth","4.modules\u002F07.reauth","i-lucide-shield-alert",{"title":154,"path":155,"stem":156,"icon":49},"External OAuth packages","\u002Fmodules\u002Fexternal-oauth","4.modules\u002F08.external-oauth",{"title":158,"path":159,"stem":160,"icon":161},"Configuration options","\u002Fmodules\u002Fconfiguration","4.modules\u002F09.configuration","i-lucide-settings",{"title":163,"path":164,"stem":165,"icon":84},"Antiforgery (CSRF) rules","\u002Fmodules\u002Fcsrf","4.modules\u002F10.csrf",{"title":167,"path":168,"stem":169,"icon":170},"Responses and errors","\u002Fmodules\u002Ferrors","4.modules\u002F11.errors","i-lucide-circle-alert",{"title":172,"path":173,"stem":174,"icon":175},"Rate-limit policies","\u002Fmodules\u002Frate-limits","4.modules\u002F12.rate-limits","i-lucide-gauge",false,{"title":178,"icon":179,"path":180,"stem":181,"children":182,"page":176},"Concepts","i-lucide-lightbulb","\u002Fconcepts","5.concepts",[183,188,193,198],{"title":184,"path":185,"stem":186,"icon":187},"AuthEndpoints compared with other options","\u002Fconcepts\u002Fcompare","5.concepts\u002F1.compare","i-lucide-git-compare",{"title":189,"path":190,"stem":191,"icon":192},"Stock Identity endpoints vs AuthEndpoints","\u002Fconcepts\u002Fstock-identity-vs-authendpoints","5.concepts\u002F2.stock-identity-vs-authendpoints","i-lucide-columns-2",{"title":194,"path":195,"stem":196,"icon":197},"Security model","\u002Fconcepts\u002Fsecurity-model","5.concepts\u002F3.security-model","i-lucide-shield",{"title":199,"path":200,"stem":201,"icon":202},"FAQ","\u002Fconcepts\u002Ffaq","5.concepts\u002F4.faq","i-lucide-circle-help",{"id":204,"title":61,"body":205,"description":432,"extension":433,"links":434,"meta":435,"navigation":436,"path":62,"seo":437,"stem":63,"__hash__":438},"docs\u002F2.guides\u002F06.reset-password.md",{"type":206,"value":207,"toc":418},"minimark",[208,217,239,244,249,253,333,339,344,362,365,369,385,399,403],[209,210,211,212,216],"p",{},"Use these steps when a user forgot their password. The routes are on the management group (facade default ",[213,214,215],"code",{},"\u002Fidentity","). They need no CSRF token and no session.",[209,218,219,222,223,226,227,230,231,234,235,238],{},[213,220,221],{},"POST \u002Fidentity\u002FforgotPassword"," always returns ",[213,224,225],{},"200",". AuthEndpoints sends mail only when the account exists and its email is confirmed. It calls ",[213,228,229],{},"IEmailSender\u003CTUser>.SendPasswordResetCodeAsync"," with an HTML-encoded Base64Url reset code. You build the reset screen and the mail template. The reset body is Identity's ",[213,232,233],{},"ResetPasswordRequest",": ",[213,236,237],{},"{ \"email\", \"resetCode\", \"newPassword\" }",".",[240,241,243],"h2",{"id":242},"video","Video",[245,246],"youtube-embed",{"id":247,"title":248},"_3wSxAQ9588","Forgot password and reset password",[240,250,252],{"id":251},"steps","Steps",[254,255,256,265,273,283,298,304,312,320],"ol",{},[257,258,259,260,264],"li",{},"Collect the account email on a ",[261,262,263],"strong",{},"Forgot password"," screen.",[257,266,267,269,270,238],{},[213,268,221],{}," with body ",[213,271,272],{},"{ \"email\" }",[257,274,275,276,278,279,282],{},"On ",[213,277,225],{},", show ",[261,280,281],{},"Check your email"," (same copy for known and unknown addresses). Then use one of the host patterns below for the reset screen.",[257,284,285,286,289,290,293,294,297],{},"Build the reset mail in your ",[213,287,288],{},"IEmailSender\u003CTUser>"," implementation. AuthEndpoints passes ",[213,291,292],{},"HtmlEncoder.Default.Encode(base64UrlCode)"," into ",[213,295,296],{},"SendPasswordResetCodeAsync",". Decode HTML entities before the user copies the code or before you put it in a link query. If you embed the code in HTML again, re-encode for markup.",[257,299,300,301,264],{},"Collect email, reset code, and new password on a ",[261,302,303],{},"Reset password",[257,305,306,269,309,311],{},[213,307,308],{},"POST \u002Fidentity\u002FresetPassword",[213,310,237],{},". Submit the Base64Url value (not the Identity raw token).",[257,313,275,314,316,317,238],{},[213,315,225],{},", sign in with the new password. See ",[318,319,46],"a",{"href":47},[257,321,275,322,325,326,329,330,238],{},[213,323,324],{},"400"," validation problem ",[213,327,328],{},"InvalidToken",", show a generic error. AuthEndpoints returns that code for a bad code, an unknown email, and an unconfirmed email alike. Password-rule failures return their own codes, such as ",[213,331,332],{},"PasswordTooShort",[240,334,336,337],{"id":335},"host-patterns-after-forgot-200","Host patterns after forgot ",[213,338,225],{},[340,341,343],"h3",{"id":342},"same-session-auto-nav-safer-default","Same-session auto-nav (safer default)",[209,345,346,347,349,350,353,354,357,358,361],{},"After forgot returns ",[213,348,225],{},", navigate the SPA to the reset page with ",[261,351,352],{},"email only"," prefilled (query string or ",[213,355,356],{},"sessionStorage","). The user pastes ",[213,359,360],{},"resetCode"," from the mail.",[209,363,364],{},"No reset token in the URL. Fits the same browser that started forgot.",[340,366,368],{"id":367},"email-deep-link-cross-device","Email deep link (cross-device)",[209,370,371,372,374,375,378,379,381,382,384],{},"In ",[213,373,296],{},", include a host-owned link to your reset page with ",[213,376,377],{},"email"," and ",[213,380,360],{}," (or ",[213,383,213],{},") query params. Still show the code in the mail as a paste fallback.",[209,386,387,388,390,391,394,395,398],{},"Stock forgot uses ",[213,389,296],{},", not ",[213,392,393],{},"SendPasswordResetLinkAsync",". A clickable link is entirely your mail template (or a custom pipeline you build). Query tokens can leak through history, ",[213,396,397],{},"Referer",", and logs. Prefer same-session auto-nav when the user resets on the same device.",[240,400,402],{"id":401},"related","Related",[404,405,406,410,414],"ul",{},[257,407,408],{},[318,409,46],{"href":47},[257,411,412],{},[318,413,41],{"href":42},[257,415,416],{},[318,417,126],{"href":127},{"title":419,"searchDepth":420,"depth":421,"links":422},"",1,2,[423,424,425,431],{"id":242,"depth":421,"text":243},{"id":251,"depth":421,"text":252},{"id":335,"depth":421,"text":426,"children":427},"Host patterns after forgot 200",[428,430],{"id":342,"depth":429,"text":343},3,{"id":367,"depth":429,"text":368},{"id":401,"depth":421,"text":402},"Request a reset mail, set a new password, then sign in.","md",null,{},{"icon":64},{"title":61,"description":432},"uTFXP--Nm59VJDHF35s7t4bYo2c7fUbbRcxuTJAMjCo",[440,442],{"title":56,"path":57,"stem":58,"description":441,"icon":59,"children":-1},"Turn authenticator two-factor authentication on and off, and issue recovery codes.",{"title":66,"path":67,"stem":68,"description":443,"icon":69,"children":-1},"Read account info, change the password, and change the email after the user confirms the new address.",1791096170307]