diff --git a/buildall.sh b/buildall.sh
index 86a94a67..a1deb282 100755
--- a/buildall.sh
+++ b/buildall.sh
@@ -1,6 +1,6 @@
#!/bin/bash
-# The buildall.sh script is designed to streamline the build process for the project.
+# The buildall.sh script is a tool to build the project and help developers.
# It allows you to run different build commands based on whether you are using "sudo" and supports multiple package managers.
# If you need to run the build commands with "sudo[script]" (look at package.json scripts), provide the "with-sudo" argument :
#
diff --git a/src/lib/Firewall.js b/src/lib/Firewall.js
index 7c5aca38..8d3e3c3b 100644
--- a/src/lib/Firewall.js
+++ b/src/lib/Firewall.js
@@ -46,51 +46,46 @@ module.exports = class Firewall {
async getIptablesRules() {
// iptables list the rules WG_IPT_CHAIN_NAME chain
-<<<<<<< HEAD
-<<<<<<< HEAD
//
// $ iptables -L WGEASY -nv --line-numbers
// Chain WGEASY (0 references)
// num pkts bytes target prot opt in out source destination
-<<<<<<< HEAD
- // 1 0 0 ACCEPT 6 -- * * 172.16.7.2 10.8.2.5
+ // 1 0 0 ACCEPT 6 -- * * 172.16.7.2 10.8.2.5 tcp spt:22565 dpt:53
//
- // $ iptables -L ${WG_IPT_CHAIN_NAME} -nv --line-numbers | awk '{print $1,$4,$5,$9,$10}'
+ // $ iptables -L ${WG_IPT_CHAIN_NAME} -nv --line-numbers | awk '{print $1,$4,$5,$9,$10,$12,$13}'
// Chain (0 references)
// num target prot source destination
// 1 ACCEPT 6 172.16.7.2 10.8.2.5
-=======
- // $ iptables -L ${WG_IPT_CHAIN_NAME} -n -v
-=======
- //
- // $ iptables -L WGEASY -nv --line-numbers
->>>>>>> b4f7165 (fix: restrict access to vue templates directory)
- // Chain WGEASY (0 references)
- // num pkts bytes target prot opt in out source destination
-=======
->>>>>>> 2bac779 (fix: lint)
- // 1 0 0 ACCEPT 6 -- * * 172.16.7.2 10.8.2.5
- //
- // $ iptables -L ${WG_IPT_CHAIN_NAME} -nv --line-numbers | awk '{print $1,$4,$5,$9,$10}'
- // Chain (0 references)
- // num target prot source destination
-<<<<<<< HEAD
- // 1 DROP 6 172.16.8.2 172.16.8.3
- // 2 ACCEPT 6 172.16.9.2 172.16.8.3
->>>>>>> 9ec7359 (feat: firewall)
-=======
- // 1 ACCEPT 6 172.16.7.2 10.8.2.5
->>>>>>> b4f7165 (fix: restrict access to vue templates directory)
- const stdout = await Util.exec(`iptables -L ${WG_IPT_CHAIN_NAME} -nv --line-numbers | awk '{print $1,$4,$5,$9,$10}'`);
+ const stdout = await Util.exec(`iptables -L ${WG_IPT_CHAIN_NAME} -nv --line-numbers | awk '{print $1,$4,$5,$9,$10,$12,$13}'`);
const lines = stdout.split(/\r?\n/);
const rules = lines.slice(2).map((line) => {
- const [num, target, protocol, source, destination] = line.trim().split(' ');
+ const [num, target, protocol, source, destination, spt, dpt] = line.trim().split(' ');
const targetToName = Util.getTargetName(target);
const protocolToName = Util.getProtocolName(protocol);
+ let newSource = source;
+ let newDestination = destination;
+
+ if (spt) {
+ // eslint-disable-next-line no-unused-vars
+ const [_, sPort] = spt.split(':');
+ if (spt.startsWith('spt')) {
+ newSource += `:${sPort}`;
+ }
+ if (spt.startsWith('dpt')) {
+ newDestination += `:${sPort}`;
+ }
+ }
+
+ if (dpt) {
+ // eslint-disable-next-line no-unused-vars
+ const [_, dPort] = dpt.split(':');
+ newDestination += `:${dPort}`;
+ }
+
return {
- num, target: targetToName, source, destination, protocol: protocolToName,
+ num, target: targetToName, source: newSource, destination: newDestination, protocol: protocolToName,
};
}).filter((rule) => rule !== null);
@@ -99,8 +94,6 @@ module.exports = class Firewall {
async addIptablesRule(source, destination, protocol, target) {
debug('Rule adding...');
-<<<<<<< HEAD
-<<<<<<< HEAD
// Validate target & protocol
if (!Util.isTarget(target) || !Util.isProtocol(protocol)) {
throw new Error('Invalid target or protocol.');
@@ -108,93 +101,38 @@ module.exports = class Firewall {
/*
Support command :
- iptables -A CHAIN -s [IPv4 | IPv4/CIDR] [--sport PORT] -d [IPv4 | IPv4/CIDR] [--dport PORT] -p PROTOCOL -j TARGET
+ iptables -A CHAIN -s [IPv4 | IPv4/CIDR] -d [IPv4 | IPv4/CIDR] -p PROTOCOL [--sport PORT] [--dport PORT] -j TARGET
*/
let iptablesCommand = `iptables -A ${WG_IPT_CHAIN_NAME}`;
- if (Util.isSupportedAddress(source)) {
- const [address, port] = source.split(':');
- if (Util.isIPAddress(address) || Util.isCIDR(address)) {
- iptablesCommand += ` -s ${address}`;
- if (port) {
- iptablesCommand += ` --sport ${port}`;
- }
+ if (Util.isSupportedAddress(source) && Util.isSupportedAddress(destination)) {
+ const [sAddress, sPort] = source.split(':');
+ const [dAddress, dPort] = destination.split(':');
+ if (Util.isIPAddress(sAddress) || Util.isCIDR(sAddress)) {
+ iptablesCommand += ` -s ${sAddress}`;
} else {
throw new Error('Invalid source address.');
}
- } else {
- throw new Error('Invalid source format.');
- }
-
- if (Util.isSupportedAddress(destination)) {
- const [address, port] = destination.split(':');
- if (Util.isIPAddress(address) || Util.isCIDR(address)) {
- iptablesCommand += ` -d ${address}`;
- if (port) {
- iptablesCommand += ` --dport ${port}`;
- }
+ if (Util.isIPAddress(dAddress) || Util.isCIDR(dAddress)) {
+ iptablesCommand += ` -d ${dAddress}`;
} else {
throw new Error('Invalid destination address.');
}
+ iptablesCommand += ` -p ${protocol}`;
+ if (sPort) {
+ iptablesCommand += ` --sport ${sPort}`;
+ }
+ if (dPort) {
+ iptablesCommand += ` --dport ${dPort}`;
+ }
} else {
- throw new Error('Invalid destination format.');
- }
-
- iptablesCommand += ` -p ${protocol} -j ${target}`;
-
- await Util.exec(iptablesCommand);
-=======
- // Validate target
- if (!Util.isValidIptablesTarget(target)) {
- throw new Error('Invalid target.');
- }
-
-<<<<<<< HEAD
- await Util.exec(`iptables -A ${WG_IPT_CHAIN_NAME} -s ${source} -d ${destination} -p ${protocol} -j ${target}`);
->>>>>>> 9ec7359 (feat: firewall)
-=======
- // Validate protocol
- if (!Util.isValidIptablesProtocol(protocol)) {
- throw new Error('Invalid protocol.');
-=======
- // Validate target & protocol
- if (!Util.isValidIptablesTarget(target) || !Util.isValidIptablesProtocol(protocol)) {
- throw new Error('Invalid target or protocol.');
- }
-
-<<<<<<< HEAD
- // If empty source or destination
- if (!source || !destination) {
- throw new Error('Invalid source or destination address.')
->>>>>>> a20e416 (fix: source & destination are required)
- }
-
-=======
->>>>>>> 48f8be5 (fix: lint)
- /*
- Support command :
- iptables -A CHAIN -s [IPv4 | IPv4/CIDR] -d [IPv4 | IPv4/CIDR] -p PROTOCOL -j TARGET
- */
-
- let iptablesCommand = `iptables -A ${WG_IPT_CHAIN_NAME}`;
-
- if (source && (Util.isIPAddress(source) || Util.isCIDR(source))) {
- iptablesCommand += ` -s ${source}`;
- } else {
- throw new Error('Invalid source address.');
- }
-
- if (destination && (Util.isIPAddress(destination) || Util.isCIDR(destination))) {
- iptablesCommand += ` -d ${destination}`;
- } else {
- throw new Error('Invalid destination address.');
+ throw new Error('Invalid source/destination format.');
}
- iptablesCommand += ` -p ${protocol} -j ${target}`;
+ iptablesCommand += ` -j ${target}`;
await Util.exec(iptablesCommand);
->>>>>>> 88b4ba1 (update: support @ip range with CIDR)
await this.__saveIptablesRules();
debug('Rule added');
}
diff --git a/src/lib/Util.js b/src/lib/Util.js
index feed5951..df3b0002 100644
--- a/src/lib/Util.js
+++ b/src/lib/Util.js
@@ -113,14 +113,40 @@ module.exports = class Util {
return ipRegex.test(ip);
}
- static isValidIptablesTarget(target) {
+ static isTarget(target) {
return Object.values(Target).includes(target);
}
- static isValidIptablesProtocol(protocol) {
+ static isProtocol(protocol) {
return Object.keys(Protocol).includes(protocol);
}
+ static isPort(port) {
+ return port >= 0 && port <= 65535;
+ }
+
+ static isRangeAddresses() {
+ /* implement */
+ }
+
+ static isRangePorts() {
+ /* implement */
+ }
+
+ /* Support addresses are :
+ 192.168.1.1
+ 192.168.1.1:53
+ 192.168.1.0/24
+ 192.168.1.0/24:53
+ */
+ static isSupportedAddress(address) {
+ const parts = address.split(':');
+ if (parts.length > 2) return false;
+ const isAddress = this.isIPAddress(parts[0]) || this.isCIDR(parts[0]);
+ if (parts[1]) return this.isPort(parts[1]) && isAddress;
+ return isAddress;
+ }
+
static getProtocolName(protocolNumber) {
return ProtocolName[protocolNumber] || 'Unknown Protocol';
}
diff --git a/src/package-lock.json b/src/package-lock.json
index 47f53818..d60863a8 100644
--- a/src/package-lock.json
+++ b/src/package-lock.json
@@ -747,11 +747,7 @@
"resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.3.tgz",
"integrity": "sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==",
"dev": true,
-<<<<<<< HEAD
"license": "MIT",
- "peer": true,
-=======
->>>>>>> 88b4ba1 (update: support @ip range with CIDR)
"engines": {
"node": ">=6"
}
@@ -1114,11 +1110,7 @@
"resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz",
"integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
"dev": true,
-<<<<<<< HEAD
"license": "MIT",
- "peer": true,
-=======
->>>>>>> 88b4ba1 (update: support @ip range with CIDR)
"dependencies": {
"ansi-styles": "^4.1.0",
"supports-color": "^7.1.0"
@@ -1712,11 +1704,7 @@
"resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz",
"integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==",
"dev": true,
-<<<<<<< HEAD
"license": "MIT",
- "peer": true,
-=======
->>>>>>> 88b4ba1 (update: support @ip range with CIDR)
"engines": {
"node": ">=10"
},
@@ -2434,28 +2422,8 @@
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz",
"integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==",
-<<<<<<< HEAD
- "dev": true,
- "license": "ISC",
- "peer": true
-=======
- "dev": true
->>>>>>> 88b4ba1 (update: support @ip range with CIDR)
- },
- "node_modules/fsevents": {
- "version": "2.3.3",
- "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz",
- "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==",
"dev": true,
- "hasInstallScript": true,
- "license": "MIT",
- "optional": true,
- "os": [
- "darwin"
- ],
- "engines": {
- "node": "^8.16.0 || ^10.6.0 || >=11.0.0"
- }
+ "license": "ISC"
},
"node_modules/function-bind": {
"version": "1.1.2",
@@ -2704,11 +2672,7 @@
"resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
"integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
"dev": true,
-<<<<<<< HEAD
"license": "MIT",
- "peer": true,
-=======
->>>>>>> 88b4ba1 (update: support @ip range with CIDR)
"engines": {
"node": ">=8"
}
@@ -2842,11 +2806,7 @@
"integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==",
"deprecated": "This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.",
"dev": true,
-<<<<<<< HEAD
"license": "ISC",
- "peer": true,
-=======
->>>>>>> 88b4ba1 (update: support @ip range with CIDR)
"dependencies": {
"once": "^1.3.0",
"wrappy": "1"
@@ -2856,13 +2816,8 @@
"version": "2.0.4",
"resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz",
"integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==",
-<<<<<<< HEAD
"dev": true,
- "license": "ISC",
- "peer": true
-=======
- "dev": true
->>>>>>> 88b4ba1 (update: support @ip range with CIDR)
+ "license": "ISC"
},
"node_modules/internal-slot": {
"version": "1.0.7",
@@ -3968,11 +3923,7 @@
"resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz",
"integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==",
"dev": true,
-<<<<<<< HEAD
"license": "ISC",
- "peer": true,
-=======
->>>>>>> 88b4ba1 (update: support @ip range with CIDR)
"dependencies": {
"wrappy": "1"
}
@@ -4993,11 +4944,7 @@
"resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz",
"integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==",
"dev": true,
-<<<<<<< HEAD
"license": "MIT",
- "peer": true,
-=======
->>>>>>> 88b4ba1 (update: support @ip range with CIDR)
"engines": {
"node": ">=8"
},
@@ -5080,11 +5027,7 @@
"resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
"integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
"dev": true,
-<<<<<<< HEAD
"license": "MIT",
- "peer": true,
-=======
->>>>>>> 88b4ba1 (update: support @ip range with CIDR)
"dependencies": {
"has-flag": "^4.0.0"
},
@@ -5611,13 +5554,8 @@
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz",
"integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==",
-<<<<<<< HEAD
"dev": true,
- "license": "ISC",
- "peer": true
-=======
- "dev": true
->>>>>>> 88b4ba1 (update: support @ip range with CIDR)
+ "license": "ISC"
},
"node_modules/y18n": {
"version": "4.0.3",
diff --git a/src/www/css/app.css b/src/www/css/app.css
index a519a483..ca1c65b7 100644
--- a/src/www/css/app.css
+++ b/src/www/css/app.css
@@ -1154,6 +1154,10 @@ video {
background-color: rgb(254 226 226 / var(--tw-bg-opacity));
}
+.bg-red-500\/50 {
+ background-color: rgb(239 68 68 / 0.5);
+}
+
.bg-red-600 {
--tw-bg-opacity: 1;
background-color: rgb(220 38 38 / var(--tw-bg-opacity));
diff --git a/src/www/js/vendor/vue-firewall.umd.min.js b/src/www/js/vendor/vue-firewall.umd.min.js
index fa47e6d7..b3146f24 100644
--- a/src/www/js/vendor/vue-firewall.umd.min.js
+++ b/src/www/js/vendor/vue-firewall.umd.min.js
@@ -1,2 +1,2 @@
-(function(t,e){"object"===typeof exports&&"object"===typeof module?module.exports=e():"function"===typeof define&&define.amd?define([],e):"object"===typeof exports?exports["VueFirewall"]=e():t["VueFirewall"]=e()})("undefined"!==typeof self?self:this,(()=>(()=>{"use strict";var t={};(()=>{t.d=(e,r)=>{for(var a in r)t.o(r,a)&&!t.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:r[a]})}})(),(()=>{t.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e)})(),(()=>{t.p=""})();var e={};if(t.d(e,{default:()=>c}),"undefined"!==typeof window){var r=window.document.currentScript,a=r&&r.src.match(/(.+\/)[^/]+\.js(\?.*)?$/);a&&(t.p=a[1])}var s=function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",{staticClass:"shadow-md rounded-lg bg-white dark:bg-neutral-700 overflow-hidden mb-4"},[r("div",{staticClass:"flex flex-row flex-auto items-center p-3 px-5 border-b-2 border-neutral-500/50 dark:border-neutral-600"},[r("div",{staticClass:"flex-grow"},[r("p",{staticClass:"text-2xl font-medium dark:text-neutral-200"},[t._v(t._s(t.$t("fwFirewall")))])])]),r("div",{staticClass:"container p-2 flex flex-col md:items-center"},[r("table",{staticClass:"border border-neutral-500/50 bg-gray-200/10 dark:text-neutral-200 md:w-[75%] mb-4"},[r("thead",[r("tr",[r("th",{staticClass:"border border-neutral-500/50 text-start p-1"},[t._v(t._s(t.$t("fwInterface")))]),r("th",{staticClass:"border border-neutral-500/50 text-start p-1"},[t._v(t._s(t.$t("fwIpv4")))]),r("th",{staticClass:"border border-neutral-500/50 text-start p-1"},[t._v(t._s(t.$t("fwIpv6")))])])]),r("tbody",t._l(t.interfaces,(function(e,a){return r("tr",{key:a},[r("td",{staticClass:"border border-neutral-500/50 p-1"},[t._v(t._s(e.name))]),r("td",{staticClass:"border border-neutral-500/50 p-1"},[t._v(t._s(e.ipv4))]),r("td",{staticClass:"border border-neutral-500/50 p-1"},[t._v(t._s(e.ipv6))])])})),0)]),r("form",{attrs:{id:"fw"},on:{submit:t.addRule}}),r("div",{staticClass:"overflow-x-auto"},[r("table",{staticClass:"dark:text-neutral-200 border-t-2 border-collapse dark:border-neutral-200 p-2"},[r("thead",{staticClass:"bg-gray-200 dark:bg-neutral-600"},[r("tr",[r("th",{staticClass:"border dark:border-neutral-200 p-1"},[t._v(t._s(t.$t("fwAction")))]),r("th",{staticClass:"border dark:border-neutral-200 p-1"},[t._v(t._s(t.$t("fwSource")))]),r("th",{staticClass:"border dark:border-neutral-200 p-1"},[t._v(t._s(t.$t("fwDestination")))]),r("th",{staticClass:"border dark:border-neutral-200 p-1"},[t._v(t._s(t.$t("fwProtocol")))]),r("th",{staticClass:"border dark:border-neutral-200 p-1"},[t._v(t._s(t.$t("fwTarget")))])])]),r("tbody",{staticClass:"text-center"},[t._l(t.rules,(function(e,a){return r("tr",{key:a},[r("td",{staticClass:"border border-neutral-500/50 p-1 hover:bg-red-800/50 transition"},[r("button",{attrs:{type:"button"},on:{click:function(r){return t.deleteRule(e.num)}}},[r("svg",{staticClass:"size-6",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"}},[r("path",{attrs:{"stroke-linecap":"round","stroke-linejoin":"round",d:"m14.74 9-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 0 1-2.244 2.077H8.084a2.25 2.25 0 0 1-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 0 0-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 0 1 3.478-.397m7.5 0v-.916c0-1.18-.91-2.164-2.09-2.201a51.964 51.964 0 0 0-3.32 0c-1.18.037-2.09 1.022-2.09 2.201v.916m7.5 0a48.667 48.667 0 0 0-7.5 0"}})])])]),r("td",{staticClass:"border border-neutral-500/50 p-1"},[t._v(t._s(e.source))]),r("td",{staticClass:"border border-neutral-500/50 p-1"},[t._v(t._s(e.destination))]),r("td",{staticClass:"border border-neutral-500/50 p-1"},[t._v(t._s(e.protocol))]),r("td",{staticClass:"border border-neutral-500/50 p-1"},[t._v(t._s(e.target))])])})),r("tr",[r("td",{staticClass:"border border-neutral-500/50 p-1 hover:bg-green-800/50 transition"},[r("button",{attrs:{form:"fw",type:"submit"}},[r("svg",{staticClass:"size-6",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"}},[r("path",{attrs:{"stroke-linecap":"round","stroke-linejoin":"round",d:"M12 4.5v15m7.5-7.5h-15"}})])])]),r("td",{staticClass:"border border-neutral-500/50"},[r("input",{directives:[{name:"model",rawName:"v-model",value:t.newRule.source,expression:"newRule.source"}],staticClass:"outline-none bg-transparent text-center",attrs:{form:"fw",type:"text",name:"source"},domProps:{value:t.newRule.source},on:{input:function(e){e.target.composing||t.$set(t.newRule,"source",e.target.value)}}})]),r("td",{staticClass:"border border-neutral-500/50"},[r("input",{directives:[{name:"model",rawName:"v-model",value:t.newRule.destination,expression:"newRule.destination"}],staticClass:"outline-none bg-transparent text-center",attrs:{form:"fw",type:"text",name:"destination"},domProps:{value:t.newRule.destination},on:{input:function(e){e.target.composing||t.$set(t.newRule,"destination",e.target.value)}}})]),r("td",{staticClass:"border border-neutral-500/50"},[r("select",{staticClass:"bg-transparent",attrs:{form:"fw",name:"protocol"},on:{change:function(e){return t.newRule.protocol=e.target.value}}},[r("option",{staticClass:"dark:text-white dark:bg-neutral-700",attrs:{selected:"",value:"TCP"}},[t._v("TCP")]),r("option",{staticClass:"dark:text-white dark:bg-neutral-700",attrs:{value:"UDP"}},[t._v("UDP")])])]),r("td",{staticClass:"border border-neutral-500/50 p-1"},[r("select",{directives:[{name:"model",rawName:"v-model",value:t.newRule.target,expression:"newRule.target"}],staticClass:"bg-transparent",attrs:{form:"fw",name:"target"},on:{change:function(e){var r=Array.prototype.filter.call(e.target.options,(function(t){return t.selected})).map((function(t){var e="_value"in t?t._value:t.value;return e}));t.$set(t.newRule,"target",e.target.multiple?r:r[0])}}},[r("option",{staticClass:"dark:text-white dark:bg-neutral-700",attrs:{value:"ACCEPT"}},[t._v("ALLOW")]),r("option",{staticClass:"dark:text-white dark:bg-neutral-700",attrs:{selected:"",value:"DROP"}},[t._v("BLOCK")])])])])],2)])])])])},n=[];const o={name:"Firewall",data(){let t=[],e=[],r={source:"*",destination:"*",protocol:"TCP",target:"DROP"};return{interfaces:t,rules:e,newRule:r}},methods:{getInterfaces(){this.api.getInterfaces().then((t=>{this.interfaces=t})).catch((t=>{alert(t.message||t.toString())}))},getRules(){this.api.getRules().then((t=>{this.rules=t})).catch((t=>{alert(t.message||t.toString())}))},addRule(t){t.preventDefault();const{source:e,destination:r,protocol:a,target:s}=this.newRule;this.api.addRule({source:e,destination:r,protocol:a,target:s}).then((()=>{this.newRule={source:"*",destination:"*",protocol:"TCP",target:"DROP"}})).catch((t=>{alert(t.message||t.toString())})).finally((()=>{this.getRules()}))},deleteRule(t){this.api.deleteRule({num:t}).catch((t=>{alert(t.message||t.toString())})).finally((()=>{this.getRules()}))}},mounted(){this.api=new API,this.getInterfaces(),this.getRules()}},l=o;function i(t,e,r,a,s,n,o,l){var i,d="function"===typeof t?t.options:t;if(e&&(d.render=e,d.staticRenderFns=r,d._compiled=!0),a&&(d.functional=!0),n&&(d._scopeId="data-v-"+n),o?(i=function(t){t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,t||"undefined"===typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),s&&s.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(o)},d._ssrRegister=i):s&&(i=l?function(){s.call(this,(d.functional?this.parent:this).$root.$options.shadowRoot)}:s),i)if(d.functional){d._injectStyles=i;var u=d.render;d.render=function(t,e){return i.call(e),u(t,e)}}else{var c=d.beforeCreate;d.beforeCreate=c?[].concat(c,i):[i]}return{exports:t,options:d}}var d=i(l,s,n,!1,null,null,null);const u=d.exports,c=u;return e=e["default"],e})()));
+(function(t,e){"object"===typeof exports&&"object"===typeof module?module.exports=e():"function"===typeof define&&define.amd?define([],e):"object"===typeof exports?exports["VueFirewall"]=e():t["VueFirewall"]=e()})("undefined"!==typeof self?self:this,(()=>(()=>{"use strict";var t={};(()=>{t.d=(e,r)=>{for(var a in r)t.o(r,a)&&!t.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:r[a]})}})(),(()=>{t.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e)})(),(()=>{t.p=""})();var e={};if(t.d(e,{default:()=>c}),"undefined"!==typeof window){var r=window.document.currentScript,a=r&&r.src.match(/(.+\/)[^/]+\.js(\?.*)?$/);a&&(t.p=a[1])}var s=function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",{staticClass:"shadow-md rounded-lg bg-white dark:bg-neutral-700 overflow-hidden mb-4"},[r("div",{staticClass:"flex flex-row flex-auto items-center p-3 px-5 border-b-2 border-neutral-500/50 dark:border-neutral-600"},[r("div",{staticClass:"flex-grow"},[r("p",{staticClass:"text-2xl font-medium dark:text-neutral-200"},[t._v(t._s(t.$t("fwFirewall")))])])]),r("div",{staticClass:"container p-2 flex flex-col md:items-center"},[r("table",{staticClass:"border border-neutral-500/50 bg-gray-200/10 dark:text-neutral-200 md:w-[75%] mb-4"},[r("thead",[r("tr",[r("th",{staticClass:"border border-neutral-500/50 text-start p-1"},[t._v(t._s(t.$t("fwInterface")))]),r("th",{staticClass:"border border-neutral-500/50 text-start p-1"},[t._v(t._s(t.$t("fwIpv4")))]),r("th",{staticClass:"border border-neutral-500/50 text-start p-1"},[t._v(t._s(t.$t("fwIpv6")))])])]),r("tbody",t._l(t.interfaces,(function(e,a){return r("tr",{key:a},[r("td",{staticClass:"border border-neutral-500/50 p-1"},[t._v(t._s(e.name))]),r("td",{staticClass:"border border-neutral-500/50 p-1"},[t._v(t._s(e.ipv4))]),r("td",{staticClass:"border border-neutral-500/50 p-1"},[t._v(t._s(e.ipv6))])])})),0)]),r("form",{attrs:{id:"fw"},on:{submit:t.addRule}}),r("div",{staticClass:"overflow-x-auto"},[r("table",{staticClass:"dark:text-neutral-200 border-t-2 border-collapse dark:border-neutral-200 p-2"},[r("thead",{staticClass:"bg-gray-200 dark:bg-neutral-600"},[r("tr",[r("th",{staticClass:"border dark:border-neutral-200 p-1"},[t._v(t._s(t.$t("fwAction")))]),r("th",{staticClass:"border dark:border-neutral-200 p-1"},[t._v(t._s(t.$t("fwSource")))]),r("th",{staticClass:"border dark:border-neutral-200 p-1"},[t._v(t._s(t.$t("fwDestination")))]),r("th",{staticClass:"border dark:border-neutral-200 p-1"},[t._v(t._s(t.$t("fwProtocol")))]),r("th",{staticClass:"border dark:border-neutral-200 p-1"},[t._v(t._s(t.$t("fwTarget")))])])]),r("tbody",{staticClass:"text-center"},[t._l(t.rules,(function(e,a){return r("tr",{key:a,class:["BLOCK"==e.target?"bg-red-500/50":""]},[r("td",{staticClass:"border border-neutral-500/50 p-1 hover:bg-red-800/50 transition"},[r("button",{attrs:{type:"button"},on:{click:function(r){return t.deleteRule(e.num)}}},[r("svg",{staticClass:"size-6",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"}},[r("path",{attrs:{"stroke-linecap":"round","stroke-linejoin":"round",d:"m14.74 9-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 0 1-2.244 2.077H8.084a2.25 2.25 0 0 1-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 0 0-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 0 1 3.478-.397m7.5 0v-.916c0-1.18-.91-2.164-2.09-2.201a51.964 51.964 0 0 0-3.32 0c-1.18.037-2.09 1.022-2.09 2.201v.916m7.5 0a48.667 48.667 0 0 0-7.5 0"}})])])]),r("td",{staticClass:"border border-neutral-500/50 p-1"},[t._v(t._s(e.source))]),r("td",{staticClass:"border border-neutral-500/50 p-1"},[t._v(t._s(e.destination))]),r("td",{staticClass:"border border-neutral-500/50 p-1"},[t._v(t._s(e.protocol))]),r("td",{staticClass:"border border-neutral-500/50 p-1"},[t._v(t._s(e.target))])])})),r("tr",[r("td",{staticClass:"border border-neutral-500/50 p-1 hover:bg-green-800/50 transition"},[r("button",{attrs:{form:"fw",type:"submit"}},[r("svg",{staticClass:"size-6",attrs:{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor"}},[r("path",{attrs:{"stroke-linecap":"round","stroke-linejoin":"round",d:"M12 4.5v15m7.5-7.5h-15"}})])])]),r("td",{staticClass:"border border-neutral-500/50"},[r("input",{directives:[{name:"model",rawName:"v-model",value:t.newRule.source,expression:"newRule.source"}],staticClass:"outline-none bg-transparent text-center",attrs:{form:"fw",type:"text",name:"source"},domProps:{value:t.newRule.source},on:{input:function(e){e.target.composing||t.$set(t.newRule,"source",e.target.value)}}})]),r("td",{staticClass:"border border-neutral-500/50"},[r("input",{directives:[{name:"model",rawName:"v-model",value:t.newRule.destination,expression:"newRule.destination"}],staticClass:"outline-none bg-transparent text-center",attrs:{form:"fw",type:"text",name:"destination"},domProps:{value:t.newRule.destination},on:{input:function(e){e.target.composing||t.$set(t.newRule,"destination",e.target.value)}}})]),r("td",{staticClass:"border border-neutral-500/50"},[r("select",{staticClass:"bg-transparent",attrs:{form:"fw",name:"protocol"},on:{change:function(e){return t.newRule.protocol=e.target.value}}},[r("option",{staticClass:"dark:text-white dark:bg-neutral-700",attrs:{selected:"",value:"TCP"}},[t._v("TCP")]),r("option",{staticClass:"dark:text-white dark:bg-neutral-700",attrs:{value:"UDP"}},[t._v("UDP")])])]),r("td",{staticClass:"border border-neutral-500/50 p-1"},[r("select",{directives:[{name:"model",rawName:"v-model",value:t.newRule.target,expression:"newRule.target"}],staticClass:"bg-transparent",attrs:{form:"fw",name:"target"},on:{change:function(e){var r=Array.prototype.filter.call(e.target.options,(function(t){return t.selected})).map((function(t){var e="_value"in t?t._value:t.value;return e}));t.$set(t.newRule,"target",e.target.multiple?r:r[0])}}},[r("option",{staticClass:"dark:text-white dark:bg-neutral-700",attrs:{value:"ACCEPT"}},[t._v("ALLOW")]),r("option",{staticClass:"dark:text-white dark:bg-neutral-700",attrs:{selected:"",value:"DROP"}},[t._v("BLOCK")])])])])],2)])])])])},n=[];const o={name:"Firewall",data(){let t=[],e=[],r={source:"",destination:"",protocol:"TCP",target:"DROP"};return{interfaces:t,rules:e,newRule:r}},methods:{getInterfaces(){this.api.getInterfaces().then((t=>{this.interfaces=t})).catch((t=>{alert(t.message||t.toString())}))},getRules(){this.api.getRules().then((t=>{this.rules=t})).catch((t=>{alert(t.message||t.toString())}))},addRule(t){t.preventDefault();const{source:e,destination:r,protocol:a,target:s}=this.newRule;this.api.addRule({source:e,destination:r,protocol:a,target:s}).then((()=>{this.newRule={source:"",destination:"",protocol:"TCP",target:"DROP"}})).catch((t=>{alert(t.message||t.toString())})).finally((()=>{this.getRules()}))},deleteRule(t){this.api.deleteRule({num:t}).catch((t=>{alert(t.message||t.toString())})).finally((()=>{this.getRules()}))}},mounted(){this.api=new API,this.getInterfaces(),this.getRules()}},l=o;function i(t,e,r,a,s,n,o,l){var i,d="function"===typeof t?t.options:t;if(e&&(d.render=e,d.staticRenderFns=r,d._compiled=!0),a&&(d.functional=!0),n&&(d._scopeId="data-v-"+n),o?(i=function(t){t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext,t||"undefined"===typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),s&&s.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(o)},d._ssrRegister=i):s&&(i=l?function(){s.call(this,(d.functional?this.parent:this).$root.$options.shadowRoot)}:s),i)if(d.functional){d._injectStyles=i;var u=d.render;d.render=function(t,e){return i.call(e),u(t,e)}}else{var c=d.beforeCreate;d.beforeCreate=c?[].concat(c,i):[i]}return{exports:t,options:d}}var d=i(l,s,n,!1,null,null,null);const u=d.exports,c=u;return e=e["default"],e})()));
//# sourceMappingURL=vue-firewall.umd.min.js.map
\ No newline at end of file
diff --git a/src/www/js/vendor/vue-firewall.umd.min.js.map b/src/www/js/vendor/vue-firewall.umd.min.js.map
index c25987c5..ac688bda 100644
--- a/src/www/js/vendor/vue-firewall.umd.min.js.map
+++ b/src/www/js/vendor/vue-firewall.umd.min.js.map
@@ -1 +1 @@
-{"version":3,"file":"vue-firewall.umd.min.js","mappings":"CAAA,SAA2CA,EAAMC,GAC1B,kBAAZC,SAA0C,kBAAXC,OACxCA,OAAOD,QAAUD,IACQ,oBAAXG,QAAyBA,OAAOC,IAC9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EAAGb,EAC3B,CACF,KAAO,CAEL,IAAIc,EAAWjD,EAAQkD,aACvBlD,EAAQkD,aAAeD,EAAW,GAAGE,OAAOF,EAAUlB,GAAQ,CAACA,EACjE,CAGF,MAAO,CACLhG,QAAS0F,EACTzB,QAASA,EAEb,CCxFA,IAAIoD,EAAY,EACd,EACA3F,EACA6C,GACA,EACA,KACA,KACA,MAIF,QAAe8C,EAAiB,QChBhC,I","sources":["webpack://VueFirewall/webpack/universalModuleDefinition","webpack://VueFirewall/webpack/bootstrap","webpack://VueFirewall/webpack/runtime/define property getters","webpack://VueFirewall/webpack/runtime/hasOwnProperty shorthand","webpack://VueFirewall/webpack/runtime/publicPath","webpack://VueFirewall/../../../.local/share/pnpm/global/5/.pnpm/@vue+cli-service@5.0.8_lodash@4.17.21_webpack-sources@3.2.3/node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js","webpack://VueFirewall/./www/templates/Firewall.vue?c7a7","webpack://VueFirewall/www/templates/Firewall.vue","webpack://VueFirewall/./www/templates/Firewall.vue?6878","webpack://VueFirewall/../../../.local/share/pnpm/global/5/.pnpm/vue-loader@15.11.1_css-loader@6.11.0_webpack@5.93.0__lodash@4.17.21_webpack@5.93.0/node_modules/vue-loader/lib/runtime/componentNormalizer.js","webpack://VueFirewall/./www/templates/Firewall.vue","webpack://VueFirewall/../../../.local/share/pnpm/global/5/.pnpm/@vue+cli-service@5.0.8_lodash@4.17.21_webpack-sources@3.2.3/node_modules/@vue/cli-service/lib/commands/build/entry-lib.js"],"sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"VueFirewall\"] = factory();\n\telse\n\t\troot[\"VueFirewall\"] = factory();\n})((typeof self !== 'undefined' ? self : this), () => {\nreturn ","// The require scope\nvar __webpack_require__ = {};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","__webpack_require__.p = \"\";","/* eslint-disable no-var */\n// This file is imported into lib/wc client bundles.\n\nif (typeof window !== 'undefined') {\n var currentScript = window.document.currentScript\n if (process.env.NEED_CURRENTSCRIPT_POLYFILL) {\n var getCurrentScript = require('@soda/get-current-script')\n currentScript = getCurrentScript()\n\n // for backward compatibility, because previously we directly included the polyfill\n if (!('currentScript' in document)) {\n Object.defineProperty(document, 'currentScript', { get: getCurrentScript })\n }\n }\n\n var src = currentScript && currentScript.src.match(/(.+\\/)[^/]+\\.js(\\?.*)?$/)\n if (src) {\n __webpack_public_path__ = src[1] // eslint-disable-line\n }\n}\n\n// Indicate to webpack that this file can be concatenated\nexport default null\n","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"shadow-md rounded-lg bg-white dark:bg-neutral-700 overflow-hidden mb-4\"},[_c('div',{staticClass:\"flex flex-row flex-auto items-center p-3 px-5 border-b-2 border-neutral-500/50 dark:border-neutral-600\"},[_c('div',{staticClass:\"flex-grow\"},[_c('p',{staticClass:\"text-2xl font-medium dark:text-neutral-200\"},[_vm._v(_vm._s(_vm.$t('fwFirewall')))])])]),_c('div',{staticClass:\"container p-2 flex flex-col md:items-center\"},[_c('table',{staticClass:\"border border-neutral-500/50 bg-gray-200/10 dark:text-neutral-200 md:w-[75%] mb-4\"},[_c('thead',[_c('tr',[_c('th',{staticClass:\"border border-neutral-500/50 text-start p-1\"},[_vm._v(_vm._s(_vm.$t('fwInterface')))]),_c('th',{staticClass:\"border border-neutral-500/50 text-start p-1\"},[_vm._v(_vm._s(_vm.$t('fwIpv4')))]),_c('th',{staticClass:\"border border-neutral-500/50 text-start p-1\"},[_vm._v(_vm._s(_vm.$t('fwIpv6')))])])]),_c('tbody',_vm._l((_vm.interfaces),function(iface,index){return _c('tr',{key:index},[_c('td',{staticClass:\"border border-neutral-500/50 p-1\"},[_vm._v(_vm._s(iface.name))]),_c('td',{staticClass:\"border border-neutral-500/50 p-1\"},[_vm._v(_vm._s(iface.ipv4))]),_c('td',{staticClass:\"border border-neutral-500/50 p-1\"},[_vm._v(_vm._s(iface.ipv6))])])}),0)]),_c('form',{attrs:{\"id\":\"fw\"},on:{\"submit\":_vm.addRule}}),_c('div',{staticClass:\"overflow-x-auto\"},[_c('table',{staticClass:\"dark:text-neutral-200 border-t-2 border-collapse dark:border-neutral-200 p-2\"},[_c('thead',{staticClass:\"bg-gray-200 dark:bg-neutral-600\"},[_c('tr',[_c('th',{staticClass:\"border dark:border-neutral-200 p-1\"},[_vm._v(_vm._s(_vm.$t('fwAction')))]),_c('th',{staticClass:\"border dark:border-neutral-200 p-1\"},[_vm._v(_vm._s(_vm.$t('fwSource')))]),_c('th',{staticClass:\"border dark:border-neutral-200 p-1\"},[_vm._v(_vm._s(_vm.$t('fwDestination')))]),_c('th',{staticClass:\"border dark:border-neutral-200 p-1\"},[_vm._v(_vm._s(_vm.$t('fwProtocol')))]),_c('th',{staticClass:\"border dark:border-neutral-200 p-1\"},[_vm._v(_vm._s(_vm.$t('fwTarget')))])])]),_c('tbody',{staticClass:\"text-center\"},[_vm._l((_vm.rules),function(rule,index){return _c('tr',{key:index},[_c('td',{staticClass:\"border border-neutral-500/50 p-1 hover:bg-red-800/50 transition\"},[_c('button',{attrs:{\"type\":\"button\"},on:{\"click\":function($event){return _vm.deleteRule(rule.num)}}},[_c('svg',{staticClass:\"size-6\",attrs:{\"xmlns\":\"http://www.w3.org/2000/svg\",\"fill\":\"none\",\"viewBox\":\"0 0 24 24\",\"stroke-width\":\"1.5\",\"stroke\":\"currentColor\"}},[_c('path',{attrs:{\"stroke-linecap\":\"round\",\"stroke-linejoin\":\"round\",\"d\":\"m14.74 9-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 0 1-2.244 2.077H8.084a2.25 2.25 0 0 1-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 0 0-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 0 1 3.478-.397m7.5 0v-.916c0-1.18-.91-2.164-2.09-2.201a51.964 51.964 0 0 0-3.32 0c-1.18.037-2.09 1.022-2.09 2.201v.916m7.5 0a48.667 48.667 0 0 0-7.5 0\"}})])])]),_c('td',{staticClass:\"border border-neutral-500/50 p-1\"},[_vm._v(_vm._s(rule.source))]),_c('td',{staticClass:\"border border-neutral-500/50 p-1\"},[_vm._v(_vm._s(rule.destination))]),_c('td',{staticClass:\"border border-neutral-500/50 p-1\"},[_vm._v(_vm._s(rule.protocol))]),_c('td',{staticClass:\"border border-neutral-500/50 p-1\"},[_vm._v(_vm._s(rule.target))])])}),_c('tr',[_c('td',{staticClass:\"border border-neutral-500/50 p-1 hover:bg-green-800/50 transition\"},[_c('button',{attrs:{\"form\":\"fw\",\"type\":\"submit\"}},[_c('svg',{staticClass:\"size-6\",attrs:{\"xmlns\":\"http://www.w3.org/2000/svg\",\"fill\":\"none\",\"viewBox\":\"0 0 24 24\",\"stroke-width\":\"1.5\",\"stroke\":\"currentColor\"}},[_c('path',{attrs:{\"stroke-linecap\":\"round\",\"stroke-linejoin\":\"round\",\"d\":\"M12 4.5v15m7.5-7.5h-15\"}})])])]),_c('td',{staticClass:\"border border-neutral-500/50\"},[_c('input',{directives:[{name:\"model\",rawName:\"v-model\",value:(_vm.newRule.source),expression:\"newRule.source\"}],staticClass:\"outline-none bg-transparent text-center\",attrs:{\"form\":\"fw\",\"type\":\"text\",\"name\":\"source\"},domProps:{\"value\":(_vm.newRule.source)},on:{\"input\":function($event){if($event.target.composing){ return; }_vm.$set(_vm.newRule, \"source\", $event.target.value)}}})]),_c('td',{staticClass:\"border border-neutral-500/50\"},[_c('input',{directives:[{name:\"model\",rawName:\"v-model\",value:(_vm.newRule.destination),expression:\"newRule.destination\"}],staticClass:\"outline-none bg-transparent text-center\",attrs:{\"form\":\"fw\",\"type\":\"text\",\"name\":\"destination\"},domProps:{\"value\":(_vm.newRule.destination)},on:{\"input\":function($event){if($event.target.composing){ return; }_vm.$set(_vm.newRule, \"destination\", $event.target.value)}}})]),_c('td',{staticClass:\"border border-neutral-500/50\"},[_c('select',{staticClass:\"bg-transparent\",attrs:{\"form\":\"fw\",\"name\":\"protocol\"},on:{\"change\":function (e) { return _vm.newRule.protocol = e.target.value; }}},[_c('option',{staticClass:\"dark:text-white dark:bg-neutral-700\",attrs:{\"selected\":\"\",\"value\":\"TCP\"}},[_vm._v(\"TCP\")]),_c('option',{staticClass:\"dark:text-white dark:bg-neutral-700\",attrs:{\"value\":\"UDP\"}},[_vm._v(\"UDP\")])])]),_c('td',{staticClass:\"border border-neutral-500/50 p-1\"},[_c('select',{directives:[{name:\"model\",rawName:\"v-model\",value:(_vm.newRule.target),expression:\"newRule.target\"}],staticClass:\"bg-transparent\",attrs:{\"form\":\"fw\",\"name\":\"target\"},on:{\"change\":function($event){var $$selectedVal = Array.prototype.filter.call($event.target.options,function(o){return o.selected}).map(function(o){var val = \"_value\" in o ? o._value : o.value;return val}); _vm.$set(_vm.newRule, \"target\", $event.target.multiple ? $$selectedVal : $$selectedVal[0])}}},[_c('option',{staticClass:\"dark:text-white dark:bg-neutral-700\",attrs:{\"value\":\"ACCEPT\"}},[_vm._v(\"ALLOW\")]),_c('option',{staticClass:\"dark:text-white dark:bg-neutral-700\",attrs:{\"selected\":\"\",\"value\":\"DROP\"}},[_vm._v(\"BLOCK\")])])])])],2)])])])])}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","\n\n\n\n\n \n
\n
\n
{{ $t('fwFirewall') }}
\n
\n
\n\n
\n
\n \n \n | {{ $t('fwInterface') }} | \n {{ $t('fwIpv4') }} | \n {{ $t('fwIpv6') }} | \n
\n \n \n \n | {{ iface.name }} | \n {{ iface.ipv4 }} | \n {{ iface.ipv6 }} | \n
\n \n
\n\n
\n\n
\n
\n
\n\n","import mod from \"-!../../../../../.local/share/pnpm/global/5/.pnpm/vue-loader@15.11.1_css-loader@6.11.0_webpack@5.93.0__lodash@4.17.21_webpack@5.93.0/node_modules/vue-loader/lib/index.js??vue-loader-options!./Firewall.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../../.local/share/pnpm/global/5/.pnpm/vue-loader@15.11.1_css-loader@6.11.0_webpack@5.93.0__lodash@4.17.21_webpack@5.93.0/node_modules/vue-loader/lib/index.js??vue-loader-options!./Firewall.vue?vue&type=script&lang=js\"","/* globals __VUE_SSR_CONTEXT__ */\n\n// IMPORTANT: Do NOT use ES2015 features in this file (except for modules).\n// This module is a runtime utility for cleaner component module output and will\n// be included in the final webpack user bundle.\n\nexport default function normalizeComponent(\n scriptExports,\n render,\n staticRenderFns,\n functionalTemplate,\n injectStyles,\n scopeId,\n moduleIdentifier /* server only */,\n shadowMode /* vue-cli only */\n) {\n // Vue.extend constructor export interop\n var options =\n typeof scriptExports === 'function' ? scriptExports.options : scriptExports\n\n // render functions\n if (render) {\n options.render = render\n options.staticRenderFns = staticRenderFns\n options._compiled = true\n }\n\n // functional template\n if (functionalTemplate) {\n options.functional = true\n }\n\n // scopedId\n if (scopeId) {\n options._scopeId = 'data-v-' + scopeId\n }\n\n var hook\n if (moduleIdentifier) {\n // server build\n hook = function (context) {\n // 2.3 injection\n context =\n context || // cached call\n (this.$vnode && this.$vnode.ssrContext) || // stateful\n (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext) // functional\n // 2.2 with runInNewContext: true\n if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {\n context = __VUE_SSR_CONTEXT__\n }\n // inject component styles\n if (injectStyles) {\n injectStyles.call(this, context)\n }\n // register component module identifier for async chunk inferrence\n if (context && context._registeredComponents) {\n context._registeredComponents.add(moduleIdentifier)\n }\n }\n // used by ssr in case component is cached and beforeCreate\n // never gets called\n options._ssrRegister = hook\n } else if (injectStyles) {\n hook = shadowMode\n ? function () {\n injectStyles.call(\n this,\n (options.functional ? this.parent : this).$root.$options.shadowRoot\n )\n }\n : injectStyles\n }\n\n if (hook) {\n if (options.functional) {\n // for template-only hot-reload because in that case the render fn doesn't\n // go through the normalizer\n options._injectStyles = hook\n // register for functional component in vue file\n var originalRender = options.render\n options.render = function renderWithStyleInjection(h, context) {\n hook.call(context)\n return originalRender(h, context)\n }\n } else {\n // inject component registration as beforeCreate hook\n var existing = options.beforeCreate\n options.beforeCreate = existing ? [].concat(existing, hook) : [hook]\n }\n }\n\n return {\n exports: scriptExports,\n options: options\n }\n}\n","import { render, staticRenderFns } from \"./Firewall.vue?vue&type=template&id=602b3624\"\nimport script from \"./Firewall.vue?vue&type=script&lang=js\"\nexport * from \"./Firewall.vue?vue&type=script&lang=js\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../../.local/share/pnpm/global/5/.pnpm/vue-loader@15.11.1_css-loader@6.11.0_webpack@5.93.0__lodash@4.17.21_webpack@5.93.0/node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","import './setPublicPath'\nimport mod from '~entry'\nexport default mod\nexport * from '~entry'\n"],"names":["root","factory","exports","module","define","amd","self","this","__webpack_require__","d","definition","key","o","Object","defineProperty","enumerable","get","obj","prop","prototype","hasOwnProperty","call","p","window","currentScript","document","src","match","render","_vm","_h","$createElement","_c","_self","staticClass","_v","_s","$t","_l","iface","index","name","ipv4","ipv6","attrs","on","addRule","rule","$event","deleteRule","num","source","destination","protocol","target","directives","rawName","value","newRule","expression","domProps","composing","$set","e","$$selectedVal","Array","filter","options","selected","map","val","_value","multiple","staticRenderFns","data","interfaces","rules","methods","getInterfaces","api","then","catch","err","alert","message","toString","getRules","preventDefault","finally","mounted","API","normalizeComponent","scriptExports","functionalTemplate","injectStyles","scopeId","moduleIdentifier","shadowMode","hook","_compiled","functional","_scopeId","context","$vnode","ssrContext","parent","__VUE_SSR_CONTEXT__","_registeredComponents","add","_ssrRegister","$root","$options","shadowRoot","_injectStyles","originalRender","h","existing","beforeCreate","concat","component"],"sourceRoot":""}
\ No newline at end of file
+{"version":3,"file":"vue-firewall.umd.min.js","mappings":"CAAA,SAA2CA,EAAMC,GAC1B,kBAAZC,SAA0C,kBAAXC,OACxCA,OAAOD,QAAUD,IACQ,oBAAXG,QAAyBA,OAAOC,IAC9CD,OAAO,GAAIH,GACe,kBAAZC,QACdA,QAAQ,eAAiBD,IAEzBD,EAAK,eAAiBC,GACvB,EATD,CASoB,qBAATK,KAAuBA,KAAOC,MAAO,I,mBCRhD,IAAIC,EAAsB,CAAC,E,MCA3BA,EAAoBC,EAAI,CAACP,EAASQ,KACjC,IAAI,IAAIC,KAAOD,EACXF,EAAoBI,EAAEF,EAAYC,KAASH,EAAoBI,EAAEV,EAASS,IAC5EE,OAAOC,eAAeZ,EAASS,EAAK,CAAEI,YAAY,EAAMC,IAAKN,EAAWC,IAE1E,C,WCNDH,EAAoBI,EAAI,CAACK,EAAKC,IAAUL,OAAOM,UAAUC,eAAeC,KAAKJ,EAAKC,E,WCAlFV,EAAoBc,EAAI,E,cCGxB,G,uBAAsB,qBAAXC,OAAwB,CACjC,IAAIC,EAAgBD,OAAOE,SAASD,cAWhCE,EAAMF,GAAiBA,EAAcE,IAAIC,MAAM,2BAC/CD,IACF,IAA0BA,EAAI,GAElC,CCnBA,IAAIE,EAAS,WAAa,IAAIC,EAAItB,KAASuB,EAAGD,EAAIE,eAAmBC,EAAGH,EAAII,MAAMD,IAAIF,EAAG,OAAOE,EAAG,MAAM,CAACE,YAAY,0EAA0E,CAACF,EAAG,MAAM,CAACE,YAAY,0GAA0G,CAACF,EAAG,MAAM,CAACE,YAAY,aAAa,CAACF,EAAG,IAAI,CAACE,YAAY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,EAAUI,qBAGRZ,GACFA,EAAa1E,KAAKd,KAAMgG,GAGtBA,GAAWA,EAAQK,uBACrBL,EAAQK,sBAAsBC,IAAIZ,EAEtC,EAGA7B,EAAQ0C,aAAeX,GACdJ,IACTI,EAAOD,EACH,WACEH,EAAa1E,KACXd,MACC6D,EAAQiC,WAAa9F,KAAKmG,OAASnG,MAAMwG,MAAMC,SAASC,WAE7D,EACAlB,GAGFI,EACF,GAAI/B,EAAQiC,WAAY,CAGtBjC,EAAQ8C,cAAgBf,EAExB,IAAIgB,EAAiB/C,EAAQxC,OAC7BwC,EAAQxC,OAAS,SAAkCwF,EAAGb,GAEpD,OADAJ,EAAK9E,KAAKkF,GACHY,EAAeC,EAAGb,EAC3B,CACF,KAAO,CAEL,IAAIc,EAAWjD,EAAQkD,aACvBlD,EAAQkD,aAAeD,EAAW,GAAGE,OAAOF,EAAUlB,GAAQ,CAACA,EACjE,CAGF,MAAO,CACLjG,QAAS2F,EACTzB,QAASA,EAEb,CCxFA,IAAIoD,EAAY,EACd,EACA5F,EACA8C,GACA,EACA,KACA,KACA,MAIF,QAAe8C,EAAiB,QChBhC,I","sources":["webpack://VueFirewall/webpack/universalModuleDefinition","webpack://VueFirewall/webpack/bootstrap","webpack://VueFirewall/webpack/runtime/define property getters","webpack://VueFirewall/webpack/runtime/hasOwnProperty shorthand","webpack://VueFirewall/webpack/runtime/publicPath","webpack://VueFirewall/../../../.local/share/pnpm/global/5/.pnpm/@vue+cli-service@5.0.8_lodash@4.17.21_webpack-sources@3.2.3/node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js","webpack://VueFirewall/./www/templates/Firewall.vue?aeb9","webpack://VueFirewall/www/templates/Firewall.vue","webpack://VueFirewall/./www/templates/Firewall.vue?6878","webpack://VueFirewall/../../../.local/share/pnpm/global/5/.pnpm/vue-loader@15.11.1_css-loader@6.11.0_webpack@5.93.0__lodash@4.17.21_webpack@5.93.0/node_modules/vue-loader/lib/runtime/componentNormalizer.js","webpack://VueFirewall/./www/templates/Firewall.vue","webpack://VueFirewall/../../../.local/share/pnpm/global/5/.pnpm/@vue+cli-service@5.0.8_lodash@4.17.21_webpack-sources@3.2.3/node_modules/@vue/cli-service/lib/commands/build/entry-lib.js"],"sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"VueFirewall\"] = factory();\n\telse\n\t\troot[\"VueFirewall\"] = factory();\n})((typeof self !== 'undefined' ? self : this), () => {\nreturn ","// The require scope\nvar __webpack_require__ = {};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","__webpack_require__.p = \"\";","/* eslint-disable no-var */\n// This file is imported into lib/wc client bundles.\n\nif (typeof window !== 'undefined') {\n var currentScript = window.document.currentScript\n if (process.env.NEED_CURRENTSCRIPT_POLYFILL) {\n var getCurrentScript = require('@soda/get-current-script')\n currentScript = getCurrentScript()\n\n // for backward compatibility, because previously we directly included the polyfill\n if (!('currentScript' in document)) {\n Object.defineProperty(document, 'currentScript', { get: getCurrentScript })\n }\n }\n\n var src = currentScript && currentScript.src.match(/(.+\\/)[^/]+\\.js(\\?.*)?$/)\n if (src) {\n __webpack_public_path__ = src[1] // eslint-disable-line\n }\n}\n\n// Indicate to webpack that this file can be concatenated\nexport default null\n","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"shadow-md rounded-lg bg-white dark:bg-neutral-700 overflow-hidden mb-4\"},[_c('div',{staticClass:\"flex flex-row flex-auto items-center p-3 px-5 border-b-2 border-neutral-500/50 dark:border-neutral-600\"},[_c('div',{staticClass:\"flex-grow\"},[_c('p',{staticClass:\"text-2xl font-medium dark:text-neutral-200\"},[_vm._v(_vm._s(_vm.$t('fwFirewall')))])])]),_c('div',{staticClass:\"container p-2 flex flex-col md:items-center\"},[_c('table',{staticClass:\"border border-neutral-500/50 bg-gray-200/10 dark:text-neutral-200 md:w-[75%] mb-4\"},[_c('thead',[_c('tr',[_c('th',{staticClass:\"border border-neutral-500/50 text-start p-1\"},[_vm._v(_vm._s(_vm.$t('fwInterface')))]),_c('th',{staticClass:\"border border-neutral-500/50 text-start p-1\"},[_vm._v(_vm._s(_vm.$t('fwIpv4')))]),_c('th',{staticClass:\"border border-neutral-500/50 text-start p-1\"},[_vm._v(_vm._s(_vm.$t('fwIpv6')))])])]),_c('tbody',_vm._l((_vm.interfaces),function(iface,index){return _c('tr',{key:index},[_c('td',{staticClass:\"border border-neutral-500/50 p-1\"},[_vm._v(_vm._s(iface.name))]),_c('td',{staticClass:\"border border-neutral-500/50 p-1\"},[_vm._v(_vm._s(iface.ipv4))]),_c('td',{staticClass:\"border border-neutral-500/50 p-1\"},[_vm._v(_vm._s(iface.ipv6))])])}),0)]),_c('form',{attrs:{\"id\":\"fw\"},on:{\"submit\":_vm.addRule}}),_c('div',{staticClass:\"overflow-x-auto\"},[_c('table',{staticClass:\"dark:text-neutral-200 border-t-2 border-collapse dark:border-neutral-200 p-2\"},[_c('thead',{staticClass:\"bg-gray-200 dark:bg-neutral-600\"},[_c('tr',[_c('th',{staticClass:\"border dark:border-neutral-200 p-1\"},[_vm._v(_vm._s(_vm.$t('fwAction')))]),_c('th',{staticClass:\"border dark:border-neutral-200 p-1\"},[_vm._v(_vm._s(_vm.$t('fwSource')))]),_c('th',{staticClass:\"border dark:border-neutral-200 p-1\"},[_vm._v(_vm._s(_vm.$t('fwDestination')))]),_c('th',{staticClass:\"border dark:border-neutral-200 p-1\"},[_vm._v(_vm._s(_vm.$t('fwProtocol')))]),_c('th',{staticClass:\"border dark:border-neutral-200 p-1\"},[_vm._v(_vm._s(_vm.$t('fwTarget')))])])]),_c('tbody',{staticClass:\"text-center\"},[_vm._l((_vm.rules),function(rule,index){return _c('tr',{key:index,class:[rule.target == 'BLOCK' ? 'bg-red-500/50' : '']},[_c('td',{staticClass:\"border border-neutral-500/50 p-1 hover:bg-red-800/50 transition\"},[_c('button',{attrs:{\"type\":\"button\"},on:{\"click\":function($event){return _vm.deleteRule(rule.num)}}},[_c('svg',{staticClass:\"size-6\",attrs:{\"xmlns\":\"http://www.w3.org/2000/svg\",\"fill\":\"none\",\"viewBox\":\"0 0 24 24\",\"stroke-width\":\"1.5\",\"stroke\":\"currentColor\"}},[_c('path',{attrs:{\"stroke-linecap\":\"round\",\"stroke-linejoin\":\"round\",\"d\":\"m14.74 9-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 0 1-2.244 2.077H8.084a2.25 2.25 0 0 1-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 0 0-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 0 1 3.478-.397m7.5 0v-.916c0-1.18-.91-2.164-2.09-2.201a51.964 51.964 0 0 0-3.32 0c-1.18.037-2.09 1.022-2.09 2.201v.916m7.5 0a48.667 48.667 0 0 0-7.5 0\"}})])])]),_c('td',{staticClass:\"border border-neutral-500/50 p-1\"},[_vm._v(_vm._s(rule.source))]),_c('td',{staticClass:\"border border-neutral-500/50 p-1\"},[_vm._v(_vm._s(rule.destination))]),_c('td',{staticClass:\"border border-neutral-500/50 p-1\"},[_vm._v(_vm._s(rule.protocol))]),_c('td',{staticClass:\"border border-neutral-500/50 p-1\"},[_vm._v(_vm._s(rule.target))])])}),_c('tr',[_c('td',{staticClass:\"border border-neutral-500/50 p-1 hover:bg-green-800/50 transition\"},[_c('button',{attrs:{\"form\":\"fw\",\"type\":\"submit\"}},[_c('svg',{staticClass:\"size-6\",attrs:{\"xmlns\":\"http://www.w3.org/2000/svg\",\"fill\":\"none\",\"viewBox\":\"0 0 24 24\",\"stroke-width\":\"1.5\",\"stroke\":\"currentColor\"}},[_c('path',{attrs:{\"stroke-linecap\":\"round\",\"stroke-linejoin\":\"round\",\"d\":\"M12 4.5v15m7.5-7.5h-15\"}})])])]),_c('td',{staticClass:\"border border-neutral-500/50\"},[_c('input',{directives:[{name:\"model\",rawName:\"v-model\",value:(_vm.newRule.source),expression:\"newRule.source\"}],staticClass:\"outline-none bg-transparent text-center\",attrs:{\"form\":\"fw\",\"type\":\"text\",\"name\":\"source\"},domProps:{\"value\":(_vm.newRule.source)},on:{\"input\":function($event){if($event.target.composing){ return; }_vm.$set(_vm.newRule, \"source\", $event.target.value)}}})]),_c('td',{staticClass:\"border border-neutral-500/50\"},[_c('input',{directives:[{name:\"model\",rawName:\"v-model\",value:(_vm.newRule.destination),expression:\"newRule.destination\"}],staticClass:\"outline-none bg-transparent text-center\",attrs:{\"form\":\"fw\",\"type\":\"text\",\"name\":\"destination\"},domProps:{\"value\":(_vm.newRule.destination)},on:{\"input\":function($event){if($event.target.composing){ return; }_vm.$set(_vm.newRule, \"destination\", $event.target.value)}}})]),_c('td',{staticClass:\"border border-neutral-500/50\"},[_c('select',{staticClass:\"bg-transparent\",attrs:{\"form\":\"fw\",\"name\":\"protocol\"},on:{\"change\":function (e) { return _vm.newRule.protocol = e.target.value; }}},[_c('option',{staticClass:\"dark:text-white dark:bg-neutral-700\",attrs:{\"selected\":\"\",\"value\":\"TCP\"}},[_vm._v(\"TCP\")]),_c('option',{staticClass:\"dark:text-white dark:bg-neutral-700\",attrs:{\"value\":\"UDP\"}},[_vm._v(\"UDP\")])])]),_c('td',{staticClass:\"border border-neutral-500/50 p-1\"},[_c('select',{directives:[{name:\"model\",rawName:\"v-model\",value:(_vm.newRule.target),expression:\"newRule.target\"}],staticClass:\"bg-transparent\",attrs:{\"form\":\"fw\",\"name\":\"target\"},on:{\"change\":function($event){var $$selectedVal = Array.prototype.filter.call($event.target.options,function(o){return o.selected}).map(function(o){var val = \"_value\" in o ? o._value : o.value;return val}); _vm.$set(_vm.newRule, \"target\", $event.target.multiple ? $$selectedVal : $$selectedVal[0])}}},[_c('option',{staticClass:\"dark:text-white dark:bg-neutral-700\",attrs:{\"value\":\"ACCEPT\"}},[_vm._v(\"ALLOW\")]),_c('option',{staticClass:\"dark:text-white dark:bg-neutral-700\",attrs:{\"selected\":\"\",\"value\":\"DROP\"}},[_vm._v(\"BLOCK\")])])])])],2)])])])])}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","\n\n\n\n\n \n
\n
\n
{{ $t('fwFirewall') }}
\n
\n
\n\n
\n
\n \n \n | {{ $t('fwInterface') }} | \n {{ $t('fwIpv4') }} | \n {{ $t('fwIpv6') }} | \n
\n \n \n \n | {{ iface.name }} | \n {{ iface.ipv4 }} | \n {{ iface.ipv6 }} | \n
\n \n
\n\n
\n\n
\n
\n
\n\n","import mod from \"-!../../../../../.local/share/pnpm/global/5/.pnpm/vue-loader@15.11.1_css-loader@6.11.0_webpack@5.93.0__lodash@4.17.21_webpack@5.93.0/node_modules/vue-loader/lib/index.js??vue-loader-options!./Firewall.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../../.local/share/pnpm/global/5/.pnpm/vue-loader@15.11.1_css-loader@6.11.0_webpack@5.93.0__lodash@4.17.21_webpack@5.93.0/node_modules/vue-loader/lib/index.js??vue-loader-options!./Firewall.vue?vue&type=script&lang=js\"","/* globals __VUE_SSR_CONTEXT__ */\n\n// IMPORTANT: Do NOT use ES2015 features in this file (except for modules).\n// This module is a runtime utility for cleaner component module output and will\n// be included in the final webpack user bundle.\n\nexport default function normalizeComponent(\n scriptExports,\n render,\n staticRenderFns,\n functionalTemplate,\n injectStyles,\n scopeId,\n moduleIdentifier /* server only */,\n shadowMode /* vue-cli only */\n) {\n // Vue.extend constructor export interop\n var options =\n typeof scriptExports === 'function' ? scriptExports.options : scriptExports\n\n // render functions\n if (render) {\n options.render = render\n options.staticRenderFns = staticRenderFns\n options._compiled = true\n }\n\n // functional template\n if (functionalTemplate) {\n options.functional = true\n }\n\n // scopedId\n if (scopeId) {\n options._scopeId = 'data-v-' + scopeId\n }\n\n var hook\n if (moduleIdentifier) {\n // server build\n hook = function (context) {\n // 2.3 injection\n context =\n context || // cached call\n (this.$vnode && this.$vnode.ssrContext) || // stateful\n (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext) // functional\n // 2.2 with runInNewContext: true\n if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {\n context = __VUE_SSR_CONTEXT__\n }\n // inject component styles\n if (injectStyles) {\n injectStyles.call(this, context)\n }\n // register component module identifier for async chunk inferrence\n if (context && context._registeredComponents) {\n context._registeredComponents.add(moduleIdentifier)\n }\n }\n // used by ssr in case component is cached and beforeCreate\n // never gets called\n options._ssrRegister = hook\n } else if (injectStyles) {\n hook = shadowMode\n ? function () {\n injectStyles.call(\n this,\n (options.functional ? this.parent : this).$root.$options.shadowRoot\n )\n }\n : injectStyles\n }\n\n if (hook) {\n if (options.functional) {\n // for template-only hot-reload because in that case the render fn doesn't\n // go through the normalizer\n options._injectStyles = hook\n // register for functional component in vue file\n var originalRender = options.render\n options.render = function renderWithStyleInjection(h, context) {\n hook.call(context)\n return originalRender(h, context)\n }\n } else {\n // inject component registration as beforeCreate hook\n var existing = options.beforeCreate\n options.beforeCreate = existing ? [].concat(existing, hook) : [hook]\n }\n }\n\n return {\n exports: scriptExports,\n options: options\n }\n}\n","import { render, staticRenderFns } from \"./Firewall.vue?vue&type=template&id=245088af\"\nimport script from \"./Firewall.vue?vue&type=script&lang=js\"\nexport * from \"./Firewall.vue?vue&type=script&lang=js\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../../.local/share/pnpm/global/5/.pnpm/vue-loader@15.11.1_css-loader@6.11.0_webpack@5.93.0__lodash@4.17.21_webpack@5.93.0/node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","import './setPublicPath'\nimport mod from '~entry'\nexport default mod\nexport * from '~entry'\n"],"names":["root","factory","exports","module","define","amd","self","this","__webpack_require__","d","definition","key","o","Object","defineProperty","enumerable","get","obj","prop","prototype","hasOwnProperty","call","p","window","currentScript","document","src","match","render","_vm","_h","$createElement","_c","_self","staticClass","_v","_s","$t","_l","iface","index","name","ipv4","ipv6","attrs","on","addRule","rule","class","target","$event","deleteRule","num","source","destination","protocol","directives","rawName","value","newRule","expression","domProps","composing","$set","e","$$selectedVal","Array","filter","options","selected","map","val","_value","multiple","staticRenderFns","data","interfaces","rules","methods","getInterfaces","api","then","catch","err","alert","message","toString","getRules","preventDefault","finally","mounted","API","normalizeComponent","scriptExports","functionalTemplate","injectStyles","scopeId","moduleIdentifier","shadowMode","hook","_compiled","functional","_scopeId","context","$vnode","ssrContext","parent","__VUE_SSR_CONTEXT__","_registeredComponents","add","_ssrRegister","$root","$options","shadowRoot","_injectStyles","originalRender","h","existing","beforeCreate","concat","component"],"sourceRoot":""}
\ No newline at end of file
diff --git a/src/www/templates/Firewall.vue b/src/www/templates/Firewall.vue
index 17df4aba..50397f4b 100644
--- a/src/www/templates/Firewall.vue
+++ b/src/www/templates/Firewall.vue
@@ -7,8 +7,8 @@ export default {
let interfaces = [];
let rules = [];
let newRule = {
- source: '*',
- destination: '*',
+ source: '',
+ destination: '',
protocol: 'TCP',
target: 'DROP',
};
@@ -37,8 +37,8 @@ export default {
const { source, destination, protocol, target } = this.newRule;
this.api.addRule({ source, destination, protocol, target }).then(() => {
this.newRule = {
- source: '*',
- destination: '*',
+ source: '',
+ destination: '',
protocol: 'TCP',
target: 'DROP',
};
@@ -104,7 +104,7 @@ export default {
-
+
|
|