asaskevich / govalidator

[Go] Package of validators and sanitizers for strings, numerics, slices and structs
MIT License
6.05k stars 555 forks source link

Do not put any limit on maximum URL length #478

Open ashishshinde-pubm opened 2 years ago

ashishshinde-pubm commented 2 years ago

Limitation : Current implementation of IsURL function simply returns false (URL as invalid) if length of URL is more than 2082 runes/characters. It does not check if the URL is valid based on regex and URL-parsing.

Approach Remove the if-check present on maximum length and allow the function to check if the URL is valid based on regex and URL-parsing.