From 7c3cc891f39244f740e184c830a0add5761b738f Mon Sep 17 00:00:00 2001 From: Matt Pass Date: Wed, 19 Sep 2012 08:33:47 +0100 Subject: [PATCH 01/13] Remove if condition No longer showing ICEcoder if we're not logged in, so no need for if else --- files.php | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/files.php b/files.php index eda21f0..26e5f95 100644 --- a/files.php +++ b/files.php @@ -121,11 +121,7 @@ for ($i=0;$i'.$chmodInfo.''; } $type == "folder" ? $class = 'pft-directory' : $class = 'pft-file '.strtolower($ext); - if ($_SESSION['loggedIn'] || (!$_SESSION['loggedIn'] && !$restrictedFile)) { - echo "
  •         ".basename($fileFolderName)." ".$fileAtts."\n"; - } else { - echo "
  •         [HIDDEN]"; - } + echo "
  •         ".basename($fileFolderName)." ".$fileAtts."\n"; if ($i\n";} $lastPath = $fileFolderName; } From 22a1305cb14f7264949cc0a4725a509204a88155 Mon Sep 17 00:00:00 2001 From: Matt Pass Date: Wed, 19 Sep 2012 08:35:43 +0100 Subject: [PATCH 02/13] Cannot view if not logged in No need to check for loggedIn anymore, you simply cannout view this page if not logged in Removed login param from init() function call --- index.php | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/index.php b/index.php index 91d74ac..6eaf538 100644 --- a/index.php +++ b/index.php @@ -43,7 +43,7 @@ window.onbeforeunload = function() { } previousFiles = [ -" onResize="ICEcoder.setLayout()" onKeyDown="return ICEcoder.interceptKeys('coder',event);" onKeyUp="parent.ICEcoder.resetKeys(event);"> +
    From 15b4793d32044a77f731069d5d3781eeca01c24e Mon Sep 17 00:00:00 2001 From: Matt Pass Date: Wed, 19 Sep 2012 08:38:55 +0100 Subject: [PATCH 03/13] bannedFiles changed Now just hide _coder and ICEcoder folders to hide ICEcoder itself from the file manager Users can now see everything else --- lib/config.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/config.php b/lib/config.php index 1ab1a86..3fbc8b3 100644 --- a/lib/config.php +++ b/lib/config.php @@ -10,7 +10,7 @@ $ICEcoder = array( "lockedNav" => true, "accountPassword" => "", "restrictedFiles" => array("wp-",".php",".rb",".sql",".zip"), -"bannedFiles" => array("_coder","wp-",".exe"), +"bannedFiles" => array("_coder","ICEcoder"), "allowedIPs" => array("*"), "plugins" => array( array("Adminer","plugins/adminer/icon.png","margin-top: 3px","plugins/adminer/adminer-3.4.0-mysql-en.php","_blank",""), From 924919fb6f5424e04ec8b614b82e27222cfbb20b Mon Sep 17 00:00:00 2001 From: Matt Pass Date: Wed, 19 Sep 2012 08:40:37 +0100 Subject: [PATCH 04/13] No need for if condition now You can only see multiple results if logged in, so no need for this if condition --- lib/multiple-results.php | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/lib/multiple-results.php b/lib/multiple-results.php index 8bd5501..3b60e83 100644 --- a/lib/multiple-results.php +++ b/lib/multiple-results.php @@ -103,10 +103,8 @@ if (startTab!=top.ICEcoder.selectedTab) { } else if(stristr(file_get_contents($fullPath), $q)) { $rFile = false; $bFile = false; - if (!$_SESSION['loggedIn']) { - for ($i=0;$i0) {$rFile = true;}; - } + for ($i=0;$i0) {$rFile = true;}; } for ($i=0;$i0) {$bFile = true;}; From aa6cfcc76e99dd161e968a012762de47642ff146 Mon Sep 17 00:00:00 2001 From: Matt Pass Date: Wed, 19 Sep 2012 08:42:11 +0100 Subject: [PATCH 05/13] No need for if condition here Removed if checks and else conditions in a couple of places --- lib/settings-screen.php | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/lib/settings-screen.php b/lib/settings-screen.php index f3d7ec0..bc2e15d 100644 --- a/lib/settings-screen.php +++ b/lib/settings-screen.php @@ -52,7 +52,7 @@ for ($i=0;$i
    file manager root:
    - +



    ICE coder by Matt Pass (@mattpass)

    @@ -202,7 +202,6 @@ var showHideTabs = function() { } var validatePasswords = function() { - if (document.settings.accountPassword.value != 0 && document.settings.accountPassword.value.length<8) { top.ICEcoder.message('Please use at least 8 chars in the password'); } else { @@ -212,9 +211,6 @@ var validatePasswords = function() { document.settings.submit(); } } - - top.ICEcoder.message('Sorry, you need to be logged in to change settings'); - } From ef6bf6e4df6883acfa744a457ebb95f949e68741 Mon Sep 17 00:00:00 2001 From: Matt Pass Date: Wed, 19 Sep 2012 08:44:11 +0100 Subject: [PATCH 06/13] Removing of if condition regarding loggedIn You can only view this file if logged in now, do no need for if or if else conditions --- lib/file-folder-properties.php | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/lib/file-folder-properties.php b/lib/file-folder-properties.php index 2bcc9b5..b5f5c06 100644 --- a/lib/file-folder-properties.php +++ b/lib/file-folder-properties.php @@ -39,17 +39,13 @@ echo number_format($outputSize, 2, '.', '').$outputUnit." (".number_format($byte

    Type: Readable / Writeable: / / Relative path:

    Absolute path:


    @@ -144,13 +140,7 @@ var validatePerms = function() { permText.split("")[2]*1 <0 || permText.split("")[2]*1 >7) { canUpdate = false; } - if (canUpdate) {top.ICEcoder.chmod('',permText)}; - } From 21d1c1f9bad5d8b1475938b7680a294573f22fa0 Mon Sep 17 00:00:00 2001 From: Matt Pass Date: Wed, 19 Sep 2012 08:54:51 +0100 Subject: [PATCH 07/13] No longer need login area Logging in now done on seperate screen not here --- index.php | 8 -------- 1 file changed, 8 deletions(-) diff --git a/index.php b/index.php index 6eaf538..f92c17d 100644 --- a/index.php +++ b/index.php @@ -98,14 +98,6 @@ showFileMenu = function() {