!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/laravel-crm/packages/Webkul/DataTransfer/src/Helpers/Sources/   drwxrwxrwx
Free 12.98 GB of 57.97 GB (22.39%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     AbstractSource.php (2.37 KB)      -rw-rw-rw-
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php

namespace Webkul\DataTransfer\Helpers\Sources;

use 
Webkul\DataTransfer\Helpers\Importers\AbstractImporter;

abstract class 
AbstractSource
{
    
/**
     * Column names.
     */
    
protected array $columnNames = [];

    
/**
     * Quantity of columns.
     */
    
protected int $totalColumns 0;

    
/**
     * Current row.
     */
    
protected array $currentRowData = [];

    
/**
     * Current row number.
     */
    
protected int $currentRowNumber = -1;

    
/**
     * Flag to indicate that wrong quote was found.
     */
    
protected bool $foundWrongQuoteFlag false;

    
/**
     * Read next line from source.
     */
    
abstract protected function getNextRow(): array|bool;

    
/**
     * Return the key of the current row.
     */
    
public function getCurrentRowNumber(): int
    
{
        return 
$this->currentRowNumber;
    }

    
/**
     * Checks if current position is valid.
     */
    
public function valid(): bool
    
{
        return 
$this->currentRowNumber !== -1;
    }

    
/**
     * Read next line from source.
     */
    
public function current(): array
    {
        
$row $this->currentRowData;

        if (
count($row) != $this->totalColumns) {
            if (
$this->foundWrongQuoteFlag) {
                throw new 
\InvalidArgumentException(AbstractImporter::ERROR_CODE_WRONG_QUOTES);
            } else {
                throw new 
\InvalidArgumentException(AbstractImporter::ERROR_CODE_COLUMNS_NUMBER);
            }
        }

        return 
array_combine($this->columnNames$row);
    }

    
/**
     * Read next line from source.
     */
    
public function next(): void
    
{
        
$this->currentRowNumber++;

        
$row $this->getNextRow();

        if (
$row === false || $row === []) {
            
$this->currentRowData = [];

            
$this->currentRowNumber = -1;
        } else {
            
$this->currentRowData $row;
        }
    }

    
/**
     * Rewind the iterator to the first row.
     */
    
public function rewind(): void
    
{
        
$this->currentRowNumber 0;

        
$this->currentRowData = [];

        
$this->getNextRow();

        
$this->next();
    }

    
/**
     * Column names getter.
     */
    
public function getColumnNames(): array
    {
        return 
$this->columnNames;
    }

    
/**
     * Column names getter.
     */
    
public function getTotalColumns(): int
    
{
        return 
count($this->columnNames);
    }
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ ok ]

:: Make Dir ::
 
[ ok ]
:: Make File ::
 
[ ok ]

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

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