Exploit database

GH-25ed919a3c63ff26fc49a3fe47dc7565

datackmy/fallingskies-cve-2023-35885

GitHubNot listedPoC
Download repository ZIP

Sources for CVE-2023-35885

4 sources

Preferred order: Exploit-DB, Metasploit, then GitHub repositories by stars.

Repository files4
datackmy/fallingskies-cve-2023-35885Revision cb3449d9acca

Files from this repository share one source choice. Supporting files may cover other vulnerabilities.

src/Log/Parser/PhpFpmErrorLogParser.php

PHP · 3,535 bytes
<?php
 namespace App\Log\Parser; class PhpFpmErrorLogParser { const GROK_PATTERN = "\134\133\x25\x7b\x44\x41\124\101\72\160\x68\x70\x5f\x66\160\155\137\x64\x61\x74\145\175\134\135\40\45\x7b\x44\101\124\x41\72\x65\x72\x72\157\162\137\164\x79\160\145\175\134\72\40\x25\x7b\107\x52\105\105\x44\x59\104\x41\124\x41\72\145\162\x72\157\162\137\x6d\145\163\163\141\x67\145\x7d\50\134\156\123\164\141\143\153\x20\x74\162\x61\143\145\72\x5c\156\45\x7b\107\x52\x45\x45\104\131\x44\x41\x54\x41\x5f\106\x55\114\114\x3a\163\164\x61\143\x6b\137\164\162\141\143\x65\175\134\x6e\x29\x3f"; private ?string $logFileContent = null; private array $parsedLogLines = []; private ?GrokParser $grokParser = null; public function __construct(string $logfileContent) { $this->logFileContent = $logfileContent; } public function parse() : array { goto d376c; d376c: $explodedLogLines = explode(PHP_EOL, $this->logFileContent); goto b34fa; B1e59: $logLines = []; goto bcfb4; d32b0: $logLineData = []; goto F45ec; D2807: $logLine = $explodedLogLines[$i] ?? ''; goto B018c; fe4fc: if (!count($logLines)) { goto F4e41; } goto F497c; f9e7f: if (!($i < $numberOfLogLines)) { goto F27a0; } goto D2807; f9dbb: F27a0: goto fe4fc; F8dde: Dc857: goto F2425; F45ec: b3eb5: goto db59f; B018c: $nextLogLine = $explodedLogLines[$i + 1] ?? ''; goto fdb0f; F2425: F4e41: goto Ffe91; e15b9: $i = 0; goto C93b4; c6496: goto A3fe0; goto f9dbb; Bc96c: if (!("\x5b" == substr($nextLogLine, 0, 1) || $i + 1 == $numberOfLogLines)) { goto b3eb5; } goto e1c00; db59f: eb653: goto D48ba; F497c: foreach ($logLines as $logLine) { goto adba8; b3685: Cefdc: goto E62c0; cf74e: if (!(false === empty($parsedLogLine))) { goto c6ad2; } goto cb8a4; ed8ef: c6ad2: goto b3685; cb8a4: $this->parsedLogLines[] = $parsedLogLine; goto ed8ef; adba8: $parsedLogLine = $this->parseLogLine($logLine); goto cf74e; E62c0: } goto F8dde; e1c00: $logLines[] = implode(PHP_EOL, $logLineData); goto d32b0; bcfb4: $logLineData = []; goto e15b9; C93b4: A3fe0: goto f9e7f; Ffe91: return $this->parsedLogLines; goto A12e9; fdb0f: $logLineData[] = $logLine; goto Bc96c; b34fa: $numberOfLogLines = count($explodedLogLines); goto B1e59; D48ba: $i++; goto c6496; A12e9: } private function parseLogLine(string $logLine) : array { goto d2582; d2582: $parsedLogLine = []; goto b1fb2; b1f2b: $parseResult = $grokParser->parse($logLine); goto e45b6; Ab3b3: e2bd8: goto a3a75; Bb62c: $errorType = $parseResult["\145\x72\162\x6f\x72\137\x74\x79\160\145"] ?? ''; goto e6253; b1fb2: $grokParser = $this->getGrokParser(); goto b1f2b; e6253: $errorMessage = $parseResult["\145\x72\162\157\x72\137\x6d\145\163\x73\141\x67\145"] ?? ''; goto ea8a1; e45b6: if (!(false !== $parseResult && count($parseResult))) { goto e2bd8; } goto Dc39c; ea8a1: $parsedLogLine = ["\x64\x61\x74\x65" => $date, "\x65\x72\162\x6f\162\x54\171\160\145" => $errorType, "\145\162\x72\157\x72\115\x65\163\163\x61\x67\145" => $errorMessage, "\x6c\157\x67\114\x69\x6e\x65" => $logLine]; goto Ab3b3; Dc39c: $date = $parseResult["\160\x68\160\137\146\x70\155\137\x64\x61\x74\145"] ?? ''; goto Bb62c; a3a75: return $parsedLogLine; goto fb6bf; fb6bf: } public function getParsedLogLines() : array { return $this->parsedLogLines; } private function getGrokParser() { goto Fecbc; cc18e: return $this->grokParser; goto F1dd2; B006b: $this->grokParser->setPattern(self::GROK_PATTERN); goto Ef8e2; Ef8e2: Afd48: goto cc18e; c8cb7: $this->grokParser = new GrokParser(); goto B006b; Fecbc: if (!(true === is_null($this->grokParser))) { goto Afd48; } goto c8cb7; F1dd2: } }