Debian Codegraph @

lib/3rdParty/composer/web-auth/cose-lib/src/Algorithm/Signature/ECDSA/ES512.php

raw symbols SCIP
1 <?php
2
3 declare(strict_types=1);
4
5 namespace Cose\Algorithm\Signature\ECDSA;
6
7 use Cose\Key\Ec2Key;
8 use const OPENSSL_ALGO_SHA512;
9
10 final class ES512 extends ECDSA
11 {
12 public const ID = -36;
13
14 public static function create(): self
15 {
16 return new self();
17 }
18
19 public static function identifier(): int
20 {
21 return self::ID;
22 }
23
24 protected function getHashAlgorithm(): int
25 {
26 return OPENSSL_ALGO_SHA512;
27 }
28
29 protected function getCurve(): int
30 {
31 return Ec2Key::CURVE_P521;
32 }
33
34 protected function getSignaturePartLength(): int
35 {
36 return 132;
37 }
38 }