You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

31 lines
829 B

  1. /**
  2. * @file f_magic.h
  3. * @copyright
  4. * Copyright (c) 2014 Cryptography Research, Inc. \n
  5. * Released under the MIT License. See LICENSE.txt for license information.
  6. * @author Mike Hamburg
  7. * @brief Goldilocks magic numbers (group orders, coefficients, algo params etc).
  8. */
  9. #ifndef __GOLDI_F_MAGIC_H__
  10. #define __GOLDI_F_MAGIC_H__ 1
  11. #include "field.h"
  12. #include "ec_point.h"
  13. /**
  14. * @brief The Edwards "d" term for this curve.
  15. */
  16. static const int64_t EDWARDS_D = -376014;
  17. /** @brief The number of combs to use for signed comb algo */
  18. #define COMB_N (USE_BIG_COMBS ? 4 : 5)
  19. /** @brief The number of teeth of the combs for signed comb algo */
  20. #define COMB_T (USE_BIG_COMBS ? 5 : 4)
  21. /** @brief The spacing the of combs for signed comb algo */
  22. #define COMB_S (USE_BIG_COMBS ? 26 : 26)
  23. #endif /* __GOLDI_F_MAGIC_H__ */