HumHub Documentation (unofficial)

NotBeforeChecker
in package
implements ClaimChecker, HeaderChecker

FinalYes

This class is a claim checker.

When the "nbf" is present, it will compare the value with the current timestamp.

Table of Contents

Interfaces

ClaimChecker
HeaderChecker

Constants

NAME  = 'nbf'

Properties

$allowedTimeDrift  : int
$protectedHeaderOnly  : bool

Methods

__construct()  : mixed
checkClaim()  : void
When the token has the applicable claim, the value is checked.
checkHeader()  : void
This method is called when the header parameter is present.
protectedHeaderOnly()  : bool
When true, the header parameter to be checked MUST be set in the protected header of the token.
supportedClaim()  : string
The method returns the claim to be checked.
supportedHeader()  : string
The method returns the header parameter to be checked.

Constants

Properties

Methods

__construct()

public __construct([int $allowedTimeDrift = 0 ][, bool $protectedHeaderOnly = false ]) : mixed
Parameters
$allowedTimeDrift : int = 0
$protectedHeaderOnly : bool = false

checkClaim()

When the token has the applicable claim, the value is checked.

public checkClaim(mixed $value) : void
Parameters
$value : mixed
Tags
throws
InvalidClaimException

if the claim "nbf" is not an integer

throws
InvalidClaimException

if the claim "nbf" restrict the use of the token

protectedHeaderOnly()

When true, the header parameter to be checked MUST be set in the protected header of the token.

public protectedHeaderOnly() : bool
Return values
bool

supportedClaim()

The method returns the claim to be checked.

public supportedClaim() : string
Return values
string

supportedHeader()

The method returns the header parameter to be checked.

public supportedHeader() : string
Return values
string

        
On this page

Search results