Skip to content

Commit 8e89ec2

Browse files
authored
Add rel="noreferrer" to external hyperlinks (#3495)
2 parents 878d6fa + f3fd182 commit 8e89ec2

File tree

9 files changed

+26
-26
lines changed

9 files changed

+26
-26
lines changed

groups-domains.lp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ mg.include('scripts/lua/header_authenticated.lp','r')
7575
</div>
7676
<div class="form-group">
7777
<strong>Hint:</strong> Need help to write a proper RegEx rule? Have a look at our online
78-
<a href="https://docs.pi-hole.net/ftldns/regex/tutorial" rel="noopener" target="_blank">
78+
<a href="https://docs.pi-hole.net/ftldns/regex/tutorial" rel="noopener noreferrer" target="_blank">
7979
regular expressions tutorial</a>.
8080
</div>
8181
</div>

login.lp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ mg.include('scripts/lua/header.lp','r')
7272
</div>
7373
<div class="box-body">
7474
<p>Your Pi-hole has two-factor authentication enabled. You have to
75-
enter a valid <a href="https://en.wikipedia.org/wiki/Time-based_One-time_Password_algorithm" rel="noopener" target="_blank">TOTP</a>
75+
enter a valid <a href="https://en.wikipedia.org/wiki/Time-based_One-time_Password_algorithm" rel="noopener noreferrer" target="_blank">TOTP</a>
7676
token in addition to your password. You see this message because your
7777
token was incorrect or has already expired.</p>
7878
</div>
@@ -104,17 +104,17 @@ mg.include('scripts/lua/header.lp','r')
104104
</div>
105105
<!-- /.login-card-body -->
106106
<div class="login-footer" style="margin-top: 15px; display: flex; justify-content: space-between;">
107-
<a class="btn btn-default btn-sm" role="button" href="https://docs.pi-hole.net/" rel="noopener" target="_blank"><i class="fas fa-question-circle"></i> Documentation</a>
108-
<a class="btn btn-default btn-sm" role="button" href="https://github.com/pi-hole/" rel="noopener" target="_blank"><i class="fab fa-github"></i> GitHub</a>
109-
<a class="btn btn-default btn-sm" role="button" href="https://discourse.pi-hole.net/" rel="noopener" target="_blank"><i class="fab fa-discourse"></i> Pi-hole Discourse</a>
107+
<a class="btn btn-default btn-sm" role="button" href="https://docs.pi-hole.net/" rel="noopener noreferrer" target="_blank"><i class="fas fa-question-circle"></i> Documentation</a>
108+
<a class="btn btn-default btn-sm" role="button" href="https://github.com/pi-hole/" rel="noopener noreferrer" target="_blank"><i class="fab fa-github"></i> GitHub</a>
109+
<a class="btn btn-default btn-sm" role="button" href="https://discourse.pi-hole.net/" rel="noopener noreferrer" target="_blank"><i class="fab fa-discourse"></i> Pi-hole Discourse</a>
110110
</div>
111111
</div>
112112
</section>
113113
</div>
114114

115115
<div class="login-donate">
116116
<div class="text-center" style="font-size:125%">
117-
<strong><a href="https://pi-hole.net/donate/" rel="noopener" target="_blank"><i class="fa fa-heart text-red"></i> Donate</a></strong> if you found this useful.
117+
<strong><a href="https://pi-hole.net/donate/" rel="noopener noreferrer" target="_blank"><i class="fa fa-heart text-red"></i> Donate</a></strong> if you found this useful.
118118
</div>
119119
</div>
120120
<script src="<?=pihole.fileversion('scripts/js/footer.js')?>"></script>

scripts/js/footer.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -517,7 +517,7 @@ function updateVersionInfo() {
517517
v.url +
518518
"/" +
519519
localVersion +
520-
'" rel="noopener" target="_blank">' +
520+
'" rel="noopener noreferrer" target="_blank">' +
521521
localVersion +
522522
"</a>";
523523
if (versionCompare(v.local, v.remote) === -1) {
@@ -548,7 +548,7 @@ function updateVersionInfo() {
548548
v.url +
549549
"/" +
550550
localVersion +
551-
'" rel="noopener" target="_blank">' +
551+
'" rel="noopener noreferrer" target="_blank">' +
552552
localVersion +
553553
"</a>";
554554
}
@@ -563,7 +563,7 @@ function updateVersionInfo() {
563563
localVersion +
564564
'&nbsp&middot; <a class="lookatme" lookatme-text="Update available!" href="' +
565565
v.url +
566-
'" rel="noopener" target="_blank">Update available!</a></li>'
566+
'" rel="noopener noreferrer" target="_blank">Update available!</a></li>'
567567
);
568568
// if at least one component can be updated, display the update-hint footer
569569
updateAvailable = true;
@@ -575,11 +575,11 @@ function updateVersionInfo() {
575575

576576
if (dockerUpdate)
577577
$("#update-hint").html(
578-
'To install updates, <a href="https://github.com/pi-hole/docker-pi-hole#upgrading-persistence-and-customizations" rel="noopener" target="_blank">replace this old container with a fresh upgraded image</a>.'
578+
'To install updates, <a href="https://github.com/pi-hole/docker-pi-hole#upgrading-persistence-and-customizations" rel="noopener noreferrer" target="_blank">replace this old container with a fresh upgraded image</a>.'
579579
);
580580
else if (updateAvailable)
581581
$("#update-hint").html(
582-
'To install updates, run <code><a href="https://docs.pi-hole.net/main/update/" rel="noopener" target="_blank">pihole -up</a></code>.'
582+
'To install updates, run <code><a href="https://docs.pi-hole.net/main/update/" rel="noopener noreferrer" target="_blank">pihole -up</a></code>.'
583583
);
584584

585585
clearTimeout(versionTimer);

scripts/lua/footer.lp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ end
5252
<footer class="main-footer">
5353
<div class="row row-centered text-center">
5454
<div class="col-xs-12 col-sm-6">
55-
<strong><a href="https://pi-hole.net/donate/" rel="noopener" target="_blank"><i class="fa fa-heart text-red"></i> Donate</a></strong> if you found this useful.
55+
<strong><a href="https://pi-hole.net/donate/" rel="noopener noreferrer" target="_blank"><i class="fa fa-heart text-red"></i> Donate</a></strong> if you found this useful.
5656
</div>
5757
</div>
5858

scripts/lua/header_authenticated.lp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ mg.include('header.lp','r')
2828
<div>
2929
<input type="checkbox" id="js-hide">
3030
<div class="js-warn" id="js-warn-exit"><h1>JavaScript Is Disabled</h1><p>JavaScript is required for the site to function.</p>
31-
<p>To learn how to enable JavaScript click <a href="https://www.enable-javascript.com/" rel="noopener" target="_blank">here</a></p><label for="js-hide">Close</label>
31+
<p>To learn how to enable JavaScript click <a href="https://www.enable-javascript.com/" rel="noopener noreferrer" target="_blank">here</a></p><label for="js-hide">Close</label>
3232
</div>
3333
</div>
3434
<!-- /JS Warning -->
@@ -76,14 +76,14 @@ mg.include('header.lp','r')
7676
<li class="user-body" id="advanced-info" style="display:none;"></li>
7777
<!-- Menu Footer -->
7878
<li class="user-footer">
79-
<a class="btn-link" href="https://pi-hole.net/" rel="noopener" target="_blank">
79+
<a class="btn-link" href="https://pi-hole.net/" rel="noopener noreferrer" target="_blank">
8080
<? mg.include('../../img/logo-bw.svg', 'r') ?>
8181
Pi-hole Website
8282
</a>
83-
<a class="btn-link" href="https://docs.pi-hole.net/" rel="noopener" target="_blank"><i class="fa-fw menu-icon fa-solid fa-circle-question"></i> Documentation</a>
84-
<a class="btn-link" href="https://discourse.pi-hole.net/" rel="noopener" target="_blank"><i class="fa-fw menu-icon fab fa-discourse"></i> Pi-hole Discourse</a>
85-
<a class="btn-link" href="https://github.com/pi-hole" rel="noopener" target="_blank"><i class="fa-fw menu-icon fab fa-github"></i> GitHub</a>
86-
<a class="btn-link" href="https://discourse.pi-hole.net/c/announcements/5" rel="noopener" target="_blank"><i class="fa-fw menu-icon fa-solid fa-rocket"></i> Pi-hole Releases</a>
83+
<a class="btn-link" href="https://docs.pi-hole.net/" rel="noopener noreferrer" target="_blank"><i class="fa-fw menu-icon fa-solid fa-circle-question"></i> Documentation</a>
84+
<a class="btn-link" href="https://discourse.pi-hole.net/" rel="noopener noreferrer" target="_blank"><i class="fa-fw menu-icon fab fa-discourse"></i> Pi-hole Discourse</a>
85+
<a class="btn-link" href="https://github.com/pi-hole" rel="noopener noreferrer" target="_blank"><i class="fa-fw menu-icon fab fa-github"></i> GitHub</a>
86+
<a class="btn-link" href="https://discourse.pi-hole.net/c/announcements/5" rel="noopener noreferrer" target="_blank"><i class="fa-fw menu-icon fa-solid fa-rocket"></i> Pi-hole Releases</a>
8787
<? if pihole.needLogin() then ?>
8888
<a class="btn-link" href="#" id="logout-button"><i class="fa-fw menu-icon fa-solid fa-arrow-right-from-bracket"></i> Log out</a>
8989
<? end ?>

scripts/lua/sidebar.lp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@
258258
<!-- Donate button -->
259259
<li class="header text-uppercase">Donate</li>
260260
<li class="menu-donate">
261-
<a href="https://pi-hole.net/donate/" rel="noopener" target="_blank">
261+
<a href="https://pi-hole.net/donate/" rel="noopener noreferrer" target="_blank">
262262
<i class="fas fa-fw menu-icon fa-donate"></i> <span>Donate</span>
263263
</a>
264264
</li>

settings-api.lp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ mg.include('scripts/lua/settings_header.lp','r')
102102
</div>
103103
<div class="row">
104104
<div class="col-md-12">
105-
<p><strong>Important</strong>:<br>Those input fields accept regex entries only.<br>Please refer to <a href="https://docs.pi-hole.net/regex/tutorial/" rel="noopener" target="_blank">our guide</a> how to construct valid regex entries.</p>
105+
<p><strong>Important</strong>:<br>Those input fields accept regex entries only.<br>Please refer to <a href="https://docs.pi-hole.net/regex/tutorial/" rel="noopener noreferrer" target="_blank">our guide</a> how to construct valid regex entries.</p>
106106
</div>
107107
</div>
108108
</div>

settings-dns.lp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ mg.include('scripts/lua/settings_header.lp','r')
9999
rate-limited clients are short-circuited at the same time.</p>
100100
<p>Rate-limiting may be disabled altogether by setting both
101101
values to zero. See
102-
<a href="https://docs.pi-hole.net/ftldns/configfile/#rate_limit" rel="noopener" target="_blank">our documentation</a>
102+
<a href="https://docs.pi-hole.net/ftldns/configfile/#rate_limit" rel="noopener noreferrer" target="_blank">our documentation</a>
103103
for further details.</p>
104104
</div>
105105
</div>
@@ -144,7 +144,7 @@ mg.include('scripts/lua/settings_header.lp','r')
144144
in your router!) they are safe to use.</p>
145145
</div>
146146
</div>
147-
<p>See <a href="https://docs.pi-hole.net/ftldns/interfaces/" rel="noopener" target="_blank">our documentation</a> for further technical details.</p>
147+
<p>See <a href="https://docs.pi-hole.net/ftldns/interfaces/" rel="noopener noreferrer" target="_blank">our documentation</a> for further technical details.</p>
148148
</div>
149149
</div>
150150
</div>
@@ -173,7 +173,7 @@ mg.include('scripts/lua/settings_header.lp','r')
173173
<p class="help-block">All reverse lookups for private IP ranges (i.e., <code>192.168.0.x/24</code>, etc.)
174174
which are not found in <code>/etc/hosts</code> or the DHCP leases are answered
175175
with "no such domain" rather than being forwarded upstream. The set
176-
of prefixes affected is the list given in <a href="https://tools.ietf.org/html/rfc6303">RFC6303</a>.</p>
176+
of prefixes affected is the list given in <a href="https://tools.ietf.org/html/rfc6303" rel="noopener noreferrer" target="_blank">RFC6303</a>.</p>
177177
<p><strong>Important:</strong><br>Enabling these two options may increase your privacy,
178178
but may also prevent you from being able to access local hostnames if the Pi-hole is not used as DHCP server.
179179
Make sure you have set up conditional forwarding in this case.</p>
@@ -189,7 +189,7 @@ mg.include('scripts/lua/settings_header.lp','r')
189189
Use an upstream DNS server which supports DNSSEC when activating DNSSEC. Note that
190190
the size of your log might increase significantly
191191
when enabling DNSSEC. A DNSSEC resolver test can be found
192-
<a href="https://dnssec.vs.uni-due.de/" rel="noopener" target="_blank">here</a>.</p>
192+
<a href="https://dnssec.vs.uni-due.de/" rel="noopener noreferrer" target="_blank">here</a>.</p>
193193
</div>
194194
</div>
195195
</div>
@@ -219,7 +219,7 @@ mg.include('scripts/lua/settings_header.lp','r')
219219
whereas an even wider network of 10.0.0.1 - 10.255.255.255 results in <code>10.0.0.0/8</code>.
220220
Setting up IPv6 ranges is exactly similar to setting up IPv4 here and fully supported.
221221
Feel free to reach out to us on our
222-
<a href="https://discourse.pi-hole.net" rel="noopener" target="_blank">Discourse forum</a>
222+
<a href="https://discourse.pi-hole.net" rel="noopener noreferrer" target="_blank">Discourse forum</a>
223223
in case you need any assistance setting up local host name resolution for your particular system.</p>
224224
<p>You can also specify a local domain name (like <code>fritz.box</code>) to ensure queries to
225225
devices ending in your local domain name will not leave your network, however, this is optional.

settings-system.lp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ mg.include('scripts/lua/settings_header.lp','r')
191191
</table> -->
192192
</div>
193193
<div class="col-lg-12">
194-
See also our <a href="https://docs.pi-hole.net/ftldns/dns-cache/" rel="noopener" target="_blank">DNS cache documentation</a>.<br>&nbsp;
194+
See also our <a href="https://docs.pi-hole.net/ftldns/dns-cache/" rel="noopener noreferrer" target="_blank">DNS cache documentation</a>.<br>&nbsp;
195195
</div>
196196
<div class="col-lg-12" id="cache-metrics-chart">
197197
<div style="width:50%">

0 commit comments

Comments
 (0)