Details
Description
AssetEncoder.decode() has this line:
int slashx = pathInfo.indexOf('/', 1);
but never checks for slashx == -1 before using it in:
encoding.setParameterValue(AssetService.DIGEST, pathInfo.substring(1, slashx));
which, if the URL didn't have another slash after "assets/", causes a StringIndexOutOfBoundsException at runtime. Some automated security testing tools flag the resulting stack trace in the response as a potential risk, and it just looks bad, even though the URL was not one generated by AssetEncoder, but one obviously manipulated manually somehow.