OXIESEC PANEL
- Current Dir:
/
/
var
/
www
/
firebase
/
vendor
/
monolog
/
monolog
/
src
/
Monolog
/
Handler
Server IP: 139.59.38.164
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
08/12/2024 10:35:58 AM
rwxr-xr-x
📄
AbstractHandler.php
2.71 KB
08/12/2024 10:35:56 AM
rw-r--r--
📄
AbstractProcessingHandler.php
1.52 KB
08/12/2024 10:35:56 AM
rw-r--r--
📄
AbstractSyslogHandler.php
3.24 KB
08/12/2024 10:35:56 AM
rw-r--r--
📄
AmqpHandler.php
5.12 KB
08/12/2024 10:35:56 AM
rw-r--r--
📄
BrowserConsoleHandler.php
9.3 KB
08/12/2024 10:35:56 AM
rw-r--r--
📄
BufferHandler.php
4.6 KB
08/12/2024 10:35:56 AM
rw-r--r--
📄
ChromePHPHandler.php
5.21 KB
08/12/2024 10:35:56 AM
rw-r--r--
📄
CouchDBHandler.php
2.64 KB
08/12/2024 10:35:56 AM
rw-r--r--
📄
CubeHandler.php
5.48 KB
08/12/2024 10:35:56 AM
rw-r--r--
📁
Curl
-
08/12/2024 10:36:32 AM
rwxr-xr-x
📄
DeduplicationHandler.php
6.42 KB
08/12/2024 10:35:56 AM
rw-r--r--
📄
DoctrineCouchDBHandler.php
1.17 KB
08/12/2024 10:35:56 AM
rw-r--r--
📄
DynamoDbHandler.php
1.97 KB
08/12/2024 10:35:56 AM
rw-r--r--
📄
ElasticaHandler.php
3.72 KB
08/12/2024 10:35:56 AM
rw-r--r--
📄
ElasticsearchHandler.php
7.01 KB
08/12/2024 10:35:56 AM
rw-r--r--
📄
ErrorLogHandler.php
2.71 KB
08/12/2024 10:35:56 AM
rw-r--r--
📄
FallbackGroupHandler.php
1.75 KB
08/12/2024 10:35:56 AM
rw-r--r--
📄
FilterHandler.php
7.12 KB
08/12/2024 10:35:57 AM
rw-r--r--
📁
FingersCrossed
-
08/12/2024 10:36:32 AM
rwxr-xr-x
📄
FingersCrossedHandler.php
8.21 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
FirePHPHandler.php
5.2 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
FleepHookHandler.php
3.57 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
FlowdockHandler.php
3.52 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
FormattableHandlerInterface.php
791 bytes
08/12/2024 10:35:57 AM
rw-r--r--
📄
FormattableHandlerTrait.php
1.29 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
GelfHandler.php
1.48 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
GroupHandler.php
3.32 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
Handler.php
1.27 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
HandlerInterface.php
2.79 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
HandlerWrapper.php
3.41 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
IFTTTHandler.php
2.29 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
InsightOpsHandler.php
2.11 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
LogEntriesHandler.php
1.93 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
LogglyHandler.php
4.17 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
LogmaticHandler.php
2.67 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
MailHandler.php
2.28 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
MandrillHandler.php
2.56 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
MissingExtensionException.php
494 bytes
08/12/2024 10:35:57 AM
rw-r--r--
📄
MongoDBHandler.php
2.39 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
NativeMailerHandler.php
5.05 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
NewRelicHandler.php
5.88 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
NoopHandler.php
950 bytes
08/12/2024 10:35:57 AM
rw-r--r--
📄
NullHandler.php
1.35 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
OverflowHandler.php
4.35 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
PHPConsoleHandler.php
12.22 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
ProcessHandler.php
5.24 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
ProcessableHandlerInterface.php
1.2 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
ProcessableHandlerTrait.php
1.65 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
PsrHandler.php
2.5 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
PushoverHandler.php
8.16 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
RedisHandler.php
2.76 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
RedisPubSubHandler.php
1.71 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
RollbarHandler.php
3.65 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
RotatingFileHandler.php
7.02 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
SamplingHandler.php
3.94 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
SendGridHandler.php
2.97 KB
08/12/2024 10:35:57 AM
rw-r--r--
📁
Slack
-
08/12/2024 10:36:32 AM
rwxr-xr-x
📄
SlackHandler.php
7.25 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
SlackWebhookHandler.php
3.92 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
SocketHandler.php
12.27 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
SqsHandler.php
1.77 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
StreamHandler.php
6.83 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
SymfonyMailerHandler.php
3.55 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
SyslogHandler.php
1.71 KB
08/12/2024 10:35:57 AM
rw-r--r--
📁
SyslogUdp
-
08/12/2024 10:36:32 AM
rwxr-xr-x
📄
SyslogUdpHandler.php
4.78 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
TelegramBotHandler.php
9.51 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
TestHandler.php
6.51 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
WebRequestRecognizerTrait.php
527 bytes
08/12/2024 10:35:57 AM
rw-r--r--
📄
WhatFailureGroupHandler.php
1.94 KB
08/12/2024 10:35:57 AM
rw-r--r--
📄
ZendMonitorHandler.php
2.87 KB
08/12/2024 10:35:57 AM
rw-r--r--
Editing: CouchDBHandler.php
Close
<?php declare(strict_types=1); /* * This file is part of the Monolog package. * * (c) Jordi Boggiano <j.boggiano@seld.be> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Monolog\Handler; use Monolog\Formatter\FormatterInterface; use Monolog\Formatter\JsonFormatter; use Monolog\Level; use Monolog\LogRecord; /** * CouchDB handler * * @author Markus Bachmann <markus.bachmann@bachi.biz> * @phpstan-type Options array{ * host: string, * port: int, * dbname: string, * username: string|null, * password: string|null * } * @phpstan-type InputOptions array{ * host?: string, * port?: int, * dbname?: string, * username?: string|null, * password?: string|null * } */ class CouchDBHandler extends AbstractProcessingHandler { /** * @var mixed[] * @phpstan-var Options */ private array $options; /** * @param mixed[] $options * * @phpstan-param InputOptions $options */ public function __construct(array $options = [], int|string|Level $level = Level::Debug, bool $bubble = true) { $this->options = array_merge([ 'host' => 'localhost', 'port' => 5984, 'dbname' => 'logger', 'username' => null, 'password' => null, ], $options); parent::__construct($level, $bubble); } /** * @inheritDoc */ protected function write(LogRecord $record): void { $basicAuth = null; if (null !== $this->options['username'] && null !== $this->options['password']) { $basicAuth = sprintf('%s:%s@', $this->options['username'], $this->options['password']); } $url = 'http://'.$basicAuth.$this->options['host'].':'.$this->options['port'].'/'.$this->options['dbname']; $context = stream_context_create([ 'http' => [ 'method' => 'POST', 'content' => $record->formatted, 'ignore_errors' => true, 'max_redirects' => 0, 'header' => 'Content-type: application/json', ], ]); if (false === @file_get_contents($url, false, $context)) { throw new \RuntimeException(sprintf('Could not connect to %s', $url)); } } /** * @inheritDoc */ protected function getDefaultFormatter(): FormatterInterface { return new JsonFormatter(JsonFormatter::BATCH_MODE_JSON, false); } }