1 | <?php |
||
14 | final class GeneratorPoint extends Point |
||
15 | { |
||
16 | /** |
||
17 | * @var \Jose\Component\Core\Util\Ecc\Random\DebugDecorator|RandomNumberGenerator|null |
||
18 | */ |
||
19 | private $generator; |
||
20 | |||
21 | /** |
||
22 | * @param GmpMath $adapter |
||
23 | * @param CurveFp $curve |
||
24 | * @param \GMP $x |
||
25 | * @param \GMP $y |
||
26 | * @param \GMP $order |
||
27 | * @param RandomNumberGenerator $generator |
||
28 | */ |
||
29 | public function __construct( |
||
40 | |||
41 | /** |
||
42 | * Verifies validity of given coordinates against the current point and its point. |
||
43 | * |
||
44 | * @todo Check if really necessary here (only used for testing in lib) |
||
45 | * @param \GMP $x |
||
46 | * @param \GMP $y |
||
47 | * @return boolean |
||
48 | */ |
||
49 | public function isValid(\GMP $x, \GMP $y) |
||
74 | |||
75 | /** |
||
76 | * @return PrivateKey |
||
77 | */ |
||
78 | public function createPrivateKey() |
||
84 | |||
85 | /** |
||
86 | * @param \GMP $x |
||
87 | * @param \GMP $y |
||
88 | * @param \GMP $order |
||
89 | * @return PublicKey |
||
90 | */ |
||
91 | public function getPublicKeyFrom(\GMP $x, \GMP $y, \GMP $order = null) |
||
96 | |||
97 | /** |
||
98 | * @param \GMP $secretMultiplier |
||
99 | * @return PrivateKey |
||
100 | */ |
||
101 | public function getPrivateKeyFrom(\GMP $secretMultiplier) |
||
105 | } |
||
106 |