Christoph M. Becker
49ef8bc026
Add missing stub for SodiumException
...
Closes GH-6649.
2021-01-28 23:25:59 +01:00
Nikita Popov
8c68745f43
Update ext/sodium parameter names
...
Closes GH-6279.
2020-10-13 10:41:35 +02:00
Máté Kocsis
c37a1cd650
Promote a few remaining errors in ext/standard
...
Closes GH-6110
2020-09-15 14:26:16 +02:00
Máté Kocsis
9975986b7e
Improve error messages mentioning parameters instead of arguments
...
Closes GH-5999
2020-09-09 10:47:43 +02:00
Nikita Popov
124260c165
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Null terminate the sodium_crypto_kx_keypair() result
2020-08-14 15:52:31 +02:00
Nikita Popov
5885eecf23
Merge branch 'PHP-7.3' into PHP-7.4
...
* PHP-7.3:
Null terminate the sodium_crypto_kx_keypair() result
2020-08-14 15:52:15 +02:00
Nikita Popov
f6d7af21a3
Null terminate the sodium_crypto_kx_keypair() result
2020-08-14 15:51:31 +02:00
Nikita Popov
86072d60de
Reduce cost factors in sodium password_hash tests
...
Drop the 4x factors to make these tests a bit less obscenely
slow.
2020-08-14 15:39:42 +02:00
Máté Kocsis
7aacc705d0
Add many missing closing PHP tags to tests
...
Closes GH-5958
2020-08-09 22:03:36 +02:00
Nikita Popov
978b7de244
Accept zend_object* in zend_get_exception_base
2020-08-07 16:40:27 +02:00
Nikita Popov
7991fc2753
Accept zend_object in zend_read_property
2020-08-07 16:40:27 +02:00
Máté Kocsis
bdacd2ae8f
Add a few missing types to stubs
2020-08-01 23:55:08 +02:00
Nikita Popov
c9b9f525a9
Include stub hash in generated arginfo files
...
The hash is used to check whether the arginfo file needs to be
regenerated. PHP-Parser will only be downloaded if this is actually
necessary.
This ensures that release artifacts will never try to regenerate
stubs and thus fetch PHP-Parser, as long as you do not modify any
files.
Closes GH-5739.
2020-06-24 09:55:19 +02:00
George Peter Banyard
a2a6c7f227
Add -Wno-type-limits compiler flag to Sodium extension
...
This may happen on 32bits
2020-04-14 22:22:33 +02:00
Máté Kocsis
3709e74b5e
Store default parameter values of internal functions in arg info
...
Closes GH-5353. From now on, PHP will have reflection information
about default values of parameters of internal functions.
Co-authored-by: Nikita Popov <nikita.ppv@gmail.com>
2020-04-08 18:37:51 +02:00
Máté Kocsis
21cfa03f17
Generate function entries for another batch of extensions
...
Closes GH-5352
2020-04-05 21:15:30 +02:00
Máté Kocsis
a43bc33fb2
Annotate function aliases in stubs
2020-04-04 13:03:16 +02:00
Máté Kocsis
118b04bd6e
Improve argument error messages in ext/sodium
...
Closes GH-5197
2020-02-28 18:09:39 +01:00
Máté Kocsis
960318ed95
Change argument error message format
...
Closes GH-5211
2020-02-26 15:00:08 +01:00
Nikita Popov
7fc29c9924
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Enable ext/sodium in CI
Add skipif for argon2id in test
2020-02-24 12:41:49 +01:00
Nikita Popov
6c0a33f2dc
Add skipif for argon2id in test
...
If argon2i is provided by libargon, then argon2id may not be
available here.
2020-02-24 12:41:24 +01:00
Máté Kocsis
ac0853eb26
Make type error messages more consistent
...
Closes GH-5092
2020-02-17 14:22:17 +01:00
Nikita Popov
f8d795820e
Reindent phpt files
2020-02-03 22:52:20 +01:00
Máté Kocsis
01a50778d1
Use RETURN_THROWS() after zend_throw_exception() in most of the extensions
2020-01-02 10:56:18 +01:00
Máté Kocsis
817605917b
Use RETURN_THROWS() during ZPP in the remaining extensions
...
In reflection, sodium, and SPL
2019-12-31 16:33:02 +01:00
Máté Kocsis
37c1171451
Promote warnings to exceptions in password_*() functions
2019-12-12 12:14:53 +01:00
Máté Kocsis
27e83d0fb8
Add union return types for function stubs
2019-11-11 14:54:55 +01:00
Christoph M. Becker
4008704f62
zend_parse_parameters_throw() is obsolete
...
Since `zend_parse_parameters()` throws now, there is no reason to
explicitly call `zend_parse_parameters_throw()` anymore, and since both
have actually the same implementation, we redefine the latter as macro.
2019-11-01 16:47:15 +01:00
Christoph M. Becker
f7c61c070f
Add ext/sodium arginfo stubs
2019-10-21 10:19:57 +02:00
Christoph M. Becker
ed2c13ab07
Merge branch 'PHP-7.4'
...
* PHP-7.4:
Fix wrong function name in SKIPIF
2019-09-27 23:02:51 +02:00
Fabien Villepinte
8c7b8d75db
Fix wrong function name in SKIPIF
2019-09-27 23:01:48 +02:00
Gabriel Caruso
5d6e923d46
Remove mention of PHP major version in Copyright headers
...
Closes GH-4732.
2019-09-25 14:51:43 +02:00
Christoph M. Becker
145ffd93fc
Fix #78516 : password_hash(): Memory cost is not in allowed range
...
libsodium measures the memory cost in bytes, while password_hash() and
friends expect kibibyte values. We have to properly map between these
scales not only when calling libsodium functions, but also when
checking for allowed values.
We also refactor to rid the code duplication.
2019-09-16 14:58:39 +02:00
Christoph M. Becker
280e40fadd
Merge branch 'PHP-7.3' into PHP-7.4
...
* PHP-7.3:
Drop regression test
2019-09-10 10:08:42 +02:00
Christoph M. Becker
318b92dc12
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Drop regression test
2019-09-10 10:08:07 +02:00
Christoph M. Becker
bca66002f1
Drop regression test
...
The state returned by `sodium_crypto_generichash_init()` has to be
regarded as opaque byte string; neither its size nor its exact
structure are fixed, and actually vary for diffent libsodium versions.
Therefore we drop the test altogether.
2019-09-10 10:07:39 +02:00
Christoph M. Becker
167ea6307b
Merge branch 'PHP-7.3' into PHP-7.4
...
* PHP-7.3:
Fix #78510 : Partially uninitialized buffer returned by sodium_crypto_generichash_init()
2019-09-09 15:33:02 +02:00
Christoph M. Becker
af2033b1cd
Merge branch 'PHP-7.2' into PHP-7.3
...
* PHP-7.2:
Fix #78510 : Partially uninitialized buffer returned by sodium_crypto_generichash_init()
2019-09-09 15:31:15 +02:00
Christoph M. Becker
8ead77936e
Fix #78510 : Partially uninitialized buffer returned by sodium_crypto_generichash_init()
...
Backport jedisct1/libsodium.php@28d13bf437 .
2019-09-09 15:30:28 +02:00
Peter Kokot
1b969a74d0
Remove some unused HAVE_* symbols
...
- HAVE_NET_SNMP removed via cab643f615
- HAVE_CRYPTO_AEAD_AES256GCM ad120c5ae9
- Remove HAVE_FREETDS and HAVE_LIBDNET_STUB (not used in current
extension; copy paste from other removed extensions)
Closes GH-4448
2019-07-21 11:34:18 +02:00
Sara Golemon
f65956e4fb
Relax argon2 mem_cost down to 64k, bump time_cost to 4
2019-07-09 11:36:48 -04:00
Sara Golemon
0ba1db7a4a
Provide argon2i(d) password hashing from sodium when needed
2019-07-07 21:53:43 -04:00
Christoph M. Becker
b2b528b973
Merge branch 'PHP-7.3' into PHP-7.4
...
* PHP-7.3:
Fix #78114 : segfault when calling sodium_* functions from eval
2019-06-06 10:01:12 +02:00
Christoph M. Becker
22a3fa0b2e
Fix #78114 : segfault when calling sodium_* functions from eval
...
We must not follow the NULL pointer.
2019-06-06 10:00:15 +02:00
Remi Collet
9ef03a94ba
sodium: fix shared build
2019-05-21 16:14:52 +02:00
Peter Kokot
75fb74860d
Normalize comments in *nix build system m4 files
...
Normalization include:
- Use dnl for everything that can be ommitted when configure is built in
favor of the shell comment character # which is visible in the output.
- Line length normalized to 80 columns
- Dots for most of the one line sentences
- Macro definitions include similar pattern header comments now
2019-05-12 18:43:03 +02:00
Peter Kokot
99b94fbb5c
Remove redundant example/test libsodium.php file
2019-05-08 22:00:22 +02:00
Hugh McMaster
4bce02898d
Use PKG_CHECK_MODULES to detect the libsodium library
2019-04-29 14:16:16 +02:00
Hugh McMaster
c9ee822bb6
Always use pkg-config from the host architecture
2019-04-29 14:16:16 +02:00
Sara Golemon
7e7fa77a2e
Validate interoperability between libsodium and libargon for argon2i(d) hashing
2019-03-27 00:36:36 -04:00