-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[WIP] Add model fields for storing AWS identity information.
We want to verify a person's AWS identity in order to permit them to access restricted resources via direct cloud APIs; and possibly for other purposes in the future. An AWS account ID is not an identity. An account may contain many identities (known as "userids" or "unique IDs"), which might or might not belong to the same person. (Even if they do all belong to the same person, it doesn't mean that person wants or should want to give all of their identities the ability to access sensitive data.) Here, we add fields to store the userid alongside the account ID (which is still retained, since it may be of interest in the future), and to store the date and time that the person's credentials were verified.
- Loading branch information
Benjamin Moody
committed
Oct 30, 2023
1 parent
078df56
commit e655251
Showing
3 changed files
with
51 additions
and
2 deletions.
There are no files selected for viewing
29 changes: 29 additions & 0 deletions
29
physionet-django/user/migrations/0058_cloudinformation_aws_userid_and_more.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,29 @@ | ||
# Generated by Django 4.1.10 on 2023-10-27 22:00 | ||
|
||
from django.db import migrations, models | ||
import user.validators | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
("user", "0057_alter_cloudinformation_aws_id"), | ||
] | ||
|
||
operations = [ | ||
migrations.AddField( | ||
model_name="cloudinformation", | ||
name="aws_userid", | ||
field=models.CharField( | ||
blank=True, | ||
max_length=30, | ||
null=True, | ||
validators=[user.validators.validate_aws_userid], | ||
), | ||
), | ||
migrations.AddField( | ||
model_name="cloudinformation", | ||
name="aws_verification_datetime", | ||
field=models.DateTimeField(null=True), | ||
), | ||
] |
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