Sebb created LANG-808:
-------------------------
Summary: RandomStringUtils inefficient init of start and end for
letters and numbers
Key: LANG-808
URL: https://issues.apache.org/jira/browse/LANG-808
Project: Commons Lang
Issue Type: Bug
Reporter: Sebb
If either letters or numbers is true, RandomStringUtils(count, 0, 0, letters,
numbers, ...) sets the default start index to space, intending to support the
set of printable characters (according to the Javadoc).
However, the code later uses Character.isLetter and Character.isDigit, which
exclude space and some other printable characters.
There is currently no direct support for generating printable characters.
The current Javadoc is misleading, and the current code is inefficient because
some characters cannot currently be used.
The lowest char which is either digit or letter is '0' (zero).
The lowest char which is a letter is 'A' (upper case a).
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira