filters\auth\AuthMethod handleFailure()

handleFailure() public method Handles authentication failure. The implementation should normally throw UnauthorizedHttpException to indicate authentication failure. public void handleFailure ( $response )$response yii\web\Response throws yii\web\UnauthorizedHttpException

filters\auth\AuthMethod challenge()

challenge() public method Generates challenges upon authentication failure. For example, some appropriate HTTP headers may be generated. public void challenge ( $response )$response yii\web\Response

filters\auth\AuthMethod beforeAction()

beforeAction() public method This method is invoked right before an action is to be executed (after all possible filters.) You may override this method to do last-minute preparation for the action. public boolean beforeAction ( $action )$action yii\base\Action The action to be executed. return boolean Whether the action should continue to be executed.

filters\auth\AuthMethod $user

$user public property The user object representing the user authentication status. If not set, the user application component will be used. public yii\web\User $user = null

filters\auth\AuthMethod $response

$response public property The response to be sent. If not set, the response application component will be used. public yii\web\Response $response = null

filters\auth\AuthMethod $request

$request public property The current request. If not set, the request application component will be used. public yii\web\Request $request = null

filters\auth\AuthMethod $optional

$optional public property (available since version 2.0.7) List of action IDs that this filter will be applied to, but auth failure will not lead to error. It may be used for actions, that are allowed for public, but return some additional data for authenticated users. Defaults to empty, meaning authentication is not optional for any action. Since version 2.0.10 action IDs can be specified as wildcards, e.g. site/*. See also isOptional(). public array $optional = []

filters\auth\AuthInterface handleFailure()

handleFailure() public abstract method Handles authentication failure. The implementation should normally throw UnauthorizedHttpException to indicate authentication failure. public abstract void handleFailure ( $response )$response yii\web\Response throws yii\web\UnauthorizedHttpException

filters\auth\AuthInterface challenge()

challenge() public abstract method Generates challenges upon authentication failure. For example, some appropriate HTTP headers may be generated. public abstract void challenge ( $response )$response yii\web\Response

filters\auth\AuthInterface authenticate()

authenticate() public abstract method Authenticates the current user. public abstract yii\web\IdentityInterface authenticate ( $user, $request, $response )$user yii\web\User $request yii\web\Request $response yii\web\Response return yii\web\IdentityInterface The authenticated user identity. If authentication information is not provided, null will be returned. throws yii\web\UnauthorizedHttpException if authentication information is provided but is invalid.