From f2a2b34e4639e88f8d948a388a51f010212b42a3 Mon Sep 17 00:00:00 2001 From: Fabrizio Steiner Date: Sun, 7 May 2017 23:10:02 +0200 Subject: Increase device password entropy. Use lower- and upper-case characters and digits, but exclude ambiguous characters. The number of digits has also been increased to 25. Signed-off-by: Fabrizio Steiner --- lib/public/Security/ISecureRandom.php | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'lib/public') diff --git a/lib/public/Security/ISecureRandom.php b/lib/public/Security/ISecureRandom.php index c60529ef803..14190639f44 100644 --- a/lib/public/Security/ISecureRandom.php +++ b/lib/public/Security/ISecureRandom.php @@ -44,6 +44,13 @@ interface ISecureRandom { const CHAR_DIGITS = '0123456789'; const CHAR_SYMBOLS = '!\"#$%&\\\'()* +,-./:;<=>?@[\]^_`{|}~'; + /** + * Characters that can be used for generate($length, $characters), to + * generate human readable random strings. Lower- and upper-case characters and digits + * are included. Characters which are ambiguous are excluded, such as I, l, and 1 and so on. + */ + const CHAR_HUMAN_READABLE = "abcdefgijkmnopqrstwxyzABCDEFGHJKLMNPQRSTWXYZ23456789"; + /** * Convenience method to get a low strength random number generator. * -- cgit v1.2.3