mirror of
https://github.com/etesync/server
synced 2024-11-25 18:28:46 +00:00
Rename encryptedSeckey to encryptedContent.
This commit is contained in:
parent
7842bd4d9c
commit
ad184f0ac3
18
django_etesync/migrations/0014_auto_20200602_1558.py
Normal file
18
django_etesync/migrations/0014_auto_20200602_1558.py
Normal file
@ -0,0 +1,18 @@
|
||||
# Generated by Django 3.0.3 on 2020-06-02 15:58
|
||||
|
||||
from django.db import migrations
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('django_etesync', '0013_collectionmemberremoved'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.RenameField(
|
||||
model_name='userinfo',
|
||||
old_name='encryptedSeckey',
|
||||
new_name='encryptedContent',
|
||||
),
|
||||
]
|
@ -214,7 +214,7 @@ class UserInfo(models.Model):
|
||||
version = models.PositiveSmallIntegerField(default=1)
|
||||
loginPubkey = models.BinaryField(editable=True, blank=False, null=False)
|
||||
pubkey = models.BinaryField(editable=True, blank=False, null=False)
|
||||
encryptedSeckey = models.BinaryField(editable=True, blank=False, null=False)
|
||||
encryptedContent = models.BinaryField(editable=True, blank=False, null=False)
|
||||
salt = models.BinaryField(editable=True, blank=False, null=False)
|
||||
|
||||
def __str__(self):
|
||||
|
@ -333,11 +333,11 @@ class InvitationAcceptSerializer(serializers.Serializer):
|
||||
|
||||
class UserSerializer(serializers.ModelSerializer):
|
||||
pubkey = BinaryBase64Field(source='userinfo.pubkey')
|
||||
encryptedSeckey = BinaryBase64Field(source='userinfo.encryptedSeckey')
|
||||
encryptedContent = BinaryBase64Field(source='userinfo.encryptedContent')
|
||||
|
||||
class Meta:
|
||||
model = User
|
||||
fields = (User.USERNAME_FIELD, User.EMAIL_FIELD, 'pubkey', 'encryptedSeckey')
|
||||
fields = (User.USERNAME_FIELD, User.EMAIL_FIELD, 'pubkey', 'encryptedContent')
|
||||
|
||||
|
||||
class UserInfoPubkeySerializer(serializers.ModelSerializer):
|
||||
@ -362,7 +362,7 @@ class AuthenticationSignupSerializer(serializers.Serializer):
|
||||
salt = BinaryBase64Field()
|
||||
loginPubkey = BinaryBase64Field()
|
||||
pubkey = BinaryBase64Field()
|
||||
encryptedSeckey = BinaryBase64Field()
|
||||
encryptedContent = BinaryBase64Field()
|
||||
|
||||
def create(self, validated_data):
|
||||
"""Function that's called when this serializer creates an item"""
|
||||
|
Loading…
Reference in New Issue
Block a user