From e96d455c644a21dfa1c17f1264a68a5bb17b0234 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Wed, 27 Nov 2019 19:24:15 +0100 Subject: [PATCH 1/3] Add notes about this firewall thing which is creating security issues if you don't need it ... --- scripts/install | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/scripts/install b/scripts/install index bca2fd3..4da9fc8 100755 --- a/scripts/install +++ b/scripts/install @@ -87,12 +87,16 @@ ynh_script_progression --message="Configuring firewall..." --time --weight=1 ### If you're not using these lines: ### - Remove the section "CLOSE A PORT" in the remove script -# Find a free port +# Find an available port port=$(ynh_find_port --port=8095) -# Open this port -ynh_exec_warn_less yunohost firewall allow --no-upnp TCP $port ynh_app_setting_set --app=$app --key=port --value=$port +# Optional: Expose this port publicly +# (N.B. : you only need to do this if the app actually needs to expose the port publicly. +# If you do this and the app doesn't actually need you are CREATING SECURITY HOLES IN THE SERVER !) +# ynh_exec_warn_less yunohost firewall allow --no-upnp TCP $port + + #================================================= # INSTALL DEPENDENCIES #================================================= From 8598039e748d3e81f4969e802dfd9eb07bfba59a Mon Sep 17 00:00:00 2001 From: Maniack Crudelis Date: Fri, 6 Dec 2019 18:28:44 +0100 Subject: [PATCH 2/3] Update install --- scripts/install | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/install b/scripts/install index 4da9fc8..1375c3a 100755 --- a/scripts/install +++ b/scripts/install @@ -94,6 +94,8 @@ ynh_app_setting_set --app=$app --key=port --value=$port # Optional: Expose this port publicly # (N.B. : you only need to do this if the app actually needs to expose the port publicly. # If you do this and the app doesn't actually need you are CREATING SECURITY HOLES IN THE SERVER !) + +# Open the port # ynh_exec_warn_less yunohost firewall allow --no-upnp TCP $port From 3b336759d8c34b282fd7bec304a01816b9f5bb74 Mon Sep 17 00:00:00 2001 From: Maniack Crudelis Date: Fri, 6 Dec 2019 18:29:03 +0100 Subject: [PATCH 3/3] Update install --- scripts/install | 1 - 1 file changed, 1 deletion(-) diff --git a/scripts/install b/scripts/install index 1375c3a..0be1fa7 100755 --- a/scripts/install +++ b/scripts/install @@ -98,7 +98,6 @@ ynh_app_setting_set --app=$app --key=port --value=$port # Open the port # ynh_exec_warn_less yunohost firewall allow --no-upnp TCP $port - #================================================= # INSTALL DEPENDENCIES #=================================================