fapi_validation_rule_url falsely accepts unencoded unicode characters for absolute URLs

Created on 9 November 2015, about 9 years ago
Updated 26 November 2024, 27 days ago

Function fapi_validation_rule_url is faulty. It accepts absolute URLs which contain unencoded unicode characters. This differs from Drupals common.inc: valid_url() which handles them correctly (per RFC 3986).

To repeat the problem, validate absolute URL string such as:
http://drupal.org/รถ
fapi_validation_rule_url() returns true
valid_url() returns false, which is correct.

fapi_validation_rule_url() was changed in commit http://cgit.drupalcode.org/fapi_validation/commit/?id=b26a6cd
to use it's own regex instead of calling Drupal's valid_url() for absolute URLs.

๐Ÿ› Bug report
Status

Closed: outdated

Version

2.2

Component

Code

Created by

๐Ÿ‡ซ๐Ÿ‡ฎFinland okaalto

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • ๐Ÿ‡บ๐Ÿ‡ฆUkraine AstonVictor

    I'm closing it because the issue was created a long time ago without any further steps.

    if you still need it then raise a new one.
    thanks

Production build 0.71.5 2024