532479301
88d1a649a2
Consensus: Fix bug when compiler do not support __builtin_clz*
...
#ifdef is not correct since defination is defined to 0 or 1. Should change to #if
Github-Pull: #12573
Rebased-From: 18307849b405f9e2067eaa8091b105838f413707
6 years ago
Adrian Gallagher
5c8e26d493
Litecoin: Basic changes for v0.16 release ( #482 )
...
* Litecon: Modify thread names
Since this string is displayed externally within lists of processes and should be consistent with branding, and not cause confusion for admins, when running "top", "ps aux", "pgrep" or similar commands.
* Litecoin: Remove invalid doxygen link
* Litecoin: Add additional optional build steps for osx builds
Fixes: https://github.com/litecoin-project/litecoin/issues/463
* Litecoin: Show scrypt sse2 status in configure and fix scrypt syntax issue
7 years ago
Romano
08f2538862
Litecoin: Enable support for SSE2 instructions in scrypt via configure --enable-sse2 ( #362 )
7 years ago
shaolinfry
4b588c670c
Litecoin: Add scrypt N=1024 PoW
7 years ago
Akira Takizawa
595a7bab23
Increment MIT Licence copyright header year on files modified in 2017
7 years ago
MeshCollider
1a445343f6
scripted-diff: Replace #include "" with #include <> (ryanofsky)
...
-BEGIN VERIFY SCRIPT-
for f in \
src/*.cpp \
src/*.h \
src/bench/*.cpp \
src/bench/*.h \
src/compat/*.cpp \
src/compat/*.h \
src/consensus/*.cpp \
src/consensus/*.h \
src/crypto/*.cpp \
src/crypto/*.h \
src/crypto/ctaes/*.h \
src/policy/*.cpp \
src/policy/*.h \
src/primitives/*.cpp \
src/primitives/*.h \
src/qt/*.cpp \
src/qt/*.h \
src/qt/test/*.cpp \
src/qt/test/*.h \
src/rpc/*.cpp \
src/rpc/*.h \
src/script/*.cpp \
src/script/*.h \
src/support/*.cpp \
src/support/*.h \
src/support/allocators/*.h \
src/test/*.cpp \
src/test/*.h \
src/wallet/*.cpp \
src/wallet/*.h \
src/wallet/test/*.cpp \
src/wallet/test/*.h \
src/zmq/*.cpp \
src/zmq/*.h
do
base=${f%/*}/ relbase=${base#src/} sed -i "s:#include \"\(.*\)\"\(.*\):if test -e \$base'\\1'; then echo \"#include <\"\$relbase\"\\1>\\2\"; else echo \"#include <\\1>\\2\"; fi:e" $f
done
-END VERIFY SCRIPT-
7 years ago
Utsav Gupta
dc334fe749
Update hmac_sha256.h
...
Fixed a typo
7 years ago
danra
5abb93f0ee
Fix include path for bitcoin-config.h in crypto/common.h
...
All the other files in the repo which include bitcoin-config.h do so with the appropriate subfolder prefixed: config/bitcoin-config.h
The header should be included with the appropriate subfolder here as well.
This canonicalization also allows getting rid of a bit of extra configuration in Makefile.am.
7 years ago
Wladimir J. van der Laan
ce5381e7fe
build: Rename --enable-experimental-asm to --enable-asm and enable by default
...
Now that 0.15 is branched off, enable assembler SHA256 optimizations by default.
7 years ago
practicalswift
64fb0ac016
Declare single-argument (non-converting) constructors "explicit"
...
In order to avoid unintended implicit conversions.
7 years ago
practicalswift
90d4d89230
scripted-diff: Use the C++11 keyword nullptr to denote the pointer literal instead of the macro NULL
...
-BEGIN VERIFY SCRIPT-
sed -i 's/\<NULL\>/nullptr/g' src/*.cpp src/*.h src/*/*.cpp src/*/*.h src/qt/*/*.cpp src/qt/*/*.h src/wallet/*/*.cpp src/wallet/*/*.h src/support/allocators/*.h
sed -i 's/Prefer nullptr, otherwise SAFECOOKIE./Prefer NULL, otherwise SAFECOOKIE./g' src/torcontrol.cpp
sed -i 's/tor: Using nullptr authentication/tor: Using NULL authentication/g' src/torcontrol.cpp
sed -i 's/METHODS=nullptr/METHODS=NULL/g' src/test/torcontrol_tests.cpp src/torcontrol.cpp
sed -i 's/nullptr certificates/NULL certificates/g' src/qt/paymentserver.cpp
sed -i 's/"nullptr"/"NULL"/g' src/torcontrol.cpp src/test/torcontrol_tests.cpp
-END VERIFY SCRIPT-
7 years ago
Pieter Wuille
6b8d872e5e
Protect SSE4 code behind a compile-time flag
7 years ago
Pieter Wuille
fa9be909c9
Add selftest for SHA256 transform
7 years ago
Pieter Wuille
c1ccb15b0e
Add SSE4 based SHA256
7 years ago
Pieter Wuille
2991c91d88
Add SHA256 dispatcher
7 years ago
Pieter Wuille
4d50f38fe0
Support multi-block SHA256 transforms
...
Extracted from a patch by Wladimir van der Laan.
7 years ago
practicalswift
90593ed92c
Limit variable scope
8 years ago
Pieter Wuille
4fd2d2fc97
Add a FastRandomContext::randrange and use it
8 years ago
Pieter Wuille
e04326fe66
Add ChaCha20
8 years ago
Pieter Wuille
843c560003
Avoid unaligned access in crypto i/o
8 years ago
isle2983
27765b6403
Increment MIT Licence copyright header year on files modified in 2016
...
Edited via:
$ contrib/devtools/copyright_header.py update .
8 years ago
fsb4000
15fa95d7e5
Fix some typos
8 years ago
Cory Fields
27a212dcb4
crypto: add AES 128/256 CBC classes
...
The output should always match openssl's, even for failed operations. Even for
a decrypt with broken padding, the output is always deterministic (and attemtps
to be constant-time).
9 years ago
Pieter Wuille
6bec172eb9
Add ctaes-based constant time AES implementation
9 years ago
Wladimir J. van der Laan
9ad1a51857
crypto: bytes counts are 64 bit
...
Byte counts for SHA256, SHA512, SHA1 and RIPEMD160 must be 64 bits.
`size_t` has a different size per platform, causing divergent results
when hashing more than 4GB of data.
9 years ago
Wladimir J. van der Laan
4414f5ffe1
build: Endian compatibility
...
- Detect endian instead of stopping configure on big-endian
- Add `byteswap.h` and `endian.h` header for compatibility with
Windows and other operating systems that don't come with them
- Update `crypto/common.h` functions to use compat
endian header
10 years ago
Pieter Wuille
1a9576de9d
Use libsecp256k1's RFC6979 implementation
10 years ago
sandakersmann
f914f1a746
Added "Core" to copyright headers
...
Github-Pull: #5494
Rebased-From: 15de949bb9277e442302bdd8dee299a8d6deee60
10 years ago
Pieter Wuille
9d8604f36a
Header define style cleanups
10 years ago
Pieter Wuille
3060e36098
Add the RFC6979 PRNG
10 years ago
Pieter Wuille
a8f5087e53
Add HMAC-SHA256
10 years ago
Pieter Wuille
36fa4a78ac
Split up crypto/sha2
10 years ago
Pavel Janík
84738627ce
Fix all header defines
10 years ago
Philip Kaufmann
0db65d8798
update license of compat and crypto
...
- change license to be just MIT for all files in compat and crypto
- also add missing header end comments
- ensure default header include style
10 years ago
Pieter Wuille
cf42c36e99
Apply clang-format on crypto/* and compat/*
10 years ago
Philip Kaufmann
611116d4e3
header include cleanup
...
- ensures alphabetical ordering for includes etc. in source file headers
10 years ago
Pieter Wuille
a0495bb68c
Add <Hasher>::OUTPUT_SIZE
11 years ago
Cory Fields
f2647cc0e9
crypto: explicitly check for byte read/write functions
...
Don't depend on hard-coded platform lists
11 years ago
Pieter Wuille
7ecd9739d9
Move {Read,Write}{LE,BE}{32,64} to common.h and use builtins if possible
11 years ago
Pieter Wuille
a5bc9c0917
Add built-in RIPEMD-160 implementation
11 years ago
Pieter Wuille
13b5dfef64
Move crypto implementations to src/crypto/
11 years ago