expephalon-smsotp/totp/models.py
Klaus-Uwe Mitterer d549897186 Too many things to remember all of them
Finally got the mail queue working
Oh yeah, queueing
Added a TOTP provider which doesn't do anything much yet
Probably a hell of a lot of other things that I just can't remember
2020-05-13 12:38:37 +02:00

12 lines
356 B
Python

from django.db.models import Model, CharField, ForeignKey, CASCADE, DateTimeField
from django.contrib.auth import get_user_model
from dbsettings.functions import getValue
import pyotp
# Create your models here.
class TOTPUser(Model):
secret = CharField(max_length=32, default=pyotp.random_base32())
user = ForeignKey(get_user_model(), CASCADE)