class CsrfMiddleware (View source)

Store current request data and clear old request data

Methods

__construct(Csrf $csrf)

Constructor.

ResponseInterface
handle(RequestInterface $request, Closure $next, mixed $action = -1)

Reject requests that fail nonce validation.

Details

__construct(Csrf $csrf)

Constructor.

Parameters

Csrf $csrf

ResponseInterface handle(RequestInterface $request, Closure $next, mixed $action = -1)

Reject requests that fail nonce validation.

Parameters

RequestInterface $request
Closure $next
mixed $action

Return Value

ResponseInterface

Exceptions

InvalidCsrfTokenException