Apache-Test
view release on metacpan or search on metacpan
when mod_cgi.c is the desired requirement.
[Fred Moyer <phred@apache.org>]
Fix overridden get_basic_credentials test when using NTLM authentication
[Rick Frankel <cpan@rickster.com>]
Work around a bug introduced in libwww-perl in version
5.820 for httpd's credentials
[Gunnar Wolf <gwolf@gwolf.org>, Niko Tyni <ntyni@debian.org>]
Make Apache::TestConfig::untaint_path tolerate undefined arguments
[Torsten Foertsch <torsten.foertsch@gmx.net]
Inherit LoadFile directives from the global httpd.conf
[Torsten Foertsch <torsten.foertsch@gmx.net]
Don't overwrite php.ini if it already exists
PR: 32994
[MAHEX <MAHEX@cpan.org>]
=item 1.30 November 26, 2007
=item 1.28 - February 22, 2006
add need_imagemap() and have_imagemap() to check for mod_imap
or mod_imagemap [ Colm MacCárthaigh ]
shortcuts like need_cgi() and need_php() no longer spit out
bogus skip messages [Geoffrey Young]
Adjust Apache::TestConfig::untaint_path() to handle relative paths
that don't start with /. [Stas]
If perlpath is longer than 62 chars, some shells on certain platforms
won't be able to run the shebang line, so when seeing a long perlpath
use the eval workaround [Mike Smith <mike@mailchannels.com>]
Location of the pid file is now configurable via the command line
-t_pid_file option [Joe Orton]
remove the mod_perl.pm entry from %INC after Apache::Test finishes
=item 1.21 - March 23, 2005
fix Apache::TestConfig (was missing 'use lib' before using
lib::import) [William McKee <william@knowmad.com>]
TestConfigPerl will now configure mod_perl last, giving mod_perl
highest priority throughout the httpd lifecycle. [Geoffrey Young]
Apache::TestConfig::untaint_path needs to remove empty entries in the
PATH list, since -T considers those tainted too. [Stas]
add Apache::TestHarnessPHP which allows for running client-side
scripts via php instead of perl. [Geoffrey Young]
=item 1.20 - January 22, 2005
instead of trying to match various custom server name variations (each
vendor seems to replace "Apache" in 'httpd -v' with their own name),
to try to index HTTP::Request::Common and warnings packages, which
happen to be used by A-T [Stas]
=item 1.17 - December 11, 2004
Apache::TestHandler: need to load Apache::RequestIO for mp2 for puts()
to work [Stas]
new Apache::TestConfig wrapper untaint_path() [Randy Kobes]
fix the config thaw() functionality (when top_dir wasn't in @INC the
saved config won't be loaded and tests will blow) [Stas]
new wrapper Apache::TestRequest::module2url to simplify handling of
vhosts in the client. ["Christopher H. Laco" <apache-test
chrislaco.com>]
resolve -T taint issues: [Stas]
- untaint $cmd in Apache::TestConfig::open_cmd
- fix the tainting of @INC (by untaintinig top_dir variable)
require Cwd 2.06 or higher (to solve File::Spec::rel2abs problems
under -T). Enforce the modules version requirements for those who
aren't running under CPAN/CPANPLUS shell) [Stas]
Apache::TestTrace: don't export by default the 'todo' utility's symbol
since it collides with Test::More [Stas]
Tweak the handling of mp2 source build case in
Apache::TestConfig::httpd_config(), apparently mp2 source build
lib/Apache/TestConfig.pm view on Meta::CPAN
#see Apache::TestMM::{filter_args,generate_script}
#we do this so 'perl Makefile.PL' can be passed options such as apxs
#without forcing regeneration of configuration and recompilation of c-modules
#as 't/TEST apxs /path/to/apache/bin/apxs' would do
while (my($key, $val) = each %Apache::TestConfig::Argv) {
$args->{$key} = $val;
}
my $top_dir = fastcwd;
$top_dir = pop_dir($top_dir, 't');
# untaint as we are going to use it a lot later on in -T sensitive
# operations (.e.g @INC)
$top_dir = $1 if $top_dir =~ /(.*)/;
# make sure that t/conf/apache_test_config.pm is found
# (unfortunately sometimes we get thrown into / by Apache so we
# can't just rely on $top_dir
lib->import($top_dir);
my $thaw = {};
#thaw current config
lib/Apache/TestConfig.pm view on Meta::CPAN
return if !defined($path) || -e $path;
$self->clean_add_path($path);
return File::Path::mkpath($path, 0, 0755);
}
sub open_cmd {
my($self, $cmd) = @_;
# untaint some %ENV fields
local @ENV{ qw(IFS CDPATH ENV BASH_ENV) };
local $ENV{PATH} = untaint_path($ENV{PATH});
# launder for -T
$cmd = $1 if $cmd =~ /(.*)/;
my $handle = Symbol::gensym();
open $handle, "$cmd|" or die "$cmd failed: $!";
return $handle;
}
lib/Apache/TestConfig.pm view on Meta::CPAN
}
}
}
sub apxs {
my($self, $q, $ok_fail) = @_;
return unless $self->{APXS};
my $val;
unless (exists $self->{_apxs}{$q}) {
local @ENV{ qw(IFS CDPATH ENV BASH_ENV) };
local $ENV{PATH} = untaint_path($ENV{PATH});
my $devnull = devnull();
my $apxs = shell_ready($self->{APXS});
$val = qx($apxs -q $q 2>$devnull);
chomp $val if defined $val; # apxs post-2.0.40 adds a new line
if ($val) {
$self->{_apxs}{$q} = $val;
}
unless ($val) {
if ($ok_fail) {
return "";
}
else {
warn "APXS ($self->{APXS}) query for $q failed\n";
return $val;
}
}
}
$self->{_apxs}{$q};
}
# return an untainted PATH
sub untaint_path {
my $path = shift;
return '' unless defined $path;
($path) = ( $path =~ /(.*)/ );
# win32 uses ';' for a path separator, assume others use ':'
my $sep = WIN32 ? ';' : ':';
# -T disallows relative and empty directories in the PATH
return join $sep, grep File::Spec->file_name_is_absolute($_),
grep length($_), split /$sep/, $path;
}
( run in 0.307 second using v1.01-cache-2.11-cpan-d6f9594c0a5 )