Subversion Repositories oidplus

Rev

Rev 846 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed

  1. <?php
  2.  
  3. /**
  4.  * secp160r1
  5.  *
  6.  * PHP version 5 and 7
  7.  *
  8.  * @category  Crypt
  9.  * @package   EC
  10.  * @author    Jim Wigginton <terrafrost@php.net>
  11.  * @copyright 2017 Jim Wigginton
  12.  * @license   http://www.opensource.org/licenses/mit-license.html  MIT License
  13.  * @link      http://pear.php.net/package/Math_BigInteger
  14.  */
  15.  
  16. namespace phpseclib3\Crypt\EC\Curves;
  17.  
  18. use phpseclib3\Crypt\EC\BaseCurves\Prime;
  19. use phpseclib3\Math\BigInteger;
  20.  
  21. class secp160r1 extends Prime
  22. {
  23.     public function __construct()
  24.     {
  25.         $this->setModulo(new BigInteger('FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF7FFFFFFF', 16));
  26.         $this->setCoefficients(
  27.             new BigInteger('FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF7FFFFFFC', 16),
  28.             new BigInteger('1C97BEFC54BD7A8B65ACF89F81D4D4ADC565FA45', 16)
  29.         );
  30.         $this->setBasePoint(
  31.             new BigInteger('4A96B5688EF573284664698968C38BB913CBFC82', 16),
  32.             new BigInteger('23A628553168947D59DCC912042351377AC5FB32', 16)
  33.         );
  34.         $this->setOrder(new BigInteger('0100000000000000000001F4C8F927AED3CA752257', 16));
  35.     }
  36. }
  37.