aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Auvolat <alex@adnab.me>2023-04-20 14:29:38 +0200
committerAlex Auvolat <alex@adnab.me>2023-04-20 14:29:38 +0200
commitd27173a2b7ada8d0df9506ce4beb1ba9dae94950 (patch)
tree6f5659d7254b8997083ab3e068f2ac743049fb01
parent48da5b61acf9edd582be5cecfdae58f63bd4527e (diff)
downloaddiplonat-d27173a2b7ada8d0df9506ce4beb1ba9dae94950.tar.gz
diplonat-d27173a2b7ada8d0df9506ce4beb1ba9dae94950.zip
debug
-rw-r--r--src/fw.rs5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/fw.rs b/src/fw.rs
index 88aaa86..abb6e20 100644
--- a/src/fw.rs
+++ b/src/fw.rs
@@ -54,6 +54,7 @@ pub fn get_opened_ports(ipt: &iptables::IPTables) -> Result<messages::PublicExpo
let re = Regex::new(r"\-A.*? \-p (\w+).*\-\-dport (\d+).*?\-j ACCEPT")
.context("Regex matching open ports encountered an unexpected rule")?;
for i in list {
+ debug!("{} list DIPLONAT: got {}", ipt.cmd, i);
let caps = re.captures(&i);
match caps {
Some(c) => {
@@ -70,7 +71,9 @@ pub fn get_opened_ports(ipt: &iptables::IPTables) -> Result<messages::PublicExpo
error!("Unexpected rule found in DIPLONAT chain")
}
}
- _ => {}
+ _ => {
+ debug!("{} rule not parsed: {}", ipt.cmd, i);
+ }
}
}