mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-06-21 14:59:14 +02:00
Allow ingress access to restricted areas
This commit is contained in:
@@ -1,3 +1,5 @@
|
|||||||
|
- [INGRESS] Allow access to restricted area without password if authentificated from within the homeassistant app
|
||||||
|
|
||||||
## 0.13-31 (19-05-2024)
|
## 0.13-31 (19-05-2024)
|
||||||
- [SPECIES_CONVERTER] : Significantly improve, add a webui when the option is enabled
|
- [SPECIES_CONVERTER] : Significantly improve, add a webui when the option is enabled
|
||||||
- [SPECIES_CONVERTER] : Improve the SPECIES_CONVERTER webui with input text filtering in both browser and mobile
|
- [SPECIES_CONVERTER] : Improve the SPECIES_CONVERTER webui with input text filtering in both browser and mobile
|
||||||
|
|||||||
@@ -25,4 +25,8 @@ sed -i "s/%%port%%/${ingress_port}/g" /etc/nginx/servers/ingress.conf
|
|||||||
sed -i "s/%%interface%%/${ingress_interface}/g" /etc/nginx/servers/ingress.conf
|
sed -i "s/%%interface%%/${ingress_interface}/g" /etc/nginx/servers/ingress.conf
|
||||||
sed -i "s|%%ingress_entry%%|${ingress_entry}|g" /etc/nginx/servers/ingress.conf
|
sed -i "s|%%ingress_entry%%|${ingress_entry}|g" /etc/nginx/servers/ingress.conf
|
||||||
|
|
||||||
|
echo "... ensuring restricted area access"
|
||||||
|
echo "${ingress_entry}" > /ingress_url
|
||||||
|
sed -i "/function is_authenticated/a if (strpos(\$_SERVER['HTTP_REFERER'], '/api/hassio_ingress') !== false && strpos(\$_SERVER['HTTP_REFERER'], trim(file_get_contents('/ingress_url'))) !== false) { \$ret = true; return \$ret; }" "$HOME"/BirdNET-Pi/scripts/common.php
|
||||||
|
|
||||||
echo " "
|
echo " "
|
||||||
|
|||||||
Reference in New Issue
Block a user