feat: added endpoints: auth, pofile, account, keyring
This commit is contained in:
@@ -5,6 +5,7 @@ import secrets
|
||||
|
||||
from api.db.connection.session import get_connection
|
||||
from api.db.tables.account import account_table, account_keyring_table, AccountRole, KeyType, KeyStatus
|
||||
from api.utils.key_id_gen import KeyIdGenerator
|
||||
|
||||
INIT_LOCK_FILE = "../init.lock"
|
||||
DEFAULT_LOGIN = "vorkout"
|
||||
@@ -39,6 +40,7 @@ async def init():
|
||||
create_key_query = account_keyring_table.insert().values(
|
||||
owner_id=user_id,
|
||||
key_type=KeyType.PASSWORD,
|
||||
key_id=KeyIdGenerator()
|
||||
key_value=hashed_password,
|
||||
status=KeyStatus.ACTIVE,
|
||||
)
|
||||
|
Reference in New Issue
Block a user