NAME
Kernel::System::CustomerAuth – customer authentication module.
DESCRIPTION
The authentication module for the customer interface.
PUBLIC INTERFACE
new()
Don't use the constructor directly, use the ObjectManager instead:
my $CustomerAuthObject = $Kernel::OM->Get('Kernel::System::CustomerAuth');
GetOption()
Get module options. Currently there is just one option, "PreAuth".
if ($AuthObject->GetOption(What => 'PreAuth')) {
print "No login screen is needed. Authentication is based on other options. E. g. $ENV{REMOTE_USER}\n";
}
Auth()
Check the user authentication.
my $AuthValid = $AuthObject->Auth(
User => $User, # (required)
Pw => $Pw, # (required)
TwoFactorToken => $TwoFactorToken, # (optional)
DeviceUUID => $DeviceUUID, # (optional)
CheckPasswordOnly => 1, # (optional) Check password only, skip actual auth
# default: 0
);
Returns 1 on success.
GetLastErrorMessage()
Retrieve $Self->{LastErrorMessage} content.
my $AuthErrorMessage = $AuthObject->GetLastErrorMessage();
Result:
$AuthErrorMessage = "An error string message.";