34 Commits

Author SHA1 Message Date
Máté Kocsis
f781803449 Narrow bool return types to true when possible (#2458) 2023-05-07 22:32:58 +02:00
Tim Düsterhus
fc1e94a9c2 random: Improve the non-CSPRNG warning (#2009)
* Strengthen the wording in `&caution.cryptographically-insecure;`

It’s not: “should not”, it’s “must not”.

* random: Unify use of `&caution.cryptographically-insecure;`

- The warning goes last.
- It is actually applied to all functions.

* random: Completely rewrite the `&caution.cryptographically-insecure;` warning

* random: Revert indentation changes to lcg-value.xml
2022-11-17 11:53:00 +01:00
Tim Düsterhus
52c495140b random: Clean up cross-references for randomness related functions (#2008)
* random: Reference the corresponding Randomizer methods in random_(bytes|int)

* random: Cross-reference the Randomizer in `str_shuffle()`

* random: Cross-reference the Randomizer in `shuffle()`

* random: Cross-reference the Randomizer in `array_rand()`

* random: Cross-reference `random_bytes()` in `uniqid()`

* random: Do not cross-reference `uniqid()` in `openssl_random_pseudo_bytes()`

uniqid() really is no good alternative to *anything*. In the vast majority of
cases it is better replaced by `bin2hex(random_bytes(…))`.

* random: Replace the `mt_rand()` cross-reference in `openssl_random_pseudo_bytes()` with `random_int()`

random_int() is a CSPRNG like openssl_random_pseudo_bytes(), mt_rand() is not.
2022-11-15 11:19:28 +01:00
Salomon88
6a6f43d1c4 Documentation of index reset effect of some array functions - issue #876 (#1077)
Co-authored-by: Alexey Kryuchkov <alexey.kryuchkov@jetbrains.com>

Closes GH-1077.
2021-11-09 13:01:19 +01:00
Christoph Michael Becker
802fb7ce9f Fix #76516: shuffle() has a note about undefined sorted order
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@345180 c90b9560-bf6c-de11-be94-00142212c4b1
2018-06-22 10:18:33 +00:00
Christoph Michael Becker
b45d8c1772 Nested <link>s can't work
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@344693 c90b9560-bf6c-de11-be94-00142212c4b1
2018-04-17 16:10:01 +00:00
Maciek Sokolewicz
ce3996c403 documented the change in behaviour due to aliasing of rand to mt_rand in PHP 7.1.0
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@341933 c90b9560-bf6c-de11-be94-00142212c4b1
2017-02-20 22:01:10 +00:00
Christoph Michael Becker
32952c4ddc Fix #51229: consecutives sorting with usort and uasort
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@339490 c90b9560-bf6c-de11-be94-00142212c4b1
2016-06-25 14:42:12 +00:00
Christoph Michael Becker
fb0122dd8b Fix #64386: No warning on insecure pseudo-random generators
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@339348 c90b9560-bf6c-de11-be94-00142212c4b1
2016-06-14 14:52:22 +00:00
Maciej Sobaczewski
8b5940cade Remove changelogs for PHP 4 - 2nd round
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@334605 c90b9560-bf6c-de11-be94-00142212c4b1
2014-08-26 14:28:17 +00:00
Jakub Vrana
e55c6e7b5b See also array_rand()
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@329772 c90b9560-bf6c-de11-be94-00142212c4b1
2013-03-13 17:11:41 +00:00
Daniel Egeberg
96c9d88bad Converted to utf-8
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@297028 c90b9560-bf6c-de11-be94-00142212c4b1
2010-03-28 22:10:10 +00:00
Torben Wilson
af4410a7e1 Normalized the sgml-default-dtd-file local-variable line for those
still using this, after discussion on the phpdoc list.
From now on, manual.ced will need to be found at ~/.phpdoc/manual.ced.



git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@288721 c90b9560-bf6c-de11-be94-00142212c4b1
2009-09-25 07:04:39 +00:00
Nilgün Belma Bugüner
876c81c602 fixed properties
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@283800 c90b9560-bf6c-de11-be94-00142212c4b1
2009-07-11 06:30:45 +00:00
Hannes Magnusson
49747f6e5f Like the changelogs says, the random number generator is seeded
automatically


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@283558 c90b9560-bf6c-de11-be94-00142212c4b1
2009-07-06 07:24:11 +00:00
Etienne Kneuss
28a4ad2460 Document #48224 and put randomseed in the changelog
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@280285 c90b9560-bf6c-de11-be94-00142212c4b1
2009-05-10 17:55:00 +00:00
Philip Olson
768052f230 Cleaned up SeeAlso for the array sorting functions,
and linked them to the new array sorting chapter


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@277530 c90b9560-bf6c-de11-be94-00142212c4b1
2009-03-20 20:40:34 +00:00
Mehdi Achour
7d46847705 Switch to new doc style
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@249383 c90b9560-bf6c-de11-be94-00142212c4b1
2007-12-29 23:04:24 +00:00
Hannes Magnusson
c030e2adf7 Upgrade to DocBook5:
- All id attributes are now xml:id
 - Add docbook namespace to all root elements
 - Replace <ulink /> with <link xlink:href />
 - Minor markup fixes here and there


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@238160 c90b9560-bf6c-de11-be94-00142212c4b1
2007-06-20 22:25:43 +00:00
Hannes Magnusson
c3bc936236 WS, preparation for the new doc style...
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@222577 c90b9560-bf6c-de11-be94-00142212c4b1
2006-10-31 11:24:02 +00:00
Dan Scott
a2abd495c5 Fix bug 34228 (rsort should link to krsort).
Fix bug 34229 (shuffle and other sort functions clobber key associations).


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@194314 c90b9560-bf6c-de11-be94-00142212c4b1
2005-08-24 14:15:11 +00:00
Jakub Vrana
5ace950dc8 Use foreach
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@189684 c90b9560-bf6c-de11-be94-00142212c4b1
2005-07-01 13:07:50 +00:00
Jakub Vrana
c148211fa2 Replace <parameter>&amp; by <parameter role="reference">
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@172416 c90b9560-bf6c-de11-be94-00142212c4b1
2004-11-10 08:30:50 +00:00
Jakub Vrana
c8196b0236 Parameters passed by reference
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@165051 c90b9560-bf6c-de11-be94-00142212c4b1
2004-08-03 10:24:06 +00:00
Sara Golemon
461a5144ed Proto fix
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@158344 c90b9560-bf6c-de11-be94-00142212c4b1
2004-05-11 05:35:15 +00:00
Mehdi Achour
b5be781648 end : rewording and CS
shuffle : there's a &note.random.seed; entity, so we don't need to use srand()


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@152961 c90b9560-bf6c-de11-be94-00142212c4b1
2004-03-05 12:12:57 +00:00
Mehdi Achour
e8844eadb3 some more CS
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@146748 c90b9560-bf6c-de11-be94-00142212c4b1
2003-12-18 17:46:56 +00:00
Heilig (Cece) Szabolcs
23396d4d4e applying PEAR coding standards on examples
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@138081 c90b9560-bf6c-de11-be94-00142212c4b1
2003-08-17 12:21:03 +00:00
Philip Olson
9fd7018715 Implement &note.randomseed; which states that random number generation is
automatic as of PHP 4.2.0


git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@129466 c90b9560-bf6c-de11-be94-00142212c4b1
2003-05-30 19:48:38 +00:00
Philip Olson
736a15f139 Added php tags (<?php ?>) to examples.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@129443 c90b9560-bf6c-de11-be94-00142212c4b1
2003-05-30 18:12:53 +00:00
Adrian Jurjica
2f7966f92e no message
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@81901 c90b9560-bf6c-de11-be94-00142212c4b1
2002-05-12 08:19:28 +00:00
Adrian Jurjica
de71bf7038 Translation of array functions.
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@81898 c90b9560-bf6c-de11-be94-00142212c4b1
2002-05-12 08:10:34 +00:00
Hartmut Holzgraefe
5b9fc29465 revision tags added
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@78496 c90b9560-bf6c-de11-be94-00142212c4b1
2002-04-17 06:45:35 +00:00
Hartmut Holzgraefe
a4b6d72ad3 banana-split
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@78202 c90b9560-bf6c-de11-be94-00142212c4b1
2002-04-15 00:12:54 +00:00