![]() Server : Apache System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64 User : corals ( 1002) PHP Version : 7.4.33 Disable Function : exec,passthru,shell_exec,system Directory : /home/corals/mautic.corals.io/vendor/litesaml/lightsaml/src/Credential/ |
<?php namespace LightSaml\Credential; use RobRichards\XMLSecLibs\XMLSecurityKey; class X509Credential extends AbstractCredential implements X509CredentialInterface { /** @var X509Certificate */ protected $certificate; /** * @param XMLSecurityKey $privateKey */ public function __construct(X509Certificate $certificate, XMLSecurityKey $privateKey = null) { parent::__construct(); $this->certificate = $certificate; $this->setPublicKey(KeyHelper::createPublicKey($certificate)); $this->setKeyNames([$this->getCertificate()->getName()]); if ($privateKey) { $this->setPrivateKey($privateKey); } } /** * @return X509Certificate */ public function getCertificate() { return $this->certificate; } }