OXIESEC PANEL
- Current Dir:
/
/
var
/
www
/
firebase
/
vendor
/
google
/
auth
/
tests
/
mocks
Server IP: 139.59.38.164
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
08/12/2024 10:36:16 AM
rwxr-xr-x
📄
AppIdentityService.php
817 bytes
08/12/2024 10:33:45 AM
rw-r--r--
📄
TestFileCacheItemPool.php
5.09 KB
08/12/2024 10:33:45 AM
rw-r--r--
📄
test_file_cache_separate_process.php
1.11 KB
08/12/2024 10:33:45 AM
rw-r--r--
Editing: test_file_cache_separate_process.php
Close
<?php require_once __DIR__ . '/../../vendor/autoload.php'; require_once __DIR__ . '/TestFileCacheItemPool.php'; use Google\Auth\FetchAuthTokenCache; use Google\Auth\FetchAuthTokenInterface; use Google\Auth\GetUniverseDomainInterface; use Google\Auth\Tests\TestFileCacheItemPool; $cache = new TestFileCacheItemPool(sys_get_temp_dir() . '/google-auth-test'); $fetcher = new class($argv[1]) implements FetchAuthTokenInterface, GetUniverseDomainInterface { private $cacheKey; public function __construct(string $cacheKey) { $this->cacheKey = $cacheKey; } public function getUniverseDomain(): string { throw new \Exception('Should not be called!'); } public function getCacheKey() { return $this->cacheKey; } // no op public function fetchAuthToken(?callable $httpHandle = null) { } // no op public function getLastReceivedToken() { } }; $cacheFetcher = new FetchAuthTokenCache( $fetcher, ['cacheUniverseDomain' => true], $cache ); echo $cacheFetcher->getUniverseDomain();