Pieter Wuille
9570f674cc
Avoid passing out-of-bound pointers to 0-size memcpy
...
Doing so could be considered UB in a strict reading of the standard.
Avoid it.
2021-01-23 21:56:43 -08:00
Dimitris Apostolou
07aa4c70ff
Fix insecure links
2020-12-18 00:24:22 +02:00
fanquake
f00d6575ca
remove dead store in ecdsa_signature_parse_der_lax
...
This change was made in bitcoin/bitcoin without upstreaming. So this is
a followup to the comment here:
https://github.com/bitcoin/bitcoin/pull/19228#issuecomment-641795558 .
See also: https://github.com/bitcoin/bitcoin/pull/11073 .
2020-06-29 13:23:26 +08:00
Tim Ruffing
ec8f20babd
Avoid out-of-bound pointers and integer overflows in size comparisons
...
This changes pointer calculations in size comparions to a form that
ensures that no out-of-bound pointers are computed, because even their
computation yields undefined behavior.
Also, this changes size comparions to a form that ensures that neither
the left-hand side nor the right-hand side can overflow.
2019-05-23 15:22:29 +02:00
Andrew Poelstra
eed87af10a
Change contrib/laxder from headers-only to files compilable as standalone C
...
Verified that both programs compile with
gcc -I. -I../include -lsecp256k1 -c -W -Wextra -Wall -Werror -ansi -pedantic lax_der_privatekey_parsing.c
gcc -I. -I../include -lsecp256k1 -c -W -Wextra -Wall -Werror -ansi -pedantic lax_der_parsing.c
2015-10-29 18:55:49 -05:00