public function mapAuthenticator($shortname)
{
// query whether or not we've manager configuration found
/** @var \AppserverIo\Appserver\Core\Api\Node\ManagerNodeInterface $managerNode */
if ($managerNode = $this->getAuthenticationContext()->getManagerConfiguration()) {
// initialize the authenticator configurations found in the manager configuration
/** @var \AppserverIo\Appserver\Core\Api\Node\AuthenticatorNodeInterface $authenticatorNode */
foreach ($managerNode->getAuthenticators() as $authenticatorNode) {
// query whether or not the shortname matches
if (strcasecmp($authenticatorNode->getName(), $shortname) === 0) {
return $authenticatorNode->getType();
}
}
}
// throw an exception if the can't find an matching authenticator class name
throw new AuthenticationException(sprintf('Can\\t find authenticator configuration for %s', $shortname));
}