key = $key; } public function getAlgorithmId(): string { return 'HS256'; } public function getSigner(): Signer { return new Sha256(); } public function getPrivateKey(): Key { return $this->loadKey(); } public function getPublicKey(): Key { return $this->loadKey(); } private function loadKey(): Key { if ($this->loadedKey === null) { $this->loadedKey = new Key($this->key); } return $this->loadedKey; } }