commit 81ca1f7280860891fec15060423b11e24cbb6a4a
Author: Self-Hosting-Group <155233284+Self-Hosting-Group@users.noreply.github.com>
Date:   Thu Oct 10 00:00:00 2024 +0000

    UPnP IGD & PCP: Improve descriptions

diff --git a/src/etc/inc/services.inc b/src/etc/inc/services.inc
index 9f6e5016ff..025e17cede 100644
--- a/src/etc/inc/services.inc
+++ b/src/etc/inc/services.inc
@@ -5223,7 +5223,7 @@ function upnp_start() {
 	}
 
 	if (config_get_path('installedpackages/miniupnpd/config/0/enable') == 'on') {
-		echo gettext("Starting UPnP service... ");
+		echo gettext("Starting UPnP IGD & PCP service...");
 		require_once('/usr/local/pkg/miniupnpd.inc');
 		sync_package_miniupnpd();
 		echo "done.\n";
diff --git a/src/usr/local/pkg/miniupnpd.inc b/src/usr/local/pkg/miniupnpd.inc
index 06b773bfd7..4d9169e43d 100644
--- a/src/usr/local/pkg/miniupnpd.inc
+++ b/src/usr/local/pkg/miniupnpd.inc
@@ -102,7 +102,7 @@
 			}
 		}
 		if ($post['overridewanip'] && !upnp_validate_ip($post['overridewanip'], false)) {
-			$input_errors[] = 'You must specify a valid ip address in the \'Override WAN address\' field';
+			$input_errors[] = 'You must specify a valid IP address in the \'Override WAN address\' field';
 		}
 		if (($post['download'] && !$post['upload']) || ($post['upload'] && !$post['download'])) {
 			$input_errors[] = 'You must fill in both \'Maximum Download Speed\' and \'Maximum Upload Speed\' fields';
@@ -126,26 +126,26 @@
 			}
 		}
 
-		/* user permissions validation */
+		/* ACL Entries validation */
 		$j = substr_count(implode(array_keys($post)), "permuser");
 		for ($i = 0; $i < $j; $i++) {
 			if ($post["permuser{$i}"]) {
 				$perm = explode(' ', $post["permuser{$i}"]);
 				/* should explode to 4 args */
 				if (count($perm) != 4) {
-					$input_errors[] = "You must follow the specified format in the 'User specified permissions {$i}' field";
+					$input_errors[] = "You must follow the specified format in the 'ACL Entries {$i}' field";
 				} else {
 					/* must with allow or deny */
 					if (!($perm[0] == 'allow' || $perm[0] == 'deny')) {
-						$input_errors[] = "You must begin with allow or deny in the 'User specified permissions {$i}' field";
+						$input_errors[] = "You must begin with allow or deny in the 'ACL Entries {$i}' field";
 					}
 					/* verify port or port range */
 					if (!upnp_validate_port($perm[1]) || !upnp_validate_port($perm[3])) {
-						$input_errors[] = "You must specify a port or port range between 0 and 65535 in the 'User specified permissions {$i}' field";
+						$input_errors[] = "You must specify a port or port range between 1 and 65535 in the 'ACL Entries {$i}' field";
 					}
 					/* verify ip address */
 					if (!upnp_validate_ip($perm[2], true)) {
-						$input_errors[] = "You must specify a valid ip address in the 'User specified permissions {$i}' field";
+						$input_errors[] = "You must specify a valid IP address in the 'ACL Entries {$i}' field";
 					}
 				}
 			}
@@ -200,7 +200,7 @@
 							$ifaces_active .= ", {$iface}";
 						}
 					} else {
-						upnp_warn("Interface {$iface} has no ip address, ignoring");
+						upnp_warn("Interface {$iface} has no IP address, ignoring");
 					}
 				} else {
 					upnp_warn("Could not resolve real interface for {$iface}");
@@ -267,7 +267,7 @@
 				}
 
 				if ($upnp_config['permdefault']) {
-					$config_text .= "deny 0-65535 0.0.0.0/0 0-65535\n";
+					$config_text .= "deny 1-65535 0.0.0.0/0 1-65535\n";
 				}
 
 				/* Recheck if queue is valid */
diff --git a/src/usr/local/pkg/miniupnpd.xml b/src/usr/local/pkg/miniupnpd.xml
index d9e09f80a7..1a00badaa1 100644
--- a/src/usr/local/pkg/miniupnpd.xml
+++ b/src/usr/local/pkg/miniupnpd.xml
@@ -27,7 +27,7 @@
 			<type>checkbox</type>
 			<enablefields>enable_upnp,enable_natpmp,ext_iface,iface_array,download,upload,overridewanip,upnpqueue,logpackets,sysuptime,permdefault</enablefields>
 			<description>Enable service</description>
-			<sethelp>Enable automatic port mapping service.</sethelp>
+			<sethelp>Enable autonomous port mapping service.</sethelp>
 		</field>
 		<field>
 			<fielddescr>UPnP IGD</fielddescr>
@@ -41,7 +41,7 @@
 			<fieldname>enable_natpmp</fieldname>
 			<type>checkbox</type>
 			<description>Allow PCP/NAT-PMP Port Mapping</description>
-			<sethelp>This protocol is often used by Apple-compatible systems.</sethelp>
+			<sethelp>These protocols are often used by Apple-compatible systems.</sethelp>
 		</field>
 		<field>
 			<fielddescr>External Interface</fielddescr>
@@ -64,13 +64,13 @@
 		<field>
 			<fielddescr>Download Speed</fielddescr>
 			<fieldname>download</fieldname>
-			<description>Set the Maximum Download Speed in Kbits/second.</description>
+			<description>Report maximum download speed in kbit/s.</description>
 			<type>input</type>
 		</field>
 		<field>
 			<fielddescr>Upload Speed</fielddescr>
 			<fieldname>upload</fieldname>
-			<description>Set the Maximum Upload Speed in Kbits/second.</description>
+			<description>Report maximum upload speed in kbit/s.</description>
 			<type>input</type>
 		</field>
 		<field>
@@ -95,7 +95,7 @@
 			<fielddescr>Uptime</fielddescr>
 			<fieldname>sysuptime</fieldname>
 			<type>checkbox</type>
-			<description>Use system uptime instead of service uptime.</description>
+			<description>Report system instead of service uptime.</description>
 		</field>
 		<field>
 			<fielddescr>Custom presentation URL</fielddescr>
@@ -154,7 +154,7 @@
 			<description>STUN UDP port (Default: 3478)</description>
 		</field>
 		<field>
-			<name>Service Access Control Lists</name>
+			<name>Service Access Control List</name>
 			<type>listtopic</type>
 		</field>
 		<field>
@@ -167,7 +167,7 @@
 			<name>ACL Help</name>
 			<type>info</type>
 			<description>
-			These entries control access to the service. Client systems may be granted or denied access based on several criteria.
+			These entries control access to the service. Client systems may be granted or denied access based on several criteria, IPv6 always allowed.
 			&lt;br /&gt;&lt;br /&gt;
 			Format: [allow or deny] [ext port or range] [int ipaddr or ipaddr/CIDR] [int port or range]
 			&lt;br /&gt;Example: allow 1024-65535 192.168.0.0/24 1024-65535</description>
diff --git a/src/usr/local/www/status_upnp.php b/src/usr/local/www/status_upnp.php
index b6a3d283af..973928cdc3 100644
--- a/src/usr/local/www/status_upnp.php
+++ b/src/usr/local/www/status_upnp.php
@@ -34,7 +34,7 @@ require_once("guiconfig.inc");
 if ($_POST) {
 	if ($_POST['clear']) {
 		upnp_action('restart');
-		$savemsg = gettext("Rules have been cleared and the daemon restarted.");
+		$savemsg = gettext("Port maps have been cleared and the service restarted.");
 	}
 }
 
@@ -67,7 +67,7 @@ if (!config_get_path('installedpackages/miniupnpd/config/0/iface_array') ||
 			<table class="table table-striped table-hover table-condensed sortable-theme-bootstrap" data-sortable>
 				<thead>
 					<tr>
-						<th><?=gettext("Interface")?></th>
+						<th><?=gettext("Ext Interface")?></th>
 						<th><?=gettext("Ext Port")?></th>
 						<th><?=gettext("Int IP")?></th>
 						<th><?=gettext("Int Port")?></th>
@@ -126,9 +126,9 @@ foreach ($rdr_entries as $rdr_entry) {
 <div>
 	<form action="status_upnp.php" method="post">
 		<nav class="action-buttons">
-			<button class="btn btn-danger btn-sm" type="submit" name="clear" id="clear" value="<?=gettext("Clear all sessions")?>">
+			<button class="btn btn-danger btn-sm" type="submit" name="clear" id="clear" value="<?=gettext("Clear all port maps")?>">
 				<i class="fa-solid fa-trash-can icon-embed-btn"></i>
-				<?=gettext("Clear all sessions")?>
+				<?=gettext("Clear all port maps")?>
 			</button>
 		</nav>
 	</form>
