🔏Authentication
Configuring your authentication services
Last updated
Configuring your authentication services
Last updated
You will configure the authentication and user services in the authentication
area of CBSecurity. CBSecurity ships with the cbauth module that can provide you with a robust authentication service, session/request storage, interceptions, and much more. However, you can use any security authentication service as long as it matches our interface: cbsecurity.interfaces.ISecurityValidator
.
If you are using cbauth as your authenticationService
(the default), you also need to configure cbauth.
The provider
key is the WireBox ID of the authentication service that must adhere to our interface.
This key is not mandatory and will be automatically filled out from the cbauth
user service class by default. This class is used for CBSecurity to know how to retrieve users and validate credentials from whatever storage system you use. This value can be a WireBox ID, and the object must adhere to our interface: cbsecurity.interfaces.IUserService
.
This is a convenience setting that tells CBSecurity into which prc
(private request context) variable to store the authenticated user on EVERY request. This allows your entire codebase to talk to a single variable for the authenticated user.