Move the decision whether we are showing the no-HTTPS warning from server-side (where no https may be used when a reverse proxy is used) to user-side where this is more definite

Signed-off-by: DL6ER <dl6er@dl6er.de>
This commit is contained in:
DL6ER
2025-03-06 17:49:29 +01:00
parent 97d3a22559
commit a5e2c627a4
4 changed files with 9 additions and 5 deletions

View File

@@ -68,6 +68,6 @@ end
<!-- ./wrapper -->
<script src="<?=pihole.fileversion('scripts/js/footer.js')?>"></script>
<div id="advanced-info-data" style="display: none;" data-starttime="<?=starttime?>" data-endtime="<?=mg.time(true)?>" data-client-ip="<?=mg.request_info.remote_addr?>" data-tls="<?=tostring(is_secure)?>" data-xff="<?=x_forwarded_for?>"></div>
<div id="advanced-info-data" style="display: none;" data-starttime="<?=starttime?>" data-endtime="<?=mg.time(true)?>" data-client-ip="<?=mg.request_info.remote_addr?>" data-xff="<?=x_forwarded_for?>"></div>
</body>
</html>

View File

@@ -39,9 +39,6 @@ function in_array (val, tab)
return false
end
-- Connection is considered secure if running natively on HTTPS
is_secure = mg.request_info.https
-- Variable to check if user is already authenticated
is_authenticated = mg.request_info.is_authenticated