String[] users = new String[] { "me", "l usr\\example.com",
"lusr\\example" };
String[] passes = new String[] { "wtf", };
- String[] hosts = new String[] { "example.com", "1.2.3.4" };
+ String[] hosts = new String[] { "example.com", "1.2.3.4", "[::1]" };
String[] ports = new String[] { "1234", "80" };
String[] paths = new String[] { "/", "/abc", "D:/x", "D:\\x" };
for (String[] test : tests) {
* Part of a pattern which matches the host part of URIs. Defines one
* capturing group containing the host name.
*/
- private static final String HOST_P = "([^\\\\/:]+)"; //$NON-NLS-1$
+ private static final String HOST_P = "((?:[^\\\\/:]+)|(?:\\[[0-9a-f:]+\\]))";
/**
* Part of a pattern which matches the optional port part of URIs. Defines