Authenticating services

This commit is contained in:
Ritiek Malhotra
2020-04-02 04:14:07 +05:30
parent 2bb9a965f5
commit 121fcdcdf6
13 changed files with 157 additions and 12 deletions

View File

@@ -0,0 +1,19 @@
from abc import ABC
from abc import abstractmethod
class AuthorizeBase(ABC):
"""
Defined service authenticators must inherit from this abstract
base class and implement their own functionality for the below
defined methods.
"""
@abstractmethod
def authorize(self):
"""
This method must authorize with the corresponding service
and return an object that can be utilized in making
authenticated requests.
"""
pass