libsodium: updated to 1.0.10
[tomato.git] / release / src / router / libsodium / ChangeLog
blobe3561d4022d43c86266fbf432018c8020d02b4d3
2 * Version 1.0.10
3  - This release only fixes a compilation issue reported with some older
4 gcc versions. There are no functional changes over the previous release.
6 * Version 1.0.9
7  - The Javascript target now includes a `--sumo` option to include all
8 the symbols of the original C library.
9  - A detached API was added to the ChaCha20-Poly1305 and AES256-GCM
10 implementations.
11  - The Argon2i password hashing function was added, and is accessible
12 directly and through a new, high-level `crypto_pwhash` API. The scrypt
13 function remains available as well.
14  - A speed-record AVX2 implementation of BLAKE2b was added (thanks to
15 Samuel Neves).
16  - The library can now be compiled using C++Builder (thanks to @jcolli44)
17  - Countermeasures for Ed25519 signatures malleability have been added
18 to match the irtf-cfrg-eddsa draft (note that malleability is irrelevant to
19 the standard definition of signature security). Signatures with a small-order
20 `R` point are now also rejected.
21  - Some implementations are now slightly faster when using the Clang
22 compiler.
23  - The HChaCha20 core function was implemented (`crypto_core_hchacha20()`).
24  - No-op stubs were added for all AES256-GCM public functions even when
25 compiled on non-Intel platforms.
26  - `crypt_generichash_blake2b_statebytes()` was added.
27  - New macros were added for the IETF variant of the ChaCha20-Poly1305
28 construction.
29  - The library can now be compiled on Minix.
30  - HEASLR is now enabled on MinGW builds.
32 * Version 1.0.8
33  - Handle the case where the CPU supports AVX, but we are running
34 on an hypervisor with AVX disabled/not supported.
35  - Faster (2x) scalarmult_base() when using the ref10 implementation.
37 * Version 1.0.7
38  - More functions whose return value should be checked have been
39 tagged with `__attribute__ ((warn_unused_result))`: `crypto_box_easy()`,
40 `crypto_box_detached()`, `crypto_box_beforenm()`, `crypto_box()`, and
41 `crypto_scalarmult()`.
42  - Sandy2x, the fastest Curve25519 implementation ever, has been
43 merged in, and is automatically used on CPUs supporting the AVX
44 instructions set.
45  - An SSE2 optimized implementation of Poly1305 was added, and is
46 twice as fast as the portable one.
47  - An SSSE3 optimized implementation of ChaCha20 was added, and is
48 twice as fast as the portable one.
49  - Faster `sodium_increment()` for common nonce sizes.
50  - New helper functions have been added: `sodium_is_zero()` and
51  `sodium_add()`.
52  - `sodium_runtime_has_aesni()` now properly detects the CPU flag when
53  compiled using Visual Studio.
55 * Version 1.0.6
56  - Optimized implementations of Blake2 have been added for modern
57 Intel platforms. `crypto_generichash()` is now faster than MD5 and SHA1
58 implementations while being far more secure.
59  - Functions for which the return value should be checked have been
60 tagged with `__attribute__ ((warn_unused_result))`. This will
61 intentionally break code compiled with `-Werror` that didn't bother
62 checking critical return values.
63  - The `crypto_sign_edwards25519sha512batch_*()` functions have been
64 tagged as deprecated.
65  - Undocumented symbols that were exported, but were only useful for
66 internal purposes have been removed or made private:
67 `sodium_runtime_get_cpu_features()`, the implementation-specific
68 `crypto_onetimeauth_poly1305_donna()` symbols,
69 `crypto_onetimeauth_poly1305_set_implementation()`,
70 `crypto_onetimeauth_poly1305_implementation_name()` and
71 `crypto_onetimeauth_pick_best_implementation()`.
72  - `sodium_compare()` now works as documented, and compares numbers
73 in little-endian format instead of behaving like `memcmp()`.
74  - The previous changes should not break actual applications, but to be
75 safe, the library version major was incremented.
76  - `sodium_runtime_has_ssse3()` and `sodium_runtime_has_sse41()` have
77 been added.
78  - The library can now be compiled with the CompCert compiler.
80 * Version 1.0.5
81  - Compilation issues on some platforms were fixed: missing alignment
82 directives were added (required at least on RHEL-6/i386), a workaround
83 for a VRP bug on gcc/armv7 was added, and the library can now be compiled
84 with the SunPro compiler.
85  - Javascript target: io.js is not supported any more. Use nodejs.
87 * Version 1.0.4
88  - Support for AES256-GCM has been added. This requires
89 a CPU with the aesni and pclmul extensions, and is accessible via the
90 crypto_aead_aes256gcm_*() functions.
91  - The Javascript target doesn't use eval() any more, so that the
92 library can be used in Chrome packaged applications.
93  - QNX and CloudABI are now supported.
94  - Support for NaCl has finally been added.
95  - ChaCha20 with an extended (96 bit) nonce and a 32-bit counter has
96 been implemented as crypto_stream_chacha20_ietf(),
97 crypto_stream_chacha20_ietf_xor() and crypto_stream_chacha20_ietf_xor_ic().
98 An IETF-compatible version of ChaCha20Poly1305 is available as
99 crypto_aead_chacha20poly1305_ietf_npubbytes(),
100 crypto_aead_chacha20poly1305_ietf_encrypt() and
101 crypto_aead_chacha20poly1305_ietf_decrypt().
102  - The sodium_increment() helper function has been added, to increment
103 an arbitrary large number (such as a nonce).
104  - The sodium_compare() helper function has been added, to compare
105 arbitrary large numbers (such as nonces, in order to prevent replay
106 attacks).
108 * Version 1.0.3
109  - In addition to sodium_bin2hex(), sodium_hex2bin() is now a
110 constant-time function.
111  - crypto_stream_xsalsa20_ic() has been added.
112  - crypto_generichash_statebytes(), crypto_auth_*_statebytes() and
113 crypto_hash_*_statebytes() have been added in order to retrieve the
114 size of structures keeping states from foreign languages.
115  - The JavaScript target doesn't require /dev/urandom or an external
116 randombytes() implementation any more. Other minor Emscripten-related
117 improvements have been made in order to support libsodium.js
118  - Custom randombytes implementations do not need to provide their own
119 implementation of randombytes_uniform() any more. randombytes_stir()
120 and randombytes_close() can also be NULL pointers if they are not
121 required.
122  - On Linux, getrandom(2) is being used instead of directly accessing
123 /dev/urandom, if the kernel supports this system call.
124  - crypto_box_seal() and crypto_box_seal_open() have been added.
125  - A solutions for Visual Studio 2015 was added.
127 * Version 1.0.2
128  - The _easy and _detached APIs now support precalculated keys;
129 crypto_box_easy_afternm(), crypto_box_open_easy_afternm(),
130 crypto_box_detached_afternm() and crypto_box_open_detached_afternm()
131 have been added as an alternative to the NaCl interface.
132  - Memory allocation functions can now be used on operating systems with
133 no memory protection.
134  - crypto_sign_open() and crypto_sign_edwards25519sha512batch_open()
135 now accept a NULL pointer instead of a pointer to the message size, if
136 storing this information is not required.
137  - The close-on-exec flag is now set on the descriptor returned when
138 opening /dev/urandom.
139  - A libsodium-uninstalled.pc file to use pkg-config even when
140 libsodium is not installed, has been added.
141  - The iOS target now includes armv7s and arm64 optimized code, as well
142 as i386 and x86_64 code for the iOS simulator.
143  - sodium_free() can now be called on regions with PROT_NONE protection.
144  - The Javascript tests can run on Ubuntu, where the node binary was
145 renamed nodejs. io.js can also be used instead of node.
147 * Version 1.0.1
148  - DLL_EXPORT was renamed SODIUM_DLL_EXPORT in order to avoid
149 collisions with similar macros defined by other libraries.
150  - sodium_bin2hex() is now constant-time.
151  - crypto_secretbox_detached() now supports overlapping input and output
152 regions.
153  - NaCl's donna_c64 implementation of curve25519 was reading an extra byte
154 past the end of the buffer containing the base point. This has been
155 fixed.
157 * Version 1.0.0
158  - The API and ABI are now stable. New features will be added, but
159 backward-compatibility is guaranteed through all the 1.x.y releases.
160  - crypto_sign() properly works with overlapping regions again. Thanks
161 to @pysiak for reporting this regression introduced in version 0.6.1.
162  - The test suite has been extended.
164 * Version 0.7.1 (1.0 RC2)
165  - This is the second release candidate of Sodium 1.0. Minor
166 compilation, readability and portability changes have been made and the
167 test suite was improved, but the API is the same as the previous release
168 candidate.
170 * Version 0.7.0 (1.0 RC1)
171  - Allocating memory to store sensitive data can now be done using
172 sodium_malloc() and sodium_allocarray(). These functions add guard
173 pages around the protected data to make it less likely to be
174 accessible in a heartbleed-like scenario. In addition, the protection
175 for memory regions allocated that way can be changed using
176 sodium_mprotect_noaccess(), sodium_mprotect_readonly() and
177 sodium_mprotect_readwrite().
178  - ed25519 keys can be converted to curve25519 keys with
179 crypto_sign_ed25519_pk_to_curve25519() and
180 crypto_sign_ed25519_sk_to_curve25519(). This allows using the same
181 keys for signature and encryption.
182  - The seed and the public key can be extracted from an ed25519 key
183 using crypto_sign_ed25519_sk_to_seed() and crypto_sign_ed25519_sk_to_pk().
184  - aes256 was removed. A timing-attack resistant implementation might
185 be added later, but not before version 1.0 is tagged.
186  - The crypto_pwhash_scryptxsalsa208sha256_* compatibility layer was
187 removed. Use crypto_pwhash_scryptsalsa208sha256_*.
188  - The compatibility layer for implementation-specific functions was
189 removed.
190  - Compilation issues with Mingw64 on MSYS (not MSYS2) were fixed.
191  - crypto_pwhash_scryptsalsa208sha256_STRPREFIX was added: it contains
192 the prefix produced by crypto_pwhash_scryptsalsa208sha256_str()
194 * Version 0.6.1
195  - Important bug fix: when crypto_sign_open() was given a signed
196 message too short to even contain a signature, it was putting an
197 unlimited amount of zeros into the target buffer instead of
198 immediately returning -1. The bug was introduced in version 0.5.0.
199  - New API: crypto_sign_detached() and crypto_sign_verify_detached()
200 to produce and verify ed25519 signatures without having to duplicate
201 the message.
202  - New ./configure switch: --enable-minimal, to create a smaller
203 library, with only the functions required for the high-level API.
204 Mainly useful for the JavaScript target and embedded systems.
205  - All the symbols are now exported by the Emscripten build script.
206  - The pkg-config .pc file is now always installed even if the
207 pkg-config tool is not available during the installation.
209 * Version 0.6.0
210  - The ChaCha20 stream cipher has been added, as crypto_stream_chacha20_*
211  - The ChaCha20Poly1305 AEAD construction has been implemented, as
212 crypto_aead_chacha20poly1305_*
213  - The _easy API does not require any heap allocations any more and
214 does not have any overhead over the NaCl API. With the password
215 hashing function being an obvious exception, the library doesn't
216 allocate and will not allocate heap memory ever.
217  - crypto_box and crypto_secretbox have a new _detached API to store
218 the authentication tag and the encrypted message separately.
219  - crypto_pwhash_scryptxsalsa208sha256*() functions have been renamed
220 crypto_pwhash_scryptsalsa208sha256*().
221  - The low-level crypto_pwhash_scryptsalsa208sha256_ll() function
222 allows setting individual parameters of the scrypt function.
223  - New macros and functions for recommended crypto_pwhash_* parameters
224 have been added.
225  - Similarly to crypto_sign_seed_keypair(), crypto_box_seed_keypair()
226 has been introduced to deterministically generate a key pair from a seed.
227  - crypto_onetimeauth() now provides a streaming interface.
228  - crypto_stream_chacha20_xor_ic() and crypto_stream_salsa20_xor_ic()
229 have been added to use a non-zero initial block counter.
230  - On Windows, CryptGenRandom() was replaced by RtlGenRandom(), which
231 doesn't require the Crypt API.
232  - The high bit in curve25519 is masked instead of processing the key as
233 a 256-bit value.
234  - The curve25519 ref implementation was replaced by the latest ref10
235 implementation from Supercop.
236  - sodium_mlock() now prevents memory from being included in coredumps
237 on Linux 3.4+
239 * Version 0.5.0
240  - sodium_mlock()/sodium_munlock() have been introduced to lock pages
241 in memory before storing sensitive data, and to zero them before
242 unlocking them.
243  - High-level wrappers for crypto_box and crypto_secretbox
244 (crypto_box_easy and crypto_secretbox_easy) can be used to avoid
245 dealing with the specific memory layout regular functions depend on.
246  - crypto_pwhash_scryptsalsa208sha256* functions have been added
247 to derive a key from a password, and for password storage.
248  - Salsa20 and ed25519 implementations now support overlapping
249 inputs/keys/outputs (changes imported from supercop-20140505).
250  - New build scripts for Visual Studio, Emscripten, different Android
251 architectures and msys2 are available.
252  - The poly1305-53 implementation has been replaced with Floodyberry's
253 poly1305-donna32 and poly1305-donna64 implementations.
254  - sodium_hex2bin() has been added to complement sodium_bin2hex().
255  - On OpenBSD and Bitrig, arc4random() is used instead of reading
256 /dev/urandom.
257  - crypto_auth_hmac_sha512() has been implemented.
258  - sha256 and sha512 now have a streaming interface.
259  - hmacsha256, hmacsha512 and hmacsha512256 now support keys of
260 arbitrary length, and have a streaming interface.
261  - crypto_verify_64() has been implemented.
262  - first-class Visual Studio build system, thanks to @evoskuil
263  - CPU features are now detected at runtime.
265 * Version 0.4.5
266  - Restore compatibility with OSX <= 10.6
268 * Version 0.4.4
269  - Visual Studio is officially supported (VC 2010 & VC 2013)
270  - mingw64 is now supported
271  - big-endian architectures are now supported as well
272  - The donna_c64 implementation of curve25519_donna_c64 now handles
273 non-canonical points like the ref implementation
274  - Missing scalarmult_curve25519 and stream_salsa20 constants are now exported
275  - A crypto_onetimeauth_poly1305_ref() wrapper has been added
277 * Version 0.4.3
278  - crypto_sign_seedbytes() and crypto_sign_SEEDBYTES were added.
279  - crypto_onetimeauth_poly1305_implementation_name() was added.
280  - poly1305-ref has been replaced by a faster implementation,
281 Floodyberry's poly1305-donna-unrolled.
282  - Stackmarkings have been added to assembly code, for Hardened Gentoo.
283  - pkg-config can now be used in order to retrieve compilations flags for
284 using libsodium.
285  - crypto_stream_aes256estream_*() can now deal with unaligned input
286 on platforms that require word alignment.
287  - portability improvements.
289 * Version 0.4.2
290  - All NaCl constants are now also exposed as functions.
291  - The Android and iOS cross-compilation script have been improved.
292  - libsodium can now be cross-compiled to Windows from Linux.
293  - libsodium can now be compiled with emscripten.
294  - New convenience function (prototyped in utils.h): sodium_bin2hex().
296 * Version 0.4.1
297  - sodium_version_*() functions were not exported in version 0.4. They
298 are now visible as intended.
299  - sodium_init() now calls randombytes_stir().
300  - optimized assembly version of salsa20 is now used on amd64.
301  - further cleanups and enhanced compatibility with non-C99 compilers.
303 * Version 0.4
304  - Most constants and operations are now available as actual functions
305 instead of macros, making it easier to use from other languages.
306  - New operation: crypto_generichash, featuring a variable key size, a
307 variable output size, and a streaming API. Currently implemented using
308 Blake2b.
309  - The package can be compiled in a separate directory.
310  - aes128ctr functions are exported.
311  - Optimized versions of curve25519 (curve25519_donna_c64), poly1305
312 (poly1305_53) and ed25519 (ed25519_ref10) are available. Optionally calling
313 sodium_init() once before using the library makes it pick the fastest
314 implementation.
315  - New convenience function: sodium_memzero() in order to securely
316 wipe a memory area.
317  - A whole bunch of cleanups and portability enhancements.
318  - On Windows, a .REF file is generated along with the shared library,
319 for use with Visual Studio. The installation path for these has become
320 $prefix/bin as expected by MingW.
322 * Version 0.3
323  - The crypto_shorthash operation has been added, implemented using
324 SipHash-2-4.
326 * Version 0.2
327  - crypto_sign_seed_keypair() has been added
329 * Version 0.1
330  - Initial release.