Configure HTTP PERL Scripts To Use TAINT Option
An XCCDF Rule
Description
If the mod_perl
module is installed, enable Perl Taint checking in
/etc/httpd/conf/httpd.conf
. To enable Perl Taint
checking, add or uncomment the following to /etc/httpd/conf.d/perl.conf
:
PerlSwitches -T
Rationale
PERL (Practical Extraction and Report Language) is an interpreted language
optimized for scanning arbitrary text files, extracting information from those
text files, and printing reports based on that information. The language is
often used in shell scripting and is intended to be practical, easy to use, and
efficient means of generating interactive web pages for the user. Unfortunately,
many widely available freeware PERL programs (scripts) are extremely insecure.
This is most readily accomplished by a malicious user substituting input to a
PERL script during a POST or a GET operation.
Consequently, the founders of
PERL have developed a mechanism named TAINT that protects the system from
malicious input sent from outside the program. When the data is tainted, it
cannot be used in programs or functions such as eval(), system(), exec(), pipes,
or popen(). The script will exit with a warning message.
- ID
- xccdf_org.ssgproject.content_rule_httpd_configure_perl_taint
- Severity
- Medium
- References
- Updated