Chain several auth providers as if they were one. This is useful for cases where one want to authenticate across several providers, for example, database and fallback to passwd file.
Hashing Algorithm. A common interface to interact with any system provided algorithms.
Hashing Strategy manager.
This class will load system provided hashing strategies and algorithms.
Represents an authenticates User and contains operations to authorise the user.
Please consult the documentation for a detailed explanation.
A secure non blocking random number generator isolated to the current context. The PRNG is bound to the vert.x context and setup to close when the context shuts down.
When applicable, use of VertxContextPRNG rather than create new PRNG objects is helpful to keep the system entropy usage to the minimum avoiding potential blocking across the application.
The use of VertxContextPRNG is particularly appropriate when multiple handlers use random numbers.
Factory interface for creating @see \io\vertx\jphp\ext\auth\AuthProvider instances that use the Vert.x JDBC client.
By default the hashing strategy is SHA-512. If you're already running in production this is backwards compatible, however for new deployments or security upgrades it is recommended to use the PBKDF2 strategy as it is the current OWASP recommendation for password storage.
Factory interface for creating JWT based @see \io\vertx\jphp\ext\auth\AuthProvider instances.
Options related to creation of new tokens.
If any expiresInMinutes, audience, subject, issuer are not provided, there is no default. The jwt generated won't include those properties in the payload.
Generated JWTs will include an iat claim by default unless noTimestamp is specified.
Factory interface for creating OAuth2 based @see \io\vertx\jphp\ext\auth\AuthProvider instances.
Functional interface that allows users to implement custom RBAC verifiers for OAuth2/OpenId Connect.
Users are to implement the isAuthorized
method to verify authorities. For provides that do not
export the permissions/roles in the token, this interface allows you to communicate with 3rd party services
such as graph APIs to collect the required data.
The contract is that once an authority is checked for a given user, it's value is cached during the execution of the request. If a user is stored to a persistent storage, or the token is introspected, the cache is cleared and a new call will be handled to the implementation.
Simplified factory to create an @see \io\vertx\jphp\ext\auth\oauth2\OAuth2Auth for Google.