/**
* @param integer $step The requested setup step
* @return void
* @Flow\SkipCsrfProtection
*/
public function authenticateAction($step)
{
try {
$this->authenticationManager->authenticate();
if (file_exists($this->settings['initialPasswordFile'])) {
unlink($this->settings['initialPasswordFile']);
}
$this->redirect('index', 'Setup', null, ['step' => $step]);
} catch (\Neos\Flow\Security\Exception\AuthenticationRequiredException $exception) {
$this->addFlashMessage('Sorry, you were not able to authenticate.', 'Authentication error', Message::SEVERITY_ERROR);
$this->redirect('login', null, null, ['step' => $step]);
}
}