From 5f737f07f2f3bc5b36cb9a6f0e60a05863320a0e Mon Sep 17 00:00:00 2001 From: * Date: Tue, 21 Apr 2026 22:54:30 -0400 Subject: [PATCH 1/2] Changed PATHs in all test files to work in termux su shell --- Backend/error.log | 25 ++ Backend/test/check_hotspot_status_test.bats | 2 +- ...bats => clear_internet_sessions_test.bats} | 2 +- Backend/test/clear_internet_sessions_test.sh | 2 +- ...s => delete_user_iptables_rules_test.bats} | 2 +- .../test/delete_user_iptables_rules_test.sh | 4 +- Backend/test/error.log | 14 + .../{testhotspot.sh => test/hotspot_test.sh} | 0 Backend/test/lifecycle_e2e_test.sh | 26 +- Backend/test/run.sh | 270 ++++++++++-------- ...re.bats => setup_infrastructure_test.bats} | 0 ...bats => shutdown_infrastructure_test.bats} | 0 Backend/test/smoke_test.sh | 12 +- .../test/start_captive_webserver_test.bats | 12 +- .../start_captive_webserver_test.sh} | 0 15 files changed, 223 insertions(+), 148 deletions(-) create mode 100644 Backend/error.log rename Backend/test/{test_clear_internet_sessions.bats => clear_internet_sessions_test.bats} (99%) rename Backend/test/{test_delete_user_iptables_rules.bats => delete_user_iptables_rules_test.bats} (99%) create mode 100644 Backend/test/error.log rename Backend/{testhotspot.sh => test/hotspot_test.sh} (100%) rename Backend/test/{test_setup_infrastructure.bats => setup_infrastructure_test.bats} (100%) rename Backend/test/{test_shutdown_infrastructure.bats => shutdown_infrastructure_test.bats} (100%) rename Backend/{test_start_captive_webserver.sh => test/start_captive_webserver_test.sh} (100%) diff --git a/Backend/error.log b/Backend/error.log new file mode 100644 index 0000000..f317d38 --- /dev/null +++ b/Backend/error.log @@ -0,0 +1,25 @@ +iptables: No chain/target/match by that name. +2026-04-21T22:49:05-0400 Error in Cybercafe_setupFunctions.sh: Line 103 + +iptables: No chain/target/match by that name. +2026-04-21T22:49:05-0400 Error in Cybercafe_setupFunctions.sh: Line 109 + +iptables: No chain/target/match by that name. +2026-04-21T22:49:05-0400 Error in Cybercafe_setupFunctions.sh: Line 117 + +iptables: No chain/target/match by that name. +2026-04-21T22:49:05-0400 Error in Cybercafe_setupFunctions.sh: Line 127 + +iptables: No chain/target/match by that name. +2026-04-21T22:49:05-0400 Error in Cybercafe_setupFunctions.sh: Line 135 + +2026-04-21T22:49:06-0400 Captive portal webserver already running. +Tue Apr 21 22:49:10 EDT 2026 Error in Cybercafe_internetSessionFunctions.sh: Line 24 + +iptables: No chain/target/match by that name. +iptables: Bad rule (does a matching rule exist in that chain?). +iptables: Bad rule (does a matching rule exist in that chain?). +RTNETLINK answers: No such file or directory +2026-04-21T22:49:12-0400 Starting captive portal webserver... +2026-04-21T22:49:12-0400 Captive portal webserver started. +2026-04-21T22:49:13-0400 Captive portal webserver already running. diff --git a/Backend/test/check_hotspot_status_test.bats b/Backend/test/check_hotspot_status_test.bats index 7e58967..3ef20b8 100644 --- a/Backend/test/check_hotspot_status_test.bats +++ b/Backend/test/check_hotspot_status_test.bats @@ -1,4 +1,4 @@ -#!/usr/bin/env bats +#!/data/data/com.termux/files/usr/bin/bats # Automated testing for check_hotspot_status function, where test cases consider state tracking, transition detection # and timestamp guard logic. diff --git a/Backend/test/test_clear_internet_sessions.bats b/Backend/test/clear_internet_sessions_test.bats similarity index 99% rename from Backend/test/test_clear_internet_sessions.bats rename to Backend/test/clear_internet_sessions_test.bats index 8f31090..2b72f58 100644 --- a/Backend/test/test_clear_internet_sessions.bats +++ b/Backend/test/clear_internet_sessions_test.bats @@ -26,7 +26,7 @@ setup() { mkdir -p "$MOCKBIN" "$TMPDIR_TEST" cat > "$MOCKBIN/iptables" <<'EOT' -#!/usr/bin/env bash +#!/data/data/com.termux/files/usr/bin/bash echo "$*" >> "${MOCKBIN}/iptables.log" exit 0 EOT diff --git a/Backend/test/clear_internet_sessions_test.sh b/Backend/test/clear_internet_sessions_test.sh index ee7d3c4..f536114 100755 --- a/Backend/test/clear_internet_sessions_test.sh +++ b/Backend/test/clear_internet_sessions_test.sh @@ -38,7 +38,7 @@ setup_env() { # 2. Setup Mock iptables cat > "$MOCK_DIR/iptables" <<'EOT' -#!/usr/bin/env bash +#!/data/data/com.termux/files/usr/bin/bash echo "iptables $*" >> "${MOCK_DIR}/iptables_calls.log" exit 0 EOT diff --git a/Backend/test/test_delete_user_iptables_rules.bats b/Backend/test/delete_user_iptables_rules_test.bats similarity index 99% rename from Backend/test/test_delete_user_iptables_rules.bats rename to Backend/test/delete_user_iptables_rules_test.bats index 7e11ac1..932c3cd 100644 --- a/Backend/test/test_delete_user_iptables_rules.bats +++ b/Backend/test/delete_user_iptables_rules_test.bats @@ -14,7 +14,7 @@ setup() { mkdir -p "$MOCKBIN" cat > "$MOCKBIN/iptables" <<'EOT' -#!/usr/bin/env bash +#!/data/data/com.termux/files/usr/bin/bash echo "$*" >> "$MOCKBIN/iptables.log" if [[ "$*" == *"10.0.0.999"* ]]; then echo "iptables: Rule does not exist." >&2 diff --git a/Backend/test/delete_user_iptables_rules_test.sh b/Backend/test/delete_user_iptables_rules_test.sh index 0e864b1..be95454 100644 --- a/Backend/test/delete_user_iptables_rules_test.sh +++ b/Backend/test/delete_user_iptables_rules_test.sh @@ -13,7 +13,7 @@ setup_mocks() { # Create a mock iptables that logs all calls cat > "$MOCK_DIR/iptables" <<'EOT' -#!/usr/bin/env bash +#!/data/data/com.termux/files/usr/bin/bash # Log the call for verification echo "$*" >> "${MOCK_DIR}/iptables_calls.log" # Simulate behavior based on arguments @@ -190,4 +190,4 @@ main() { [[ $failed -eq 0 ]] && exit 0 || exit 1 } -main "$@" \ No newline at end of file +main "$@" diff --git a/Backend/test/error.log b/Backend/test/error.log new file mode 100644 index 0000000..52ead90 --- /dev/null +++ b/Backend/test/error.log @@ -0,0 +1,14 @@ +Tue Apr 21 22:49:55 EDT 2026 Error in Cybercafe_internetSessionFunctions.sh: Line 24 + +iptables v1.6.1: Couldn't find target `iptmon_tx' + +Try `iptables -h' or 'iptables --help' for more information. +iptables v1.6.1: Couldn't find target `iptmon_rx' + +Try `iptables -h' or 'iptables --help' for more information. +iptables: No chain/target/match by that name. +iptables: No chain/target/match by that name. +iptables: No chain/target/match by that name. +iptables: Bad rule (does a matching rule exist in that chain?). +iptables: Bad rule (does a matching rule exist in that chain?). +RTNETLINK answers: No such file or directory diff --git a/Backend/testhotspot.sh b/Backend/test/hotspot_test.sh similarity index 100% rename from Backend/testhotspot.sh rename to Backend/test/hotspot_test.sh diff --git a/Backend/test/lifecycle_e2e_test.sh b/Backend/test/lifecycle_e2e_test.sh index 3cb5c0f..8cc7fbc 100755 --- a/Backend/test/lifecycle_e2e_test.sh +++ b/Backend/test/lifecycle_e2e_test.sh @@ -1,11 +1,25 @@ #!/usr/bin/env bash set -e +SCRIPT_DIR="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" && pwd)" +ROOT_DIR="$(cd -- "$SCRIPT_DIR/.." && pwd)" +CYBERCAFE_SH="$ROOT_DIR/cybercafe.sh" + echo "=======================================" echo "CyberCafe Lifecycle E2E Test" echo "=======================================" -LOG_DIR="/tmp/cybercafe_logs" +if [[ -n "${TMPDIR:-}" && -d "${TMPDIR}" && -w "${TMPDIR}" ]]; then + TMP_BASE="$TMPDIR" +elif [[ -d /data/local/tmp && -w /data/local/tmp ]]; then + TMP_BASE="/data/local/tmp" +elif [[ -d /tmp && -w /tmp ]]; then + TMP_BASE="/tmp" +else + TMP_BASE="./.tmp" +fi + +LOG_DIR="$TMP_BASE/cybercafe_logs" mkdir -p "$LOG_DIR" # --------------------------------------- @@ -13,7 +27,7 @@ mkdir -p "$LOG_DIR" # --------------------------------------- echo "[STEP 1] Starting infrastructure..." -bash Backend/cybercafe.sh run > "$LOG_DIR/run.log" 2>&1 & +/data/data/com.termux/files/usr/bin/bash "$CYBERCAFE_SH" run > "$LOG_DIR/run.log" 2>&1 & CYBER_PID=$! sleep 3 @@ -33,7 +47,7 @@ fi # --------------------------------------- echo "[STEP 2] Checking system status..." -STATUS_OUTPUT=$(bash Backend/cybercafe.sh status 2>&1 || true) +STATUS_OUTPUT=$(/data/data/com.termux/files/usr/bin/bash "$CYBERCAFE_SH" status 2>&1 || true) echo "$STATUS_OUTPUT" if echo "$STATUS_OUTPUT" | grep -q "Status"; then @@ -47,7 +61,7 @@ fi # --------------------------------------- echo "[STEP 3] Validating system interaction..." -LIST_OUTPUT=$(bash Backend/cybercafe.sh list users 2>&1 || true) +LIST_OUTPUT=$(/data/data/com.termux/files/usr/bin/bash "$CYBERCAFE_SH" list users 2>&1 || true) echo "$LIST_OUTPUT" if echo "$LIST_OUTPUT" | grep -qi "no such table"; then @@ -63,7 +77,7 @@ fi # --------------------------------------- echo "[STEP 4] Shutting down infrastructure..." -bash Backend/cybercafe.sh shutdown > "$LOG_DIR/shutdown.log" 2>&1 || true +/data/data/com.termux/files/usr/bin/bash "$CYBERCAFE_SH" shutdown > "$LOG_DIR/shutdown.log" 2>&1 || true kill $CYBER_PID 2>/dev/null || true @@ -74,4 +88,4 @@ echo "[OK] Shutdown completed" # --------------------------------------- echo "=======================================" echo "Lifecycle test completed" -echo "=======================================" \ No newline at end of file +echo "=======================================" diff --git a/Backend/test/run.sh b/Backend/test/run.sh index 099bc24..50c2ef6 100755 --- a/Backend/test/run.sh +++ b/Backend/test/run.sh @@ -1,138 +1,160 @@ #!/usr/bin/env bash -set -Eeuo pipefail -# -E: The ERR trap is inherited by shell functions. -# -e: Exit immediately if a command exits with a non-zero status. -# -u: Treat unset variables as an error when substituting. -# -o pipefail: the return value of a pipeline is the status of - -# Resovle repo root (Backend/) regardless of where this script is called from -ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)" -TEST_DIR="$ROOT_DIR/test" - -usage() { - cat << 'EOF' -Usage: - test/run.sh Run all tests - test/run.sh path/to/test.sh Run a specific test script - test/run.sh --filter text Run tests whose path contains 'text' -EOF -} - -FILTER="" -SINGLE_FILE="" - -# Minimal argument parsing -while [[ $# -gt 0 ]]; do - case "$1" in - -h|--help) usage; exit 0;; - --filter) FILTER="${2:-}"; shift 2;; # next argument is the filter string - *) SINGLE_FILE="$1"; shift;; # treat any other arg as a file path - esac +set -uo pipefail + +# Resolve Backend/ and test/ regardless of current working directory +TEST_DIR="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" && pwd)" +ROOT_DIR="$(cd -- "$TEST_DIR/.." && pwd)" + +# Normalize PATH so the runner works on: +# - laptops +# - Android emulators with Termux +# - T95 boxes after entering `su` +for d in \ + /data/data/com.termux/files/usr/bin \ + /data/data/com.termux/files/bin \ + /system/bin \ + /system/xbin \ + /usr/bin \ + /bin +do + [[ -d "$d" ]] && PATH="$d:$PATH" done +export PATH -# Collect tests into an array safely (handles spaces in paths) -declare -a TESTS=() - -# If a file is specified, run only that file -if [[ -n "$SINGLE_FILE" ]]; then - # Allow file path relative to repo root or absolute - if [[ -f "$SINGLE_FILE" ]]; then - TESTS+=("$SINGLE_FILE") - elif [[ -f "$ROOT_DIR/$SINGLE_FILE" ]]; then - TESTS+=("$ROOT_DIR/$SINGLE_FILE") - else - echo "ERROR: Test file not found: $SINGLE_FILE" >&2 - exit 2 - fi +# Pick a writable temp base that works in su on Android +if [[ -d /tmp && -w /tmp ]]; then + TMP_BASE="/tmp" +elif [[ -d /data/local/tmp && -w /data/local/tmp ]]; then + TMP_BASE="/data/local/tmp" else - if [[ ! -d "$TEST_DIR" ]]; then - echo "ERROR: Test directory not found: $TEST_DIR" >&2 - exit 2 - fi - # Find tests named *_test.sh under Backend/test/ - # mapfile reads lines into an array without splitting on spaces - TESTS=() - TMP_FILE="$(mktemp)" - - { - find "$TEST_DIR" -type f -name "*_test.sh" - find "$TEST_DIR" -type f -name "*.bats" - } | sort > "$TMP_FILE" - - while IFS= read -r file; do - TESTS+=("$file") - done < "$TMP_FILE" - - rm -f "$TMP_FILE" + TMP_BASE="$ROOT_DIR/.tmp" + mkdir -p "$TMP_BASE" fi -# Optional filter (still safe: operates line-by-line) -if [[ -n "$FILTER" ]]; then - declare -a FILTERED=() - for t in "${TESTS[@]}"; do - if [[ "$t" == *"$FILTER"* ]]; then - FILTERED+=("$t") - fi - done - TESTS=("${FILTERED[@]}") -fi +# Bats uses TMPDIR as the base temp dir +export TMPDIR="$TMP_BASE" +export BATS_TMPDIR="$TMP_BASE" -if (( ${#TESTS[@]} == 0 )); then - echo "No tests found." - exit 0 +# Resolve tools after PATH normalization +BASH_BIN="$(command -v bash || true)" +BATS_BIN="$(command -v bats || true)" + +if [[ -z "$BASH_BIN" ]]; then + echo "ERROR: bash not found in PATH=$PATH" >&2 + exit 2 fi -# run a single test based on file type -run_one_test() { - local t="$1" - case "$t" in - *.bats) - if command -v bats >/dev/null 2>&1; then - bats "$t" - else - echo "ERROR: Found .bats test but bats is not installed:" >&2 - echo " ${t#"$ROOT_DIR"/}" >&2 - echo "Install bats or convert this test to *_test.sh" >&2 - return 2 - fi - ;; - *) - bash "$t" - ;; - esac +total_tests=0 +passed_tests=0 +failed_tests=0 +declare -a passed_names=() +declare -a failed_names=() + +run_one() { + local t="$1" + local rc=0 + + echo "==> $t" + + case "$t" in + *.bats) + if [[ -z "$BATS_BIN" ]]; then + echo "ERROR: bats not found in PATH=$PATH" >&2 + rc=2 + else + TMPDIR="$TMPDIR" "$BATS_BIN" "$t" || rc=$? + fi + ;; + *) + TMPDIR="$TMPDIR" "$BASH_BIN" "$t" || rc=$? + ;; + esac + + total_tests=$((total_tests + 1)) + + if [[ "$rc" -eq 0 ]]; then + passed_tests=$((passed_tests + 1)) + passed_names+=("$(basename "$t")") + echo "PASS: $(basename "$t")" + else + failed_tests=$((failed_tests + 1)) + failed_names+=("$(basename "$t")") + echo "FAIL: $(basename "$t") (exit $rc)" + fi + + echo } -pass=0 -fail=0 -failures=() - -echo "Running tests..." -echo "================" - -# Run each test script in its own Bash process -# Pass/fail is determined by the script's exit code (0=pass, non-0=fail) -for t in "${TESTS[@]}"; do - echo "Running test: $t" - if run_one_test "$t"; then - echo "PASS: ${t#"$ROOT_DIR"/}" - pass=$((pass + 1)) - else - rc=$? - echo "FAIL: ${t#"$ROOT_DIR"/} (exit=$rc)" - fail=$((fail + 1)) - failures+=("${t#"$ROOT_DIR"/}") - fi - echo "----------------" -done - -echo -echo "Summary: $pass passed, $fail failed." +print_summary() { + echo "====================" + echo "Test File Summary" + echo "====================" + echo "Total: $total_tests" + echo "Passed: $passed_tests" + echo "Failed: $failed_tests" + echo + + echo "Passed files:" + if [[ "${#passed_names[@]}" -eq 0 ]]; then + echo " (none)" + else + local name + for name in "${passed_names[@]}"; do + echo " - $name" + done + fi + echo + + echo "Failed files:" + if [[ "${#failed_names[@]}" -eq 0 ]]; then + echo " (none)" + else + local name + for name in "${failed_names[@]}"; do + echo " - $name" + done + fi +} -# If anything failed, exit non-zero so CI fails -if (( fail > 0 )); then - echo "Failed tests:" - for f in "${failures[@]}"; do - echo " - $f" +main() { + cd "$ROOT_DIR" + + local found=0 + local t + + if [[ "$#" -gt 0 ]]; then + for t in "$@"; do + if [[ -f "$t" ]]; then + found=1 + run_one "$t" + elif [[ -f "$TEST_DIR/$t" ]]; then + found=1 + run_one "$TEST_DIR/$t" + else + echo "ERROR: test file not found: $t" >&2 + failed_tests=$((failed_tests + 1)) + total_tests=$((total_tests + 1)) + failed_names+=("$t") + fi + done + else + for t in "$TEST_DIR"/*_test.bats "$TEST_DIR"/*_test.sh; do + [[ -e "$t" ]] || continue + found=1 + run_one "$t" done + fi + + if [[ "$found" -eq 0 ]]; then + echo "No test files found in $TEST_DIR" >&2 exit 1 -fi \ No newline at end of file + fi + + print_summary + + if [[ "$failed_tests" -ne 0 ]]; then + exit 1 + fi +} + +main "$@" diff --git a/Backend/test/test_setup_infrastructure.bats b/Backend/test/setup_infrastructure_test.bats similarity index 100% rename from Backend/test/test_setup_infrastructure.bats rename to Backend/test/setup_infrastructure_test.bats diff --git a/Backend/test/test_shutdown_infrastructure.bats b/Backend/test/shutdown_infrastructure_test.bats similarity index 100% rename from Backend/test/test_shutdown_infrastructure.bats rename to Backend/test/shutdown_infrastructure_test.bats diff --git a/Backend/test/smoke_test.sh b/Backend/test/smoke_test.sh index c728930..59d7efd 100644 --- a/Backend/test/smoke_test.sh +++ b/Backend/test/smoke_test.sh @@ -29,21 +29,21 @@ export PATH="$FAKEBIN:$PATH" # Create lightweight mocks so the test never touches real system state # The mock commands log what was called and what succeed cat > "$FAKEBIN/iptables" <<'EOF' -#!/usr/bin/env bash +#!/data/data/com.termux/files/usr/bin/bash echo "iptables $*" >> "$MOCK_CALL_LOG" exit 0 EOF chmod +x "$FAKEBIN/iptables" cat > "$FAKEBIN/tc" <<'EOF' -#!/usr/bin/env bash +#!/data/data/com.termux/files/usr/bin/bash echo "tc $*" >> "$MOCK_CALL_LOG" exit 0 EOF chmod +x "$FAKEBIN/tc" cat > "$FAKEBIN/ip" <<'EOF' -#!/usr/bin/env bash +#!/data/data/com.termux/files/usr/bin/bash echo "ip $*" >> "$MOCK_CALL_LOG" # Pretend interface exists so step 6 doesn't log "Device does not exist" exit 0 @@ -51,14 +51,14 @@ EOF chmod +x "$FAKEBIN/ip" cat > "$FAKEBIN/pkill" <<'EOF' -#!/usr/bin/env bash +#!/data/data/com.termux/files/usr/bin/bash echo "pkill $*" >> "$MOCK_CALL_LOG" exit 0 EOF chmod +x "$FAKEBIN/pkill" cat > "$FAKEBIN/ifconfig" <<'EOF' -#!/usr/bin/env bash +#!/data/data/com.termux/files/usr/bin/bash echo "ifconfig $*" >> "$MOCK_CALL_LOG" # Output that matches the grep/awk pipeline in shutdown_infrastructure echo "inet addr:192.168.1.50 Bcast:192.168.1.255 Mask:255.255.255.0" @@ -91,4 +91,4 @@ test_shutdown() { assert_contains "$calls" "ip link show wlan0" } -test_shutdown \ No newline at end of file +test_shutdown diff --git a/Backend/test/start_captive_webserver_test.bats b/Backend/test/start_captive_webserver_test.bats index 72ae17a..8d2dd03 100755 --- a/Backend/test/start_captive_webserver_test.bats +++ b/Backend/test/start_captive_webserver_test.bats @@ -44,7 +44,7 @@ setup() { # by full path for idempotency tests. export LIGHTTPD_PATH="${TEST_DIR}/lighttpd" cat > "${LIGHTTPD_PATH}" <<'EOF' -#!/bin/bash +#!/data/data/com.termux/files/usr/bin/bash while true; do sleep 1; done EOF chmod +x "${LIGHTTPD_PATH}" @@ -88,7 +88,7 @@ teardown() { make_lighttpd_stub() { local exit_code="${1:-0}" cat > "${LIGHTTPD_PATH}" < "${LIGHTTPD_PATH}" <> "${invocation_log}" exit 0 EOF @@ -283,7 +283,7 @@ EOF @test "[TEST 18] Logs 'already running' message on second call" { # Stub loops forever so pgrep -f can find it by full path cat > "${LIGHTTPD_PATH}" <<'EOF' -#!/bin/bash +#!/data/data/com.termux/files/usr/bin/bash while true; do sleep 1; done EOF chmod +x "${LIGHTTPD_PATH}" @@ -312,7 +312,7 @@ EOF # assert there is exactly 1. @test "[TEST 19] Does not spawn a second lighttpd process on second call" { cat > "${LIGHTTPD_PATH}" <<'EOF' -#!/bin/bash +#!/data/data/com.termux/files/usr/bin/bash while true; do sleep 1; done EOF chmod +x "${LIGHTTPD_PATH}" @@ -403,7 +403,7 @@ EOF LIGHTTPD_PATH="${SPACE_DIR}/lighttpd" cat > "${LIGHTTPD_PATH}" <<'EOF' -#!/bin/bash +#!/data/data/com.termux/files/usr/bin/bash exit 0 EOF chmod +x "${LIGHTTPD_PATH}" diff --git a/Backend/test_start_captive_webserver.sh b/Backend/test/start_captive_webserver_test.sh similarity index 100% rename from Backend/test_start_captive_webserver.sh rename to Backend/test/start_captive_webserver_test.sh From 80e5e7625c525631bb1587e344cf85b7303fa759 Mon Sep 17 00:00:00 2001 From: Daniel Lopez Date: Tue, 21 Apr 2026 19:57:23 -0700 Subject: [PATCH 2/2] Delete Backend/error.log Shouldn't track error.log --- Backend/error.log | 25 ------------------------- 1 file changed, 25 deletions(-) delete mode 100644 Backend/error.log diff --git a/Backend/error.log b/Backend/error.log deleted file mode 100644 index f317d38..0000000 --- a/Backend/error.log +++ /dev/null @@ -1,25 +0,0 @@ -iptables: No chain/target/match by that name. -2026-04-21T22:49:05-0400 Error in Cybercafe_setupFunctions.sh: Line 103 - -iptables: No chain/target/match by that name. -2026-04-21T22:49:05-0400 Error in Cybercafe_setupFunctions.sh: Line 109 - -iptables: No chain/target/match by that name. -2026-04-21T22:49:05-0400 Error in Cybercafe_setupFunctions.sh: Line 117 - -iptables: No chain/target/match by that name. -2026-04-21T22:49:05-0400 Error in Cybercafe_setupFunctions.sh: Line 127 - -iptables: No chain/target/match by that name. -2026-04-21T22:49:05-0400 Error in Cybercafe_setupFunctions.sh: Line 135 - -2026-04-21T22:49:06-0400 Captive portal webserver already running. -Tue Apr 21 22:49:10 EDT 2026 Error in Cybercafe_internetSessionFunctions.sh: Line 24 - -iptables: No chain/target/match by that name. -iptables: Bad rule (does a matching rule exist in that chain?). -iptables: Bad rule (does a matching rule exist in that chain?). -RTNETLINK answers: No such file or directory -2026-04-21T22:49:12-0400 Starting captive portal webserver... -2026-04-21T22:49:12-0400 Captive portal webserver started. -2026-04-21T22:49:13-0400 Captive portal webserver already running.