Lines Matching refs:curve

101         $curve = self::loadCurveByParam($xpath);
106 self::extractPointRFC4050($xpath, $curve) :
107 self::extractPoint("\0" . $pubkey, $curve);
183 private static function extractPointRFC4050(\DOMXPath $xpath, BaseCurve $curve) argument
194 $curve->convertInteger(new BigInteger($x->item(0)->getAttribute('Value'))),
195 $curve->convertInteger(new BigInteger($y->item(0)->getAttribute('Value')))
197 if (!$curve->verifyPoint($point)) {
221 $curve = '\phpseclib3\Crypt\EC\Curves\\' . $name;
222 if (!class_exists($curve)) {
225 return new $curve();
265 $curve = new PrimeCurve();
266 $curve->setModulo(new BigInteger($p, 256));
267 $curve->setCoefficients(
271 $point = self::extractPoint("\0" . $base, $curve);
272 $curve->setBasePoint(...$point);
273 $curve->setOrder(new BigInteger($order, 256));
274 return $curve;
317 $curve = new PrimeCurve();
320 $curve->setModulo(new BigInteger($p));
324 $curve->setCoefficients(
331 $curve->setBasePoint(
337 $curve->setOrder(new BigInteger($order));
338 return $curve;
380 public static function savePublicKey(BaseCurve $curve, array $publicKey, array $options = []) argument
384 if ($curve instanceof TwistedEdwardsCurve || $curve instanceof MontgomeryCurve) {
397 self::encodeXMLParameters($curve, $pre, $options) . "\r\n" .
408 self::encodeXMLParameters($curve, $pre, $options) . "\r\n" .
421 private static function encodeXMLParameters(BaseCurve $curve, $pre, array $options = []) argument
423 $result = self::encodeParameters($curve, true, $options);
441 $a = $curve->getA();
442 $b = $curve->getB();
443 list($x, $y) = $curve->getBasePoint();
460 '<' . $pre . 'Order>' . $curve->getOrder() . '</' . $pre . 'Order>' . "\r\n" .