Browse Source

more local firewall

dev
rootzoll 6 years ago
parent
commit
198c08eabc
  1. 4
      home.admin/90finishSetup.sh
  2. 4
      home.admin/config.scripts/lnd.export.sh

4
home.admin/90finishSetup.sh

@ -66,9 +66,9 @@ sudo ufw allow 8080 comment 'lightning REST API'
echo "allow: trasmission" echo "allow: trasmission"
sudo ufw allow 51413 comment 'transmission' sudo ufw allow 51413 comment 'transmission'
echo "allow: local web admin" echo "allow: local web admin"
sudo ufw allow from 192.168.0.0/24 to any port 80 comment 'allow local LAN web' sudo ufw allow from 192.168.0.0/16 to any port 80 comment 'allow local LAN web'
echo "open firewall for auto nat discover (see issue #129)" echo "open firewall for auto nat discover (see issue #129)"
sudo ufw allow proto udp from 192.168.0.0/24 port 1900 to any comment 'allow local LAN SSDP for UPnP discovery' sudo ufw allow proto udp from 192.168.0.0/16 port 1900 to any comment 'allow local LAN SSDP for UPnP discovery'
echo "enable lazy firewall" echo "enable lazy firewall"
sudo ufw --force enable sudo ufw --force enable
echo "" echo ""

4
home.admin/config.scripts/lnd.export.sh

@ -74,9 +74,9 @@ elif [ ${exportType} = "http" ]; then
sudo cp /home/bitcoin/.lnd/data/chain/${network}/${chain}net/readonly.macaroon ./${randomFolderName}/readonly.macaroon sudo cp /home/bitcoin/.lnd/data/chain/${network}/${chain}net/readonly.macaroon ./${randomFolderName}/readonly.macaroon
sudo cp /home/bitcoin/.lnd/tls.cert ./${randomFolderName}/tls.cert sudo cp /home/bitcoin/.lnd/tls.cert ./${randomFolderName}/tls.cert
cd ${randomFolderName} cd ${randomFolderName}
sudo ufw allow from 192.168.0.0/24 to any port ${randomPortNumber} comment 'temp http server' sudo ufw allow from 192.168.0.0/16 to any port ${randomPortNumber} comment 'temp http server'
python -m SimpleHTTPServer ${randomPortNumber} python -m SimpleHTTPServer ${randomPortNumber}
sudo ufw delete allow from 192.168.0.0/24 to any port ${randomPortNumber} comment 'temp http server' sudo ufw delete allow from 192.168.0.0/16 to any port ${randomPortNumber} comment 'temp http server'
cd .. cd ..
sudo rm -r ${randomFolderName} sudo rm -r ${randomFolderName}
echo "OK - temp HTTP server is stopped." echo "OK - temp HTTP server is stopped."

Loading…
Cancel
Save