[fix] montage: smaller, secu

This commit is contained in:
Alban 2019-11-22 23:41:40 +01:00
parent f7f6fa25ea
commit be8354b535
3 changed files with 6 additions and 5 deletions

View file

@ -21,7 +21,7 @@ if (strpos($img, 'data:image/png;base64') === 0) {
panic("Not a valid image");
}
$output = $return_code = NULL;
exec( __DIR__."/../page_generator.sh ".escapeshellargs($file)." ".escapeshellargs($horizontal)." ".escapeshellargs($vertical)." ".escapeshellargs($landscape) , $output, $return_code);
exec( __DIR__."/../page_generator.sh ".escapeshellarg($file)." ".escapeshellarg($horizontal)." ".escapeshellarg($vertical)." ".escapeshellarg($landscape) , $output, $return_code);
if( 0 === $return_code ){
$pdf = basename(implode("", $output));
echo( "https://2020.hackersfest.org/ImageGenerator/a4/".urlencode($pdf) );