-
-
Notifications
You must be signed in to change notification settings - Fork 48
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(api): introduce auth action to verify email for legacy accounts
This commit can be reverted once all email addresses have been verified. Usage: ```python from desecapi import models for user in models.User.objects.filter(email_verified__isnull=True, is_active=True).all(): user.send_confirmation_email('confirm-account', created=user.created) ```
- Loading branch information
1 parent
9022c0e
commit 9f07e2f
Showing
7 changed files
with
78 additions
and
0 deletions.
There are no files selected for viewing
24 changes: 24 additions & 0 deletions
24
api/desecapi/migrations/0021_authenticatednoopuseraction.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# Generated by Django 4.0.1 on 2022-01-19 14:41 | ||
|
||
from django.db import migrations, models | ||
import django.db.models.deletion | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
('desecapi', '0020_user_email_verified'), | ||
] | ||
|
||
operations = [ | ||
migrations.CreateModel( | ||
name='AuthenticatedNoopUserAction', | ||
fields=[ | ||
('authenticateduseraction_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='desecapi.authenticateduseraction')), | ||
], | ||
options={ | ||
'managed': False, | ||
}, | ||
bases=('desecapi.authenticateduseraction',), | ||
), | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
Hi there, | ||
|
||
You have registered with deSEC a long time ago (on {{ created|date:"Y-m-d" }}), probably to | ||
set up a DNS domain (e.g. under dedyn.io). At the time when you registered | ||
your account, we did not verify your email address. | ||
|
||
Our terms now require that deSEC account holders provide an up-to-date contact | ||
email address, in case we need to contact you (e.g. when there is a problem | ||
with your domain). We are currently cleaning our database and making sure | ||
that all addresses are verified. | ||
|
||
Therefore, if you would like to continue using your deSEC account, you now | ||
need to verify your email address. To do so, please use the following link | ||
(valid for {% widthratio link_expiration_hours 24 1 %} days): | ||
|
||
{{ confirmation_link.0 }} | ||
|
||
If you do not want to continue using deSEC, we will delete your account once | ||
the link has expired, without contacting you again. In case you miss the | ||
deadline, we invite you to sign up again with the same email address. | ||
|
||
We apologize for the slight inconvenience, and hope you enjoy deSEC! | ||
|
||
Stay secure, | ||
Nils |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
[deSEC] Important: Please confirm your deSEC DNS account |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters