lab/cacme/vendor/acmephp/ssl/KeyPair.php

43 lines
862 B
PHP
Raw Permalink Normal View History

2024-08-05 20:27:28 +05:30
<?php
/*
* This file is part of the Acme PHP project.
*
* (c) Titouan Galopin <galopintitouan@gmail.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace AcmePhp\Ssl;
/**
* Represent a SSL key-pair (public and private).
*
* @author Titouan Galopin <galopintitouan@gmail.com>
*/
class KeyPair
{
/** @var PublicKey */
private $publicKey;
/** @var PrivateKey */
private $privateKey;
public function __construct(PublicKey $publicKey, PrivateKey $privateKey)
{
$this->publicKey = $publicKey;
$this->privateKey = $privateKey;
}
public function getPublicKey(): PublicKey
{
return $this->publicKey;
}
public function getPrivateKey(): PrivateKey
{
return $this->privateKey;
}
}