def __init__(self, message=""): """ HttpUnauthorized constructor :param message: String, message of the exception. Ie, "Unauthorized access" """ Unauthorized.__init__(self) self.description = message
def __init__(self, stomach, stale=False): Unauthorized.__init__(self) realm = stomach.realm nonce = stomach.gen_nonce() qop = stomach.qop self.config = (realm, nonce, [qop], None, 'MD5', stale)
def __init__( self, description="Unauthorized", admin_only=False, error=None, error_description=None, ): self.description = description self.www_auth_value = self.__get_wwww_auth_value( admin_only, error, error_description) Unauthorized.__init__(self, description=description, response=None, www_authenticate=None)
def __init__(self, sync_type): Unauthorized.__init__(self) self.sync_type = sync_type