From 28911c6f2275e4dba85d321fecd8655497c66240 Mon Sep 17 00:00:00 2001 From: Fredrick Brennan Date: Sun, 21 Sep 2014 17:51:59 +0000 Subject: [PATCH] Better protection of protected dirs --- create.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/create.php b/create.php index 5dbf4b21..2ec3189f 100644 --- a/create.php +++ b/create.php @@ -4,7 +4,7 @@ include "inc/functions.php"; include "inc/ayah/ayah.php"; include "inc/mod/auth.php"; checkBan('*'); -$bannedWords = array('/^cake$/', '8ch', '/^cp$/', 'child'); +$bannedWords = array('/^cake$/', '8ch', '/^cp$/', 'child', '/^inc$/', '/^static$/', '/^templates$/', '/^js$/', '/^stylesheets$/', '/^tools$/'); $ayah = new AYAH(); @@ -48,8 +48,6 @@ if (!(strlen($subtitle) < 200)) error('Invalid subtitle'); if (!preg_match('/^[a-zA-Z0-9._]{1,30}$/', $username)) error('Invalid username'); -if (is_dir($uri)) - error("Cannot create board with name of reserved directory!"); if (!$score) error('You failed the game'); foreach (listBoards() as $i => $board) {