summaryrefslogtreecommitdiffstats
path: root/Bugzilla/Template.pm
diff options
context:
space:
mode:
authorSebastin Santy <sebastinssanty@gmail.com>2017-04-21 20:08:47 +0200
committerDylan William Hardison <dylan@hardison.net>2017-04-26 19:20:34 +0200
commiteffcc512d52b6bfca05db4df18087bbc2ca8057e (patch)
tree3446afd8eb7d2bec15e4156b69818d87f7547138 /Bugzilla/Template.pm
parent27b3fe459717a4815b51e51616b7a17a0625fc4d (diff)
downloadbugzilla-effcc512d52b6bfca05db4df18087bbc2ca8057e.tar.gz
bugzilla-effcc512d52b6bfca05db4df18087bbc2ca8057e.tar.xz
Bug 1355100 - Add rel=nofollow to all external links in bug comments
Refer https://support.google.com/webmasters/answer/96569\?hl\=en
Diffstat (limited to 'Bugzilla/Template.pm')
-rw-r--r--Bugzilla/Template.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/Bugzilla/Template.pm b/Bugzilla/Template.pm
index 9cac9ad87..65396b96d 100644
--- a/Bugzilla/Template.pm
+++ b/Bugzilla/Template.pm
@@ -200,7 +200,7 @@ sub quoteUrls {
my $safe_protocols = SAFE_URL_REGEXP();
$text =~ s~\b($safe_protocols)
~($tmp = html_quote($1)) &&
- ($things[$count++] = "<a href=\"$tmp\">$tmp</a>") &&
+ ($things[$count++] = "<a rel=\"nofollow\" href=\"$tmp\">$tmp</a>") &&
("\x{FDD2}" . ($count-1) . "\x{FDD3}")
~egox;