Completed
Push — master ( 022625...2b82d4 )
by Florent
05:58
created

PS384   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 26
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 0
Metric Value
wmc 3
lcom 0
cbo 1
dl 0
loc 26
rs 10
c 0
b 0
f 0

3 Methods

Rating   Name   Duplication   Size   Complexity  
A getAlgorithm() 0 4 1
A getSignatureMethod() 0 4 1
A getAlgorithmName() 0 4 1
1
<?php
2
3
/*
4
 * The MIT License (MIT)
5
 *
6
 * Copyright (c) 2014-2016 Spomky-Labs
7
 *
8
 * This software may be modified and distributed under the terms
9
 * of the MIT license.  See the LICENSE file for details.
10
 */
11
12
namespace Jose\Algorithm\Signature;
13
14
use phpseclib\Crypt\RSA as PHPSecLibRSA;
15
16
/**
17
 * Class PS384.
18
 */
19
final class PS384 extends RSA
20
{
21
    /**
22
     * @return string
23
     */
24
    protected function getAlgorithm()
25
    {
26
        return 'sha384';
27
    }
28
29
    /**
30
     * @return int
31
     */
32
    protected function getSignatureMethod()
33
    {
34
        return PHPSecLibRSA::SIGNATURE_PSS;
35
    }
36
37
    /**
38
     * @return string
39
     */
40
    public function getAlgorithmName()
41
    {
42
        return 'PS384';
43
    }
44
}
45