| 1 |
<?php |
| 2 |
|
| 3 |
declare(strict_types=1); |
| 4 |
|
| 5 |
namespace Jose\Component\KeyManagement\Analyzer; |
| 6 |
|
| 7 |
use Jose\Component\Core\Util\Ecc\Curve; |
| 8 |
use Jose\Component\Core\Util\Ecc\NistCurve; |
| 9 |
|
| 10 |
final class ES256KeyAnalyzer extends ESKeyAnalyzer |
| 11 |
{ |
| 12 |
protected function getAlgorithmName(): string |
| 13 |
{ |
| 14 |
return 'ES256'; |
| 15 |
} |
| 16 |
|
| 17 |
protected function getCurveName(): string |
| 18 |
{ |
| 19 |
return 'P-256'; |
| 20 |
} |
| 21 |
|
| 22 |
protected function getCurve(): Curve |
| 23 |
{ |
| 24 |
return NistCurve::curve256(); |
| 25 |
} |
| 26 |
|
| 27 |
protected function getKeySize(): int |
| 28 |
{ |
| 29 |
return 256; |
| 30 |
} |
| 31 |
} |