Compare commits
No commits in common. "5e07b3b7ddd2697872f68093ce033f920cf86d40" and "ecb06e812dc21070b675e92c81730aa31cb49a8b" have entirely different histories.
5e07b3b7dd
...
ecb06e812d
2 changed files with 3 additions and 19 deletions
|
@ -5,7 +5,6 @@ import flask_sqlalchemy
|
|||
import flask_praetorian
|
||||
import flask_cors
|
||||
import sys
|
||||
from password_util import get_random_password
|
||||
|
||||
db = flask_sqlalchemy.SQLAlchemy()
|
||||
guard = flask_praetorian.Praetorian()
|
||||
|
@ -132,12 +131,6 @@ def protected():
|
|||
"""
|
||||
return {'message': f'protected endpoint (allowed user {flask_praetorian.current_user().username})'}
|
||||
|
||||
@app.route('/api/protected/rcv_pw', methods=['GET'])
|
||||
# @flask_praetorian.auth_required
|
||||
def get_password():
|
||||
pw = get_random_password()
|
||||
print(pw)
|
||||
return pw
|
||||
|
||||
@app.route('/api/register', methods=['POST'])
|
||||
def register():
|
||||
|
|
|
@ -9,8 +9,7 @@ def get_random_value(list_length):
|
|||
random_select = randint(0, list_length)
|
||||
return random_select
|
||||
|
||||
|
||||
def get_random_password():
|
||||
def get_password():
|
||||
|
||||
first_part = [
|
||||
"Der Vogel",
|
||||
|
@ -18,19 +17,12 @@ def get_random_password():
|
|||
"Die Biene",
|
||||
"Ein Mensch",
|
||||
"Jemand",
|
||||
"Der Hund",
|
||||
"Der Kater",
|
||||
]
|
||||
|
||||
second_part = [
|
||||
"frisst",
|
||||
"küsst",
|
||||
"begrüsst",
|
||||
"besucht",
|
||||
"beeinflusst",
|
||||
"isst",
|
||||
"findet",
|
||||
"vergisst",
|
||||
]
|
||||
|
||||
third_part = [
|
||||
|
@ -48,7 +40,6 @@ def get_random_password():
|
|||
"auf der Wiese.",
|
||||
"im Garten.",
|
||||
"in der Kühltruhe.",
|
||||
"auf dem Balkon.",
|
||||
]
|
||||
|
||||
password = ""
|
||||
|
|
Loading…
Reference in a new issue