sanic_jwt/authentication.py
async def _check_authentication(
        self, request, request_args, request_kwargs
    ):
        """
        Checks a request object to determine if that request contains a valid,
        and authenticated JWT.

        It returns a tuple:
        1. Boolean whether the request is authenticated with a valid JWT
        2. HTTP status code
        3. Reasons (if any) for a potential authentication failure
        """
        try:
            is_valid, status, reasons = await self._verify(
                request,
                request_args=request_args,
                request_kwargs=request_kwargs,
            )
        except Exception as e:
            logger.debug(e.args)
            if self.config.debug():
                raise e

            args = e.args if isinstance(e, SanicJWTException) else []

            raise exceptions.Unauthorized(*args)

        return is_valid, status, reasons

        Checks a request object to determine if that request contains a valid,
        and authenticated JWT.

        It returns a tuple:
        1. Boolean whether the request is authenticated with a valid JWT
        2. HTTP status code
        3. Reasons (if any) for a potential authentication failure
        
Checks a request object to determine if that request contains a valid,
and authenticated JWT.

It returns a tuple:
1. Boolean whether the request is authenticated with a valid JWT
2. HTTP status code
3. Reasons (if any) for a potential authentication failure
Checks a request object to determine if that request contains a valid and authenticated JWT . It returns a tuple : 1 . Boolean whether the request is authenticated with a valid JWT 2 . HTTP status code 3 . Reasons ( if any ) for a potential authentication failure
async def _check_authentication(
        self, request, request_args, request_kwargs
    ):
        try:
            is_valid, status, reasons = await self._verify(
                request,
                request_args=request_args,
                request_kwargs=request_kwargs,
            )
        except Exception as e:
            logger.debug(e.args)
            if self.config.debug():
                raise e
            args = e.args if isinstance(e, SanicJWTException) else []
            raise exceptions.Unauthorized(*args)
        return is_valid, status, reasons
async def _check_authentication ( self , request , request_args , request_kwargs ) : try : is_valid , status , reasons = await self . _verify ( request , request_args = request_args , request_kwargs = request_kwargs , ) except Exception as e : logger . debug ( e . args ) if self . config . debug ( ) : raise e args = e . args if isinstance ( e , SanicJWTException ) else [ ] raise exceptions . Unauthorized ( * args ) return is_valid , status , reasons
Checks a request object to determine if that request contains a valid,
and authenticated JWT.
Checks a request object to determine if that request contains a valid and authenticated JWT .
"""
        Checks a request object to determine if that request contains a valid,
        and authenticated JWT.

        It returns a tuple:
        1. Boolean whether the request is authenticated with a valid JWT
        2. HTTP status code
        3. Reasons (if any) for a potential authentication failure
        """
self
request
request_args
request_kwargs