Check if the given request can be skipped.

@param Request $request
@return bool
771059
public function canSkip(Request $request)
    {
        $routeName = $request->route()->getName();

        return in_array($routeName, $this->preventRouteNames, true);
    }
134822
public function canRequest(RequestInterface $request, array $options = []) : bool
    {
        $groupCanRequest = true;
        $this->_requestLimiters->rewind();
        while ($this->_requestLimiters->valid())
        {
            /** @var RequestLimiter $requestLimiter */
            $requestLimiter = $this->_requestLimiters->current();

            $canRequest = $requestLimiter->canRequest($request, $options);
            if ($groupCanRequest && !$canRequest)
            {
                $groupCanRequest = false;
                $this->_retryAfter = $requestLimiter->getRemainingSeconds();
            }

            $this->_requestLimiters->next();
        }

        return $groupCanRequest;
    }
1102015
private function tokenShouldNotBeChecked(Request $request) : bool
    {
        return in_array($request->getMethod(), [RequestMethods::GET, RequestMethods::HEAD, RequestMethods::OPTIONS]);
    }
730365
protected function requestIsInvalid(Request $request)
    {
        return empty($request->getBody()) && empty($request->getHeaders())
        && empty($request->getMethod()) && empty($request->getUrl());
    }
1064962
public function isCacheable(Request $request, $user)
    {
        if (!$this->active) {
            return false;
        }

        if ($user) {
            return false;
        }

        if ($request->hasSession() && $request->getSession()->get('no_cache', false)) {
            $request->getSession()->remove('no_cache');

            return false;
        }

        if ($this->env != 'prod') {
            return false;
        }

        if ($request->getMethod() != 'GET') {
            return false;
        }

        return true;
    }
1093232
protected static function checkServerPort(Request $request): bool
    {
        return $request->server->has('SERVER_PORT') && self::HTTPS === (int)$request->server->get('SERVER_PORT');
    }
784987
public function supportsApplication(Request $request): bool
    {
        return in_array($request->getApplicationId(), $this->supportedApplicationIds, true);
    }
106240
protected function isRememberMeRequested(Request $request)
    {
        if (true === ($this->options[static::OPTION_ALWAYS_REMEMBER_ME] ?? false)) {
            return true;
        }

        $parameter = $request->get($this->options[static::OPTION_REMEMBER_ME_PARAMETER]);

        return 'true' === $parameter || 'on' === $parameter || '1' === $parameter || 'yes' === $parameter || true === $parameter;
    }
561120
public function matches(Request $request)
    {
        $this->checkCasSessionParam($request);
        // Already logged using CAS or CAS path
        $casMatcher = new RequestMatcher('^/cas');
        $loginCheckMatcher = new RequestMatcher('^/login_check');
        $isCASTicket = $request->query->get('ticket') !== null ?
            preg_match('/^ST/', $request->query->get('ticket')) :
            false;
        if (
            !empty($request->getSession()->get('LOGGED_VIA_CAS')) ||
            ($this->casConfiguration->isActive() &&
                ($casMatcher->matches($request) || ($loginCheckMatcher->matches($request) && $isCASTicket))
            )
        ) {
            return false;
        }

        return true;
    }
1355013
public function cancelRedirectAction(Request $request)
    {
        $orderReference = $request->query->get('orderReference');
        $urlHmac = $request->query->get('sig');

        if ($orderReference) {
            $cancelRedirectTransfer = new PayoneCancelRedirectTransfer();
            $cancelRedirectTransfer->setOrderReference($orderReference);
            $cancelRedirectTransfer->setUrlHmac($urlHmac);

            $response = $this->getClient()->cancelRedirect($cancelRedirectTransfer);
        }

        return $this->redirectResponseInternal(PayoneControllerProvider::CHECKOUT_PAYMENT);
    }
302919
private function canHandleRedirect(Request $request)
    {
        $session = $request->getSession();
        return (is_a($session, '\Symfony\Component\HttpFoundation\Session\SessionInterface') ||  is_a($session, '\Illuminate\Contracts\Session\Session')) &&
            $request->headers->has(self::ORIGIN_REQUEST_HEADER);
    }
125472
protected static function checkHttpXForwardedSsl(Request $request): bool
    {
        return $request->server->has('HTTP_X_FORWARDED_SSL') && 'on' === $request->server->get('HTTP_X_FORWARDED_SSL');
    }
386825
public function deny(Request $request)
    {
        $authRequest = $this->getAuthRequestFromSession($request);

        if (is_array($uri = $authRequest->getClient()->getRedirectUri())) {
            $uri = Arr::first($uri);
        }

        $separator = $authRequest->getGrantTypeId() === 'implicit' ? '#' : '?';

        return $this->response->redirectTo(
            $uri.$separator.'error=access_denied&state='.$request->input('state')
        );
    }
1105018
public static function canBeUsedForRequest(Request $request)
    {
        return $request->has(self::CHUNK_UUID_INDEX) && $request->has(self::CHUNK_TOTAL_INDEX) &&
            $request->has(self::CHUNK_INDEX);
    }
298185
public function supports(Request $request)
    {
        return !empty($request->headers->get(self::AUTHORIZATION_HEADER)) || !empty($request->cookies->get(AuthResponseService::AUTH_COOKIE));
    }
932542
protected function secondsRemainingOnLockout( Request $request )
	{
		return UniversalBuilder::resolveClass( RateLimiter::class )->availableIn( $this->getThrottleKey( $request ) );
	}
1344194
protected function checkCsrfToken(Request $request)
    {
        if (!$request->headers->has(self::CSRF_TOKEN_HEADER)) {
            return false;
        }

        return $this->csrfTokenManager->isTokenValid(
            new CsrfToken(
                $this->csrfTokenIntention,
                $request->headers->get(self::CSRF_TOKEN_HEADER)
            )
        );
    }