commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jamshid Afshar <>
Subject [validator] Should "http://fooserver.local" really be considered invalid?
Date Sat, 09 Nov 2013 20:10:44 GMT
Hi, is "http://fooserver.local" intentionally considered an "invalid"
url? It fails even if I use UrlValidator.ALLOW_LOCAL_URLS.

    private static final String[] ALLOWED_SCHEMES ={"http","https"};

    public static final UrlValidator URL_VALIDATOR = new

    if (!URL_VALIDATOR.isValid("http://fooserver.local")) { error... }

Maybe "local" should be added to:

private static final String[] LOCAL_TLDS = new String[] {
   "localhost",           // RFC2606 defined
   "localdomain"          // Also widely used as localhost.localdomain

I know, ".local" has a checkered past:, but it is widely used in server
names and testing.

Or maybe there is an easy option to consider any TLD valid. Anyway, so
many are being added.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message