Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-40330

WordsUtil#getRandomWord may throw an ArrayIndexOutOfBoundsException

    Details

      Description

      In WordsUtil._getRandomWord(), there is the line

      SecureRandomUtil.nextInt() % _dictionaryList.size();

      nextInt() may return a negative number which may cause the next line

      dictionaryList.get(pos)

      to throw an ArrayIndexOutOfBoundsException

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              shuyang.zhou Shuyang Zhou
              Reporter:
              samuel.kong Samuel Kong
              Participants of an Issue:
              Recent user:
              Esther Sanz
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Days since last comment:
                7 years, 10 weeks, 6 days ago

                  Packages

                  Version Package
                  6.2.0 CE RC1