mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-07-12 17:34:16 -04:00
17 lines
427 B
Python
17 lines
427 B
Python
from flask_basicauth import BasicAuth
|
|
from flask import jsonify, request
|
|
|
|
class CustomBasicAuth(BasicAuth):
|
|
"""
|
|
Description:
|
|
|
|
Usage:
|
|
|
|
"""
|
|
|
|
def check_credentials(self, username, password):
|
|
# here, for example, you can search user in the database by passed `username` and `password`, etc.
|
|
return username == 'user' and password == 'password'
|
|
|
|
|
|
custom_basic_auth = CustomBasicAuth() |