Found issue where : is accepted as a valid header, this is obviously wrong

This commit is contained in:
Joe Bowser
2015-09-08 11:19:34 -07:00
parent 2b31723708
commit 8fcdb1aa3d
+1
View File
@@ -206,6 +206,7 @@ public class FileTransfer extends CordovaPlugin {
String headerKey = iter.next().toString();
headerKey = headerKey.replaceAll("\\n","")
.replaceAll("\\s+","")
.replaceAll(":", "")
.replaceAll("[^\\x20-\\x7E]+", "");
JSONArray headerValues = headers.optJSONArray(headerKey);