diff options
author | Michal Čihař <michal@cihar.com> | 2016-12-08 13:39:32 +0300 |
---|---|---|
committer | Michal Čihař <michal@cihar.com> | 2016-12-08 13:41:42 +0300 |
commit | f2bfa7d745a49ecc6625924a376c66ace194d8d1 (patch) | |
tree | f8a9deaf3547d71705cedd7f5f3d796711600933 /scripts/update-po | |
parent | 5f558b0a1d8c0da3a79da8b11d735d4c6febe5da (diff) |
Avoid running shell scripts as CGI
There is really no reason for that besides misconfigured servers.
This is followup for PMASA-2016-54
Signed-off-by: Michal Čihař <michal@cihar.com>
Diffstat (limited to 'scripts/update-po')
-rwxr-xr-x | scripts/update-po | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/scripts/update-po b/scripts/update-po index 3e7d9dcbee..53387ab575 100755 --- a/scripts/update-po +++ b/scripts/update-po @@ -2,6 +2,12 @@ # vim: expandtab sw=4 ts=4 sts=4: export LC_ALL=C +# Do not run as CGI +if [ -n "$GATEWAY_INTERFACE" ] ; then + echo 'Can not invoke as CGI!' + exit 1 +fi + # Exit on failure set -e |