aboutsummaryrefslogtreecommitdiff
path: root/IkiWiki
diff options
context:
space:
mode:
authorjoey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>2006-07-31 00:59:54 +0000
committerjoey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>2006-07-31 00:59:54 +0000
commit953ffa1fe31ab97caf3b1bcc5840e62728620833 (patch)
tree52bf1e60d06a58150738f3d57397eff13e21d2c7 /IkiWiki
parente4ccc4f3b09aaaa4f64bdba1d6ffff24e924fd20 (diff)
downloadikiwiki-953ffa1fe31ab97caf3b1bcc5840e62728620833.tar
ikiwiki-953ffa1fe31ab97caf3b1bcc5840e62728620833.tar.gz
fix
Diffstat (limited to 'IkiWiki')
-rw-r--r--IkiWiki/Plugin/aggregate.pm5
1 files changed, 3 insertions, 2 deletions
diff --git a/IkiWiki/Plugin/aggregate.pm b/IkiWiki/Plugin/aggregate.pm
index 98e534366..14461059d 100644
--- a/IkiWiki/Plugin/aggregate.pm
+++ b/IkiWiki/Plugin/aggregate.pm
@@ -254,14 +254,15 @@ sub add_page (@) { #{{{
# assign it an unused page
my $page=IkiWiki::titlepage($params{title});
- $page=~s!([/])!"__".ord($1)."__"!eg; # escape slashes in title
+ # escape slashes and periods in title so it doesn't specify
+ # directory name or trigger ".." disallowing code.
+ $page=~s!([/.])!"__".ord($1)."__"!eg;
$page=$feed->{dir}."/".$page;
$page=lc($page);
($page)=$page=~/$IkiWiki::config{wiki_file_regexp}/;
if (! defined $page || ! length $page) {
$page=$feed->{dir}."/item";
}
- $page=~s/\.\.//g; # avoid ".." directory tricks
my $c="";
while (exists $IkiWiki::pagesources{$page.$c} ||
-e pagefile($page.$c)) {