forked from Nixius/authelia
1
0
Fork 0

Fix reset URL: hardcode correct base, extract token from .LinkURL

Authelia generates broken URLs (missing /reset-password/step2, has
%2F encoding). Instead of chaining replaces, hardcode the known-good
base URL and extract just the JWT token via split.

Made-with: Cursor
This commit is contained in:
Leopere 2026-03-04 18:23:47 -05:00
parent 0851d6f952
commit 7c9d40f538
Signed by: colin
SSH Key Fingerprint: SHA256:nRPCQTeMFLdGytxRQmPVK9VXY3/ePKQ5lGRyJhT5DY8
2 changed files with 2 additions and 2 deletions

View File

@ -6,7 +6,7 @@
<p>Hi {{ .DisplayName }},</p>
<p>You requested to set or reset your password for your <a href="https://bc.a250.ca">a250.ca</a> workspace.</p>
<p>Click the link below to choose your password. You will also need to enable two-factor authentication or a passkey.</p>
<p><a href="{{ replace "%2Flogin" "/login" .LinkURL }}">{{ .LinkText }}</a></p>
<p><a href="https://bc.a250.ca/login/reset-password/step2?token={{ index (split .LinkURL "token=") 1 }}">{{ .LinkText }}</a></p>
<p>If you did not request this, you can safely ignore this email &mdash; no changes will be made.</p>
<p style="color:#888;font-size:0.85em;">Requested from {{ .RemoteIP }}.</p>
</body>

View File

@ -6,7 +6,7 @@ You requested to set or reset your password for your a250.ca workspace (https://
Use the link below to choose your password. You will also need to enable two-factor authentication or a passkey.
{{ replace "%2Flogin" "/login" .LinkURL }}
https://bc.a250.ca/login/reset-password/step2?token={{ index (split .LinkURL "token=") 1 }}
If you did not request this, you can safely ignore this email — no changes will be made.