diff options
author | joey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071> | 2007-08-21 16:47:01 +0000 |
---|---|---|
committer | joey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071> | 2007-08-21 16:47:01 +0000 |
commit | 9ff9ea55f70a455a96fad3d34266343327528723 (patch) | |
tree | 0cb91395d51c941fe5956b795f90749737842993 | |
parent | 29a0de719779615f02c76d6e83132cc1f27dde3b (diff) | |
download | ikiwiki-9ff9ea55f70a455a96fad3d34266343327528723.tar ikiwiki-9ff9ea55f70a455a96fad3d34266343327528723.tar.gz |
fix libdir tainting
-rw-r--r-- | IkiWiki.pm | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/IkiWiki.pm b/IkiWiki.pm index 5eef40878..b70f51175 100644 --- a/IkiWiki.pm +++ b/IkiWiki.pm @@ -146,7 +146,7 @@ sub checkconfig () { #{{{ sub loadplugins () { #{{{ if (defined $config{libdir}) { - unshift @INC, $config{libdir}; + unshift @INC, possibly_foolish_untaint($config{libdir}); } loadplugin($_) foreach @{$config{plugin}}; @@ -166,7 +166,8 @@ sub loadplugin ($) { #{{{ return if grep { $_ eq $plugin} @{$config{disable_plugins}}; - foreach my $dir ($config{libdir}, "$installdir/lib/ikiwiki") { + foreach my $dir (possibly_foolish_untaint($config{libdir}), + "$installdir/lib/ikiwiki") { if (defined $dir && -x "$dir/plugins/$plugin") { require IkiWiki::Plugin::external; import IkiWiki::Plugin::external "$dir/plugins/$plugin"; |