def _auth_resp_callback_func(self, context, internal_response):
        """
        This function is called by a backend module when the authorization is
        complete.

        :type context: satosa.context.Context
        :type internal_response: satosa.internal.InternalData
        :rtype: satosa.response.Response

        :param context: The request context
        :param internal_response: The authentication response
        :return: response
        """

        context.request = None
        internal_response.requester = context.state[STATE_KEY]["requester"]

        # If configured construct the user id from attribute values.
        if "user_id_from_attrs" in self.config["INTERNAL_ATTRIBUTES"]:
            subject_id = [
                "".join(internal_response.attributes[attr]) for attr in
                self.config["INTERNAL_ATTRIBUTES"]["user_id_from_attrs"]
            ]
            internal_response.subject_id = "".join(subject_id)

        if self.response_micro_services:
            return self.response_micro_services[0].process(
                context, internal_response)

        return self._auth_resp_finish(context, internal_response)
def _auth_resp_callback_func ( self , context , internal_response ) : context . request = None internal_response . requester = context . state [ STATE_KEY ] [ "requester" ] if "user_id_from_attrs" in self . config [ "INTERNAL_ATTRIBUTES" ] : subject_id = [ "" . join ( internal_response . attributes [ attr ] ) for attr in self . config [ "INTERNAL_ATTRIBUTES" ] [ "user_id_from_attrs" ] ] internal_response . subject_id = "" . join ( subject_id ) if self . response_micro_services : return self . response_micro_services [ 0 ] . process ( context , internal_response ) return self . _auth_resp_finish ( context , internal_response )
This function is called by a backend module when the authorization is
        complete.

        :type context: satosa.context.Context
        :type internal_response: satosa.internal.InternalData
        :rtype: satosa.response.Response

        :param context: The request context
        :param internal_response: The authentication response
        :return: response