Rev 874 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 874 | Rev 1042 | ||
---|---|---|---|
Line 5... | Line 5... | ||
5 | * |
5 | * |
6 | * PHP version 5 |
6 | * PHP version 5 |
7 | * |
7 | * |
8 | * Reads and creates arrays as DSA keys |
8 | * Reads and creates arrays as DSA keys |
9 | * |
9 | * |
10 | * @category Crypt |
- | |
11 | * @package DSA |
- | |
12 | * @author Jim Wigginton <terrafrost@php.net> |
10 | * @author Jim Wigginton <terrafrost@php.net> |
13 | * @copyright 2015 Jim Wigginton |
11 | * @copyright 2015 Jim Wigginton |
14 | * @license http://www.opensource.org/licenses/mit-license.html MIT License |
12 | * @license http://www.opensource.org/licenses/mit-license.html MIT License |
15 | * @link http://phpseclib.sourceforge.net |
13 | * @link http://phpseclib.sourceforge.net |
16 | */ |
14 | */ |
Line 20... | Line 18... | ||
20 | use phpseclib3\Math\BigInteger; |
18 | use phpseclib3\Math\BigInteger; |
21 | 19 | ||
22 | /** |
20 | /** |
23 | * Raw DSA Key Handler |
21 | * Raw DSA Key Handler |
24 | * |
22 | * |
25 | * @package DSA |
- | |
26 | * @author Jim Wigginton <terrafrost@php.net> |
23 | * @author Jim Wigginton <terrafrost@php.net> |
27 | * @access public |
- | |
28 | */ |
24 | */ |
29 | abstract class Raw |
25 | abstract class Raw |
30 | { |
26 | { |
31 | /** |
27 | /** |
32 | * Break a public or private key down into its constituent components |
28 | * Break a public or private key down into its constituent components |
33 | * |
29 | * |
34 | * @access public |
- | |
35 | * @param array $key |
30 | * @param array $key |
36 | * @param string $password optional |
31 | * @param string $password optional |
37 | * @return array |
32 | * @return array |
38 | */ |
33 | */ |
39 | public static function load($key, $password = '') |
34 | public static function load($key, $password = '') |
Line 59... | Line 54... | ||
59 | } |
54 | } |
60 | 55 | ||
61 | /** |
56 | /** |
62 | * Convert a private key to the appropriate format. |
57 | * Convert a private key to the appropriate format. |
63 | * |
58 | * |
64 | * @access public |
- | |
65 | * @param \phpseclib3\Math\BigInteger $p |
59 | * @param \phpseclib3\Math\BigInteger $p |
66 | * @param \phpseclib3\Math\BigInteger $q |
60 | * @param \phpseclib3\Math\BigInteger $q |
67 | * @param \phpseclib3\Math\BigInteger $g |
61 | * @param \phpseclib3\Math\BigInteger $g |
68 | * @param \phpseclib3\Math\BigInteger $y |
62 | * @param \phpseclib3\Math\BigInteger $y |
69 | * @param \phpseclib3\Math\BigInteger $x |
63 | * @param \phpseclib3\Math\BigInteger $x |
Line 76... | Line 70... | ||
76 | } |
70 | } |
77 | 71 | ||
78 | /** |
72 | /** |
79 | * Convert a public key to the appropriate format |
73 | * Convert a public key to the appropriate format |
80 | * |
74 | * |
81 | * @access public |
- | |
82 | * @param \phpseclib3\Math\BigInteger $p |
75 | * @param \phpseclib3\Math\BigInteger $p |
83 | * @param \phpseclib3\Math\BigInteger $q |
76 | * @param \phpseclib3\Math\BigInteger $q |
84 | * @param \phpseclib3\Math\BigInteger $g |
77 | * @param \phpseclib3\Math\BigInteger $g |
85 | * @param \phpseclib3\Math\BigInteger $y |
78 | * @param \phpseclib3\Math\BigInteger $y |
86 | * @return string |
79 | * @return string |