Details
-
Bug
-
Resolution: Duplicate
-
Medium
-
None
-
2.9
Description
Not sure how long this goes back, but I found this bug while searching for a username in global search. Queries are parsed through the LabelParser to find matching labels.
Offending code:
else if(labelString.startsWith(USER_LABEL_PREFIX)) { int index = labelString.indexOf(NAMESPACE_DELIMITER); userName = labelString.substring(1, index); labelName = labelString.substring(index + 1); prefix = PERSONAL_LABEL_PREFIX; }
throws StringIndexOutOfBoundsException: String index out of range: -2 when there is no namespace delimiter (":")
Attachments
Issue Links
- duplicates
-
CONFSERVER-13628 LabelParser doesn't handle empty label text, or empty username for personal labels
- Closed