uawdijnntqw1x1x1
IP : 18.220.245.184
Hostname : ns1.eurodns.top
Kernel : Linux ns1.eurodns.top 4.18.0-553.5.1.lve.1.el7h.x86_64 #1 SMP Fri Jun 14 14:24:52 UTC 2024 x86_64
Disable Function : mail,sendmail,exec,passthru,shell_exec,system,popen,curl_multi_exec,show_source,eval,open_base
OS : Linux
PATH:
/
home
/
sudancam
/
public_html
/
..
/
.trash
/
fonts
/
..
/
.
/
system.1
/
library
/
session.php
/
/
<?php /** * @package OpenCart * @author Daniel Kerr * @copyright Copyright (c) 2005 - 2017, OpenCart, Ltd. (https://www.opencart.com/) * @license https://opensource.org/licenses/GPL-3.0 * @link https://www.opencart.com */ /** * Session */ namespace Opencart\System\Library; class Session { protected object $adaptor; protected string $session_id; public array $data = []; /** * Constructor * * @param string $adaptor * @param object $registry */ public function __construct(string $adaptor, \Opencart\System\Engine\Registry $registry) { $class = 'Opencart\System\Library\Session\\' . $adaptor; if (class_exists($class)) { if ($registry) { $this->adaptor = new $class($registry); } else { $this->adaptor = new $class(); } register_shutdown_function([&$this, 'close']); register_shutdown_function([&$this, 'gc']); } else { throw new \Exception('Error: Could not load session adaptor ' . $adaptor . ' session!'); } } /** * Get Session ID * * @return string */ public function getId() { return $this->session_id; } /** * Start * * Starts a session. * * @param string $session_id * * @return string Returns the current session ID. */ public function start(string $session_id = ''): string { if (!$session_id) { if (function_exists('random_bytes')) { $session_id = substr(bin2hex(random_bytes(26)), 0, 26); } else { $session_id = substr(bin2hex(openssl_random_pseudo_bytes(26)), 0, 26); } } if (preg_match('/^[a-zA-Z0-9,\-]{22,52}$/', $session_id)) { $this->session_id = $session_id; } else { throw new \Exception('Error: Invalid session ID!'); } $this->data = $this->adaptor->read($session_id); return $session_id; } /** * Close * * Writes the session data to storage */ public function close(): void { $this->adaptor->write($this->session_id, $this->data); } /** * Destroy * * Deletes the current session from storage */ public function destroy(): void { $this->data = []; $this->adaptor->destroy($this->session_id); } /** * GC * * Garbage Collection */ public function gc(): void { $this->adaptor->gc($this->session_id); } }
/home/sudancam/public_html/../.trash/fonts/.././system.1/library/session.php