PSR7Sessions\Storageless\Http\SessionMiddleware::fromSymmetricKeyDefaults PHP Метод

fromSymmetricKeyDefaults() публичный статический Метод

This constructor simplifies instantiation when using HTTPS (REQUIRED!) and symmetric key encription
public static fromSymmetricKeyDefaults ( string $symmetricKey, integer $expirationTime ) : SessionMiddleware
$symmetricKey string
$expirationTime integer
Результат SessionMiddleware
    public static function fromSymmetricKeyDefaults(string $symmetricKey, int $expirationTime) : SessionMiddleware
    {
        return new self(new Signer\Hmac\Sha256(), $symmetricKey, $symmetricKey, SetCookie::create(self::DEFAULT_COOKIE)->withSecure(true)->withHttpOnly(true)->withPath('/'), new Parser(), $expirationTime, new SystemCurrentTime());
    }