Demosthene-OR
commited on
Commit
•
cfea428
1
Parent(s):
1848052
Update main.py
Browse files
main.py
CHANGED
@@ -97,6 +97,7 @@ def authenticate(authorisation: str = Header(None)):
|
|
97 |
if scheme != 'Basic':
|
98 |
raise HTTPException(status_code=401, detail="Utilisateur non authorisé "+scheme)
|
99 |
username, password = credentials.split(":")
|
|
|
100 |
if username not in users_credentials or users_credentials[username] != password:
|
101 |
raise HTTPException(status_code=401, detail="Utilisateur non authorisé "+username+":"+password)
|
102 |
except Exception as e:
|
|
|
97 |
if scheme != 'Basic':
|
98 |
raise HTTPException(status_code=401, detail="Utilisateur non authorisé "+scheme)
|
99 |
username, password = credentials.split(":")
|
100 |
+
print("username="+username+" password="+password)
|
101 |
if username not in users_credentials or users_credentials[username] != password:
|
102 |
raise HTTPException(status_code=401, detail="Utilisateur non authorisé "+username+":"+password)
|
103 |
except Exception as e:
|