Final RST modifications (12 May)

This commit is contained in:
Pinga 2025-05-12 17:40:46 +03:00
parent 1c79be37a6
commit cb372409d3
4 changed files with 48 additions and 0 deletions

View file

@ -240,6 +240,16 @@ class ApplicationsController extends Controller
}
}
$smdId = $xpath->evaluate('string(//smd:id)');
$isRevoked = $db->selectValue(
"SELECT 1 FROM tmch_revocation WHERE smd_id = ?",
[ $smdId ]
);
if ($isRevoked === 1) {
$this->container->get('flash')->addMessage('error', 'Error creating application: SMD certificate has been revoked');
return $response->withHeader('Location', '/application/create')->withStatus(302);
}
$notBefore = new \DateTime($xpath->evaluate('string(//smd:notBefore)'));
$notafter = new \DateTime($xpath->evaluate('string(//smd:notAfter)'));
$markName = $xpath->evaluate('string(//mark:markName)');