diff options
author | clarkzjw <[email protected]> | 2023-02-23 15:37:48 -0800 |
---|---|---|
committer | clarkzjw <[email protected]> | 2023-02-23 15:37:48 -0800 |
commit | 4cee8500a51aff6d0a445a3a6259cafed92d4845 (patch) | |
tree | 1090256b48a76aae7afe2e10b860a02b43790807 /dbstore | |
parent | 31a2d111d1c0ceb2ebfd5bb5daf4ee0ab2de4eb4 (diff) | |
download | swarm2fediverse-4cee8500a51aff6d0a445a3a6259cafed92d4845.tar.gz |
bot: encrypt access_key with cryptography.fernet library
Diffstat (limited to 'dbstore')
-rw-r--r-- | dbstore/peewee_store.py | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/dbstore/peewee_store.py b/dbstore/peewee_store.py index d124de2..445816e 100644 --- a/dbstore/peewee_store.py +++ b/dbstore/peewee_store.py | |||
@@ -16,10 +16,8 @@ class BaseModel(Model): | |||
16 | 16 | ||
17 | class User(BaseModel): | 17 | class User(BaseModel): |
18 | telegram_user_id = CharField(unique=True, primary_key=True) | 18 | telegram_user_id = CharField(unique=True, primary_key=True) |
19 | # TODO: | 19 | access_key = CharField(max_length=256) |
20 | # add AES encryption to access_key | 20 | home_instance = CharField(max_length=256) |
21 | access_key = CharField(max_length=64) | ||
22 | home_instance = CharField(max_length=128) | ||
23 | state = CharField(max_length=128) | 21 | state = CharField(max_length=128) |
24 | client_id = CharField(max_length=128) | 22 | client_id = CharField(max_length=128) |
25 | client_secret = CharField(max_length=128) | 23 | client_secret = CharField(max_length=128) |