#104 regexp for url validator is incorrect

closed
nobody
None
5
2011-09-24
2010-06-20
Anonymous
No

Hi,

the following url is considered invalid by formencode validator :

http://c.wrzuta.pl/wi16677/5050f81b001f9e5f45902c1b/0/kaczynski%20i%20komputer

its this part actually http://c.wrzuta.pl - the subdomain part is one letter and that doesnt get matched by regex.

I changed the subdomain part of regex to :

(?P<domain>[a-z0-9][a-z0-9\-]{0,62}\.)* # (sub)domain - alpha followed by 62max chars (63 total)

to get it to work. it was {1,62} before, afaik.

Discussion

  • Chris Lambacher

    Chris Lambacher - 2011-09-24
    • status: open --> closed
     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks