fix: require redirect url to end with .ente.io

This commit is contained in:
httpjamesm 2023-12-28 02:41:33 -05:00
parent a59b3d8d9c
commit e93563ce78
No known key found for this signature in database

View file

@ -33,7 +33,7 @@ const PasskeysFlow = () => {
const redirectURL = new URL(redirect); const redirectURL = new URL(redirect);
if (process.env.NEXT_PUBLIC_DISABLE_REDIRECT_CHECK !== 'true') { if (process.env.NEXT_PUBLIC_DISABLE_REDIRECT_CHECK !== 'true') {
if (redirect !== '' && !redirectURL.host.endsWith('ente.io')) { if (redirect !== '' && !redirectURL.host.endsWith('.ente.io')) {
setInvalidInfo(true); setInvalidInfo(true);
setLoading(false); setLoading(false);
return; return;