1. 29 1月, 2016 1 次提交
  2. 28 1月, 2016 1 次提交
  3. 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
  4. 20 1月, 2016 1 次提交
  5. 19 1月, 2016 1 次提交
  6. 18 1月, 2016 1 次提交
  7. 13 1月, 2016 1 次提交
  8. 12 1月, 2016 6 次提交
  9. 08 1月, 2016 3 次提交
    • 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
    • D
      Only declare stacks in headers · 4a1f3f27
      Dr. Stephen Henson 提交于
      Don't define stacks in C source files: it causes warnings
      about unused functions in some compilers.
      Reviewed-by: NRichard Levitte <levitte@openssl.org>
      4a1f3f27
    • D
      Rename DECLARE*STACK_OF to DEFINE*STACK_OF · 85885715
      Dr. Stephen Henson 提交于
      Applications wishing to include their own stacks now just need to include
      
      DEFINE_STACK_OF(foo)
      
      in a header file.
      Reviewed-by: NRichard Levitte <levitte@openssl.org>
      85885715
  10. 17 12月, 2015 1 次提交
    • R
      Rename some BUF_xxx to OPENSSL_xxx · 7644a9ae
      Rich Salz 提交于
      Rename BUF_{strdup,strlcat,strlcpy,memdup,strndup,strnlen}
      to OPENSSL_{strdup,strlcat,strlcpy,memdup,strndup,strnlen}
      Add #define's for the old names.
      Add CRYPTO_{memdup,strndup}, called by OPENSSL_{memdup,strndup} macros.
      Reviewed-by: NTim Hudson <tjh@openssl.org>
      7644a9ae
  11. 11 12月, 2015 1 次提交
  12. 10 12月, 2015 1 次提交
  13. 10 11月, 2015 1 次提交
  14. 05 11月, 2015 1 次提交
  15. 06 10月, 2015 1 次提交
  16. 04 9月, 2015 1 次提交
  17. 17 8月, 2015 1 次提交
  18. 23 6月, 2015 1 次提交
  19. 09 6月, 2015 1 次提交
  20. 03 6月, 2015 1 次提交
  21. 23 5月, 2015 1 次提交
    • R
      Fix the update target and remove duplicate file updates · 0f539dc1
      Richard Levitte 提交于
      We had updates of certain header files in both Makefile.org and the
      Makefile in the directory the header file lived in.  This is error
      prone and also sometimes generates slightly different results (usually
      just a comment that differs) depending on which way the update was
      done.
      
      This removes the file update targets from the top level Makefile, adds
      an update: target in all Makefiles and has it depend on the depend: or
      local_depend: targets, whichever is appropriate, so we don't get a
      double run through the whole file tree.
      Reviewed-by: NRich Salz <rsalz@openssl.org>
      0f539dc1
  22. 21 5月, 2015 1 次提交
  23. 14 5月, 2015 2 次提交
  24. 13 5月, 2015 2 次提交
    • H
      Call of memcmp with null pointers in obj_cmp() · 2b8dc08b
      Hanno Böck 提交于
      The function obj_cmp() (file crypto/objects/obj_dat.c) can in some
      situations call memcmp() with a null pointer and a zero length.
      
      This is invalid behaviour. When compiling openssl with undefined
      behaviour sanitizer (add -fsanitize=undefined to compile flags) this
      can be seen. One example that triggers this behaviour is the pkcs7
      command (but there are others, e.g. I've seen it with the timestamp
      function):
      apps/openssl pkcs7 -in test/testp7.pem
      
      What happens is that obj_cmp takes objects of the type ASN1_OBJECT and
      passes their ->data pointer to memcmp. Zero-sized ASN1_OBJECT
      structures can have a null pointer as data.
      
      RT#3816
      Signed-off-by: NMatt Caswell <matt@openssl.org>
      Reviewed-by: NRich Salz <rsalz@openssl.org>
      2b8dc08b
    • G
      Fix the heap corruption in libeay32!OBJ_add_object. · 56d88027
      Gunnar Kudrjavets 提交于
      Original 'sizeof(ADDED_OBJ)' was replaced with 'sizeof(*ao)'. However,
      they return different sizes. Therefore as the result heap gets corrupted
      and at some point later debug version of malloc() detects the corruption.
      
      On x86 we can observe that as follows:
      
      sizeof(*ao) == 4
      sizeof(*ao[0]) == sizeof(ADDED_OBJ) == 8
      
      Issue reproduces with either enabling CRT debug heap or Application
      Verifier's full-page heap.
      
      Basic debugging data from the moment the corruption is first detected:
      
      0:000:x86> |
      .  0    id: 283c        create  name: openssl.exe
      0:000:x86> kcn
       #
      00 MSVCR120D!_heap_alloc_dbg_impl
      01 MSVCR120D!_nh_malloc_dbg_impl
      02 MSVCR120D!_nh_malloc_dbg
      03 MSVCR120D!malloc
      04 LIBEAY32!default_malloc_ex
      05 LIBEAY32!CRYPTO_malloc
      06 LIBEAY32!lh_insert
      07 LIBEAY32!OBJ_add_object
      08 LIBEAY32!OBJ_create
      09 openssl!add_oid_section
      0a openssl!req_main
      0b openssl!do_cmd
      0c openssl!main
      0d openssl!__tmainCRTStartup
      0e openssl!mainCRTStartup
      0f KERNEL32!BaseThreadInitThunk
      10 ntdll_77d60000!__RtlUserThreadStart
      11 ntdll_77d60000!_RtlUserThreadStart
      Signed-off-by: NMatt Caswell <matt@openssl.org>
      Reviewed-by: NRichard Levitte <levitte@openssl.org>
      56d88027
  25. 11 5月, 2015 1 次提交
  26. 07 5月, 2015 1 次提交
  27. 06 5月, 2015 3 次提交
  28. 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
  29. 03 5月, 2015 1 次提交