SilverStripe\SAML\Helpers\SAMLHelper::redirect
Create a SAML AuthN request and send the user off to the identity provider (IdP) to get authenticated. This method does not check to see if the user is already authenticated, that is the responsibility of the caller.
Note: This method will *never* return via normal control flow - instead one of two things will happen: - The user will be forcefully & immediately redirected to the IdP to get authenticated, OR - A HTTPResponse_Exception is thrown because php-saml encountered an error while generating a valid AuthN request
Signature
public function redirect([RequestHandler
$requestHandler = NULL,
[HTTPRequest
$request = NULL,
[string|null
$backURL = NULL]]] )
Parameters
$requestHandler
— SilverStripe\Control\RequestHandler- In case of error, we require a RequestHandler to throw errors from
$request
— SilverStripe\Control\HTTPRequest- The currently active request (used to retrieve session)
$backURL
— object- The URL to return to after successful SAML authentication (@see SAMLController)
Returns
- void
- This function will never return via normal control flow (see above).