dsa.py 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. # This file is dual licensed under the terms of the Apache License, Version
  2. # 2.0, and the BSD License. See the LICENSE file in the root of this repository
  3. # for complete details.
  4. from __future__ import absolute_import, division, print_function
  5. INCLUDES = """
  6. #include <openssl/dsa.h>
  7. """
  8. TYPES = """
  9. typedef ... DSA;
  10. """
  11. FUNCTIONS = """
  12. int DSA_generate_key(DSA *);
  13. DSA *DSA_new(void);
  14. void DSA_free(DSA *);
  15. DSA *DSAparams_dup(DSA *);
  16. int DSA_size(const DSA *);
  17. int DSA_sign(int, const unsigned char *, int, unsigned char *, unsigned int *,
  18. DSA *);
  19. int DSA_verify(int, const unsigned char *, int, const unsigned char *, int,
  20. DSA *);
  21. /* added in 1.1.0 to access the opaque struct */
  22. void DSA_get0_pqg(const DSA *, const BIGNUM **, const BIGNUM **,
  23. const BIGNUM **);
  24. int DSA_set0_pqg(DSA *, BIGNUM *, BIGNUM *, BIGNUM *);
  25. void DSA_get0_key(const DSA *, const BIGNUM **, const BIGNUM **);
  26. int DSA_set0_key(DSA *, BIGNUM *, BIGNUM *);
  27. int DSA_generate_parameters_ex(DSA *, int, unsigned char *, int,
  28. int *, unsigned long *, BN_GENCB *);
  29. """
  30. CUSTOMIZATIONS = """
  31. """