diff options
author | James Edwards-Jones <jedwardsjones@gitlab.com> | 2018-12-05 20:14:09 +0000 |
---|---|---|
committer | James Edwards-Jones <jedwardsjones@gitlab.com> | 2018-12-06 15:18:18 +0000 |
commit | 72c00594070dfd1a778c2e03ff400b478e6c3774 (patch) | |
tree | d8fd26536ef6c5e4a2e3ef02ea7785537d34d93b /app/validators | |
parent | 8cd5004b350ef342f66956c11272dad1328f6526 (diff) | |
download | gitlab-ce-72c00594070dfd1a778c2e03ff400b478e6c3774.tar.gz |
Allow URLs to be validated as ascii_only
Restricts unicode characters and IDNA deviations
which could be used in a phishing attack
Diffstat (limited to 'app/validators')
-rw-r--r-- | app/validators/url_validator.rb | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/app/validators/url_validator.rb b/app/validators/url_validator.rb index 216acf79cbd..5feb0b0f05b 100644 --- a/app/validators/url_validator.rb +++ b/app/validators/url_validator.rb @@ -69,6 +69,7 @@ class UrlValidator < ActiveModel::EachValidator ports: [], allow_localhost: true, allow_local_network: true, + ascii_only: false, enforce_user: false } end |