1 | <?php |
||
8 | class Certificate |
||
9 | { |
||
10 | /** |
||
11 | * @param string The contents of the certificate |
||
12 | */ |
||
13 | protected $contents; |
||
14 | |||
15 | /** |
||
16 | * @param string $inputFile |
||
17 | * |
||
18 | * @return static |
||
19 | */ |
||
20 | public static function loadFromFile(string $inputFile) |
||
24 | |||
25 | /** |
||
26 | * @param string $url |
||
27 | * |
||
28 | * @return static |
||
29 | */ |
||
30 | public static function loadFromUrl(string $url) |
||
34 | |||
35 | public function __construct(string $contents) |
||
41 | |||
42 | /** |
||
43 | * Get the URL of the parent certificate. |
||
44 | */ |
||
45 | public function getParentCertificateUrl(): string |
||
63 | |||
64 | public function fetchParentCertificate(): Certificate |
||
68 | |||
69 | public function hasParentInTrustChain(): bool |
||
73 | |||
74 | public function getContents(): string |
||
80 | |||
81 | protected function guardAgainstInvalidContents(string $content) |
||
87 | } |
||
88 |