Feature complete!
Maybe some renaming/refactoring later
This commit is contained in:
parent
feddecd5e1
commit
32e153801e
4 changed files with 16 additions and 2 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -1 +1,2 @@
|
|||
venv/
|
||||
db.sqlite3
|
||||
|
|
13
README.md
13
README.md
|
@ -1,5 +1,18 @@
|
|||
## Introduction
|
||||
|
||||
This service returns a valid ungleichotp token that can be used to
|
||||
proof that you could connect to us.
|
||||
|
||||
Use case:
|
||||
|
||||
Run this
|
||||
|
||||
## Setup
|
||||
|
||||
```
|
||||
pip install -r requirements.txt
|
||||
```
|
||||
|
||||
## Run
|
||||
|
||||
Use your favorite uwsgi configuration or
|
||||
|
|
|
@ -6,7 +6,7 @@ from django.conf import settings
|
|||
|
||||
def index(request):
|
||||
answer = {}
|
||||
answer['token'] = pyotp.TOTP(settings.UNGLEICHOTP['UNGLEICHOTPSEED'])
|
||||
answer['token'] = pyotp.TOTP(settings.UNGLEICHOTP['UNGLEICHOTPSEED']).now()
|
||||
answer['name'] = settings.UNGLEICHOTP['UNGLEICHOTPNAME']
|
||||
answer['realm'] = settings.UNGLEICHOTP['UNGLEICHOTPREALM']
|
||||
|
||||
|
|
|
@ -17,5 +17,5 @@ from django.urls import path, include
|
|||
|
||||
|
||||
urlpatterns = [
|
||||
path('', include('returnok.urls')
|
||||
path('', include('returnok.urls'))
|
||||
]
|
||||
|
|
Loading…
Reference in a new issue