mirror of
https://github.com/ThunixdotNet/www.git
synced 2026-01-24 07:10:18 +00:00
Check SSH public key format
This commit is contained in:
@@ -35,6 +35,11 @@ if ( $tv == "tildeverse" )
|
|||||||
if($retval == 0)
|
if($retval == 0)
|
||||||
$success = 'success3';
|
$success = 'success3';
|
||||||
|
|
||||||
|
// Check SSH public key format:
|
||||||
|
exec("echo $pubkey | ssh-keygen -l -f - 2>&1", $null, $retval);
|
||||||
|
if($retval != 0)
|
||||||
|
$success = 'success1';
|
||||||
|
|
||||||
if ( $success == "success2" )
|
if ( $success == "success2" )
|
||||||
mail($destination_addr, $subject, $mailbody, $from);
|
mail($destination_addr, $subject, $mailbody, $from);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user