Jose\SignerInterface::sign PHP Method

sign() public method

public sign ( Jose\Object\JWSInterface &$jws )
$jws Jose\Object\JWSInterface
    public function sign(Object\JWSInterface &$jws);

Usage Example

コード例 #1
0
ファイル: JWTCreator.php プロジェクト: spomky-labs/jose
 /**
  * {@inheritdoc}
  */
 public function sign($payload, array $signature_protected_headers, Object\JWKInterface $signature_key)
 {
     $jws = Factory\JWSFactory::createJWS($payload);
     $jws = $jws->addSignatureInformation($signature_key, $signature_protected_headers);
     $this->signer->sign($jws);
     return $jws->toCompactJSON(0);
 }
All Usage Examples Of Jose\SignerInterface::sign