code: untaint the hostname (as passed from commandline)
authorHeiko Schlittermann <hs@schlittermann.de>
Tue, 14 Apr 2009 15:37:33 +0200
changeset 13 ddf323751753
parent 12 8cd92042fb8b
child 15 4168921d9151
code: untaint the hostname (as passed from commandline)
sap-vpn.pl
--- a/sap-vpn.pl	Tue Jan 06 09:55:50 2009 +0100
+++ b/sap-vpn.pl	Tue Apr 14 15:37:33 2009 +0200
@@ -94,6 +94,7 @@
 
     $opt_verbose += $opt_debug;
 
+    untaint($opt_host) or ohshit "hostname didn't pass verification\n";
     untaint($opt_linkname) or ohshit "linkname didn't pass verification\n";
     untaint($opt_script)
       or ohshit "script name didn't pass verification\n"