1. 22 6月, 2018 1 次提交
  2. 24 5月, 2018 1 次提交
  3. 04 4月, 2018 1 次提交
    • D
      Fix a bug in ecp_nistp224.c. · dc55e4f7
      David Benjamin 提交于
      felem_neg does not produce an output within the tight bounds suitable
      for felem_contract. This affects build configurations which set
      enable-ec_nistp_64_gcc_128.
      
      point_double and point_add, in the non-z*_is_zero cases, tolerate and
      fix up the wider bounds, so this only affects point_add calls where the
      other point is infinity. Thus it only affects the final addition in
      arbitrary-point multiplication, giving the wrong y-coordinate. This is a
      no-op for ECDH and ECDSA, which only use the x-coordinate of
      arbitrary-point operations.
      
      Note: ecp_nistp521.c has the same issue in that the documented
      preconditions are violated by the test case. I have not addressed this
      in this PR. ecp_nistp521.c does not immediately produce the wrong
      answer; felem_contract there appears to be a bit more tolerant than its
      documented preconditions. However, I haven't checked the point_add
      property above holds. ecp_nistp521.c should either get this same fix, to
      be conservative, or have the bounds analysis and comments reworked for
      the wider bounds.
      Reviewed-by: NRich Salz <rsalz@openssl.org>
      (Merged from https://github.com/openssl/openssl/pull/5779)
      dc55e4f7
  4. 20 3月, 2018 1 次提交
  5. 05 3月, 2018 1 次提交
  6. 08 12月, 2017 1 次提交
  7. 27 8月, 2017 1 次提交
  8. 22 8月, 2017 1 次提交
  9. 18 8月, 2017 1 次提交
  10. 10 8月, 2017 1 次提交
  11. 03 8月, 2017 1 次提交
    • R
      Switch from ossl_rand to DRBG rand · 75e2c877
      Rich Salz 提交于
      If RAND_add wraps around, XOR with existing. Add test to drbgtest that
      does the wrap-around.
      
      Re-order seeding and stop after first success.
      
      Add RAND_poll_ex()
      
      Use the DF and therefore lower RANDOMNESS_NEEDED.  Also, for child DRBG's,
      mix in the address as the personalization bits.
      
      Centralize the entropy callbacks, from drbg_lib to rand_lib.
      (Conceptually, entropy is part of the enclosing application.)
      Thanks to Dr. Matthias St Pierre for the suggestion.
      
      Various code cleanups:
          -Make state an enum; inline RANDerr calls.
          -Add RAND_POLL_RETRIES (thanks Pauli for the idea)
          -Remove most RAND_seed calls from rest of library
          -Rename DRBG_CTX to RAND_DRBG, etc.
          -Move some code from drbg_lib to drbg_rand; drbg_lib is now only the
           implementation of NIST DRBG.
          -Remove blocklength
      Reviewed-by: NPaul Dale <paul.dale@oracle.com>
      (Merged from https://github.com/openssl/openssl/pull/4019)
      75e2c877
  12. 27 7月, 2017 1 次提交
    • P
      Update the test framework so that the need for test_main is removed. Everything · ad887416
      Pauli 提交于
      that needed test_main now works using the same infrastructure as tests that used
      register_tests.
      
      This meant:
      * renaming register_tests to setup_tests and giving it a success/failure return.
      * renaming the init_test function to setup_test_framework.
      * renaming the finish_test function to pulldown_test_framework.
      * adding a user provided global_init function that runs before the test frame
          work is initialised.  It returns a failure indication that stops the stest.
      * adding helper functions that permit tests to access their command line args.
      * spliting the BIO initialisation and finalisation out from the test setup and
          teardown.
      * hiding some of the now test internal functions.
      * fix the comments in testutil.h
      Reviewed-by: NRichard Levitte <levitte@openssl.org>
      (Merged from https://github.com/openssl/openssl/pull/3953)
      ad887416
  13. 04 7月, 2017 1 次提交
  14. 28 6月, 2017 1 次提交
  15. 20 6月, 2017 1 次提交
  16. 17 6月, 2017 1 次提交
  17. 10 5月, 2017 1 次提交
  18. 06 5月, 2017 1 次提交
  19. 01 3月, 2017 1 次提交
  20. 22 8月, 2016 1 次提交
  21. 10 6月, 2016 1 次提交
    • E
      RT 4242: reject invalid EC point coordinates · 1e2012b7
      Emilia Kasper 提交于
      We already test in EC_POINT_oct2point that points are on the curve. To
      be on the safe side, move this check to
      EC_POINT_set_affine_coordinates_* so as to also check point coordinates
      received through some other method.
      
      We do not check projective coordinates, though, as
      - it's unlikely that applications would be receiving this primarily
        internal representation from untrusted sources, and
      - it's possible that the projective setters are used in a setting where
        performance matters.
      Reviewed-by: NRich Salz <rsalz@openssl.org>
      1e2012b7
  22. 18 5月, 2016 1 次提交
  23. 29 2月, 2016 1 次提交
  24. 24 2月, 2016 1 次提交
  25. 09 2月, 2016 1 次提交
  26. 06 2月, 2016 1 次提交
  27. 29 1月, 2016 1 次提交
  28. 28 1月, 2016 1 次提交
  29. 27 1月, 2016 1 次提交
    • R
      Remove /* foo.c */ comments · 34980760
      Rich Salz 提交于
      This was done by the following
              find . -name '*.[ch]' | /tmp/pl
      where /tmp/pl is the following three-line script:
              print unless $. == 1 && m@/\* .*\.[ch] \*/@;
              close ARGV if eof; # Close file to reset $.
      
      And then some hand-editing of other files.
      Reviewed-by: NViktor Dukhovni <viktor@openssl.org>
      34980760
  30. 11 1月, 2016 1 次提交
  31. 08 1月, 2016 1 次提交
    • R
      mem functions cleanup · bbd86bf5
      Rich Salz 提交于
      Only two macros CRYPTO_MDEBUG and CRYPTO_MDEBUG_ABORT to control this.
      If CRYPTO_MDEBUG is not set, #ifdef out the whole debug machinery.
              (Thanks to Jakob Bohm for the suggestion!)
      Make the "change wrapper functions" be the only paradigm.
      Wrote documentation!
      Format the 'set func' functions so their paramlists are legible.
      Format some multi-line comments.
      Remove ability to get/set the "memory debug" functions at runtme.
      Remove MemCheck_* and CRYPTO_malloc_debug_init macros.
      Add CRYPTO_mem_debug(int flag) function.
      Add test/memleaktest.
      Rename CRYPTO_malloc_init to OPENSSL_malloc_init; remove needless calls.
      Reviewed-by: NRichard Levitte <levitte@openssl.org>
      bbd86bf5
  32. 20 12月, 2015 1 次提交
  33. 10 6月, 2015 1 次提交
    • M
      EC_POINT_is_on_curve does not return a boolean · 68886be7
      Matt Caswell 提交于
      The function EC_POINT_is_on_curve does not return a boolean value.
      It returns 1 if the point is on the curve, 0 if it is not, and -1
      on error. Many usages within OpenSSL were incorrectly using this
      function and therefore not correctly handling error conditions.
      
      With thanks to the Open Crypto Audit Project for reporting this issue.
      Reviewed-by: NKurt Roeckx <kurt@openssl.org>
      68886be7
  34. 11 5月, 2015 1 次提交
  35. 05 5月, 2015 1 次提交
    • R
      Use safer sizeof variant in malloc · b4faea50
      Rich Salz 提交于
      For a local variable:
              TYPE *p;
      Allocations like this are "risky":
              p = OPENSSL_malloc(sizeof(TYPE));
      if the type of p changes, and the malloc call isn't updated, you
      could get memory corruption.  Instead do this:
              p = OPENSSL_malloc(sizeof(*p));
      Also fixed a few memset() calls that I noticed while doing this.
      Reviewed-by: NRichard Levitte <levitte@openssl.org>
      b4faea50
  36. 04 5月, 2015 1 次提交
  37. 01 5月, 2015 1 次提交
    • R
      free NULL cleanup 7 · 23a1d5e9
      Rich Salz 提交于
      This gets BN_.*free:
          BN_BLINDING_free BN_CTX_free BN_FLG_FREE BN_GENCB_free
          BN_MONT_CTX_free BN_RECP_CTX_free BN_clear_free BN_free BUF_MEM_free
      
      Also fix a call to DSA_SIG_free to ccgost engine and remove some #ifdef'd
      dead code in engines/e_ubsec.
      Reviewed-by: NRichard Levitte <levitte@openssl.org>
      23a1d5e9
  38. 01 4月, 2015 1 次提交
  39. 26 3月, 2015 1 次提交
  40. 06 2月, 2015 1 次提交