Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
0c554fd
refactor(debian): name the maintainer files after their binary package
Nov 23, 2026
313365e
feat(controlplane): optional TLS listener, bulk status and schema for…
Nov 23, 2026
b40c8f4
feat(webui): WebUI plugin lmn_squid as second binary package linuxmus…
Nov 23, 2026
8978222
ci: build, lint and smoke both binary packages
Nov 23, 2026
7fbed80
build(make-deb): deliver every binary package of the source, not only…
Nov 23, 2026
b710396
fix(webui): show errors in the dialogs, handle a stored-but-unhealthy…
Nov 23, 2026
11c9712
style(webui): follow the lmn73 plugin markup, unique message ids, rea…
Nov 23, 2026
02b7a8b
fix(webui): wide detail dialog, one-row input groups, server first in…
Nov 23, 2026
6e9991c
feat(webui): switchable view "by proxy server" | "by school"
Nov 23, 2026
3c513a0
fix(controlplane): refuse a missing keytab before Docker sees it; sta…
Nov 23, 2026
f0dc870
fix(webui): dialogs close again, one-row toolbar, "keytab missing" state
Nov 23, 2026
42bdf6c
feat(controlplane): write-only secrets endpoint and lmnsquid tls enable
Nov 23, 2026
27b0092
feat(webui): read-only precheck on the DC before a proxy host is set …
Nov 23, 2026
2bb6661
feat(webui): set up a proxy host over SSH and deliver its keytab, as …
Nov 23, 2026
fb53480
feat(webui): "Set up a new proxy server" wizard and keytab button (D3)
Nov 23, 2026
b1290e2
build(debian): ship the matching linuxmuster-squid .deb and provision…
Nov 23, 2026
0d0c731
docs: ADR-020 (keytab from the WebUI), ADR-021 (setup over SSH), thre…
Nov 23, 2026
d0fc75b
fix(webui): run the SSH host key scan in the runner process, not in t…
Nov 23, 2026
6a284ed
fix(webui): private runtime directory /run/lmn_squid (was created 0777)
Nov 23, 2026
76605a6
fix(webui): readable result of the time step
Nov 23, 2026
021371c
fix(webui): German text for known control-plane problems
Nov 23, 2026
70b762c
fix(controlplane): keep the loopback API when the TLS listener cannot…
Nov 24, 2026
c471ba1
fix(webui): harden setup, jobs, keytab, connections and browser requests
Nov 24, 2026
4a88809
build(debian): webui package depends on samba-common-bin and ldb-tool…
Nov 24, 2026
1ad3aaa
docs: rotation, account checks, hardened jobs and setup, CSRF guard (…
Nov 24, 2026
90955b3
test(webui): a paramiko without PKey.from_type_string is named, not a…
Nov 24, 2026
414a019
fix(webui): editing a connection keeps the fields it does not send (f…
Nov 24, 2026
d581e01
fix(webui): keytab button checks the target before AD changes; AES-on…
Nov 24, 2026
493b419
fix(webui): long dialogs scroll inside the window
Nov 25, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
54 changes: 39 additions & 15 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -102,10 +102,16 @@ jobs:
ruff format --check --line-length 100 debian/venv-relocate
- name: mypy
run: mypy --config-file controlplane/pyproject.toml controlplane/lmnsquid
- name: mypy (WebUI plugin)
run: mypy --config-file webui/pyproject.toml webui/lmn_squid webui/build_plugin.py
- name: pytest
run: pytest -q controlplane/tests
# The plugin against stand-ins of the WebUI's aj/jadi modules and against real control
# planes (lmnsquid app, fake Docker) on a TLS listener with a self-signed certificate.
- name: pytest (WebUI plugin)
run: pytest -q webui/tests
- name: shellcheck
run: sudo apt-get update -qq && sudo apt-get install -y -qq shellcheck && shellcheck --severity=warning $(git ls-files '*.sh') debian/preinst debian/postinst debian/prerm debian/postrm
run: sudo apt-get update -qq && sudo apt-get install -y -qq shellcheck && shellcheck --severity=warning $(git ls-files '*.sh') debian/*.preinst debian/*.postinst debian/*.prerm debian/*.postrm
- name: reuse (license compliance)
run: reuse lint
- name: blocklist smoke
Expand Down Expand Up @@ -145,11 +151,14 @@ jobs:
# dpkg-buildpackage writes one level above the source tree.
mkdir -p output && mv ../*.deb ../*.changes ../*.buildinfo ../*.dsc ../*.tar.xz output/
# DEBIAN/md5sums must cover every shipped regular file, or `dpkg --verify` is a no-op.
deb=$(ls output/*.deb)
dpkg-deb -I "$deb"
dpkg-deb --ctrl-tarfile "$deb" | tar -tf - | grep -qx './md5sums'
test "$(dpkg-deb -c "$deb" | grep -c '^-')" = "$(dpkg-deb --ctrl-tarfile "$deb" | tar -xOf - ./md5sums | wc -l)"
echo "md5sums: $(dpkg-deb --ctrl-tarfile "$deb" | tar -xOf - ./md5sums | wc -l) files"
# Two binary packages: linuxmuster-squid (amd64) and linuxmuster-squid-webui (all).
test "$(ls output/*.deb | wc -l)" = 2
for deb in output/linuxmuster-squid_*_amd64.deb output/linuxmuster-squid-webui_*_all.deb; do
dpkg-deb -I "$deb"
dpkg-deb --ctrl-tarfile "$deb" | tar -tf - | grep -qx './md5sums'
test "$(dpkg-deb -c "$deb" | grep -c '^-')" = "$(dpkg-deb --ctrl-tarfile "$deb" | tar -xOf - ./md5sums | wc -l)"
echo "$deb md5sums: $(dpkg-deb --ctrl-tarfile "$deb" | tar -xOf - ./md5sums | wc -l) files"
done
- name: Lintian (the .deb only)
run: |
# Never lint the .changes: `lmn73` is not a known distribution, which makes lintian
Expand Down Expand Up @@ -239,7 +248,7 @@ jobs:
gh release download "$tag" --repo "$GITHUB_REPOSITORY" --pattern '*.deb' --dir previous && break
echo "download attempt $i failed, retrying"; sleep 10
done
test -n "$(ls previous/*.deb 2>/dev/null)"
test -n "$(ls previous/linuxmuster-squid_*_amd64.deb 2>/dev/null)"
echo "tag=$tag" >> "$GITHUB_OUTPUT"
- name: Compare the file tree with the released package
if: steps.prev.outputs.skip != '1'
Expand All @@ -251,8 +260,8 @@ jobs:
# unnoticed in a file-only comparison); a symlink prints "path -> target", so a
# retargeted link (/usr/bin/lmnsquid, the venv's python and lib64) is drift too.
norm() { dpkg-deb -c "$1" | awk '{t = ($7 == "->" ? " " $7 " " $8 : ""); print $1, $2, $6 t}' | LC_ALL=C sort; }
norm previous/*.deb > old.txt
norm packages/*.deb > new.txt
norm previous/linuxmuster-squid_*_amd64.deb > old.txt
norm packages/linuxmuster-squid_*_amd64.deb > new.txt
python3 - old.txt new.txt linuxmuster-squid lmnsquid "$PREV_TAG" <<'PY' | tee -a "$GITHUB_STEP_SUMMARY"
import re
import sys
Expand Down Expand Up @@ -318,7 +327,7 @@ jobs:
run: |
set -eux
sudo apt-get update -qq
sudo apt-get install -y ./packages/*.deb
sudo apt-get install -y ./packages/linuxmuster-squid_*_amd64.deb
test "$(command -v lmnsquid)" = /usr/bin/lmnsquid
sudo lmnsquid --help >/dev/null
# postinst enabled + started the service; the API must answer like the docs promise.
Expand Down Expand Up @@ -347,6 +356,12 @@ jobs:
# race, so the same .deb is configured 30 more times, failing on the first error.
- name: Configure loop (15x purge + fresh install, 15x reinstall/dpkg-reconfigure)
run: sudo bash scripts/tests/install_loop.sh packages/linuxmuster-squid_*_amd64.deb 15
# The WebUI plugin package depends on linuxmuster-webui7, which only a school server has:
# installed with --force-depends next to recording stand-ins of merge-permissions.py and
# sophomorix-ui (file tree, permissions.yml, configure/remove/purge). The WebUI itself is
# tested in the lab.
- name: WebUI plugin package (without linuxmuster-webui7)
run: sudo bash scripts/tests/webui_deb_smoke.sh packages/linuxmuster-squid-webui_*_all.deb

# Kevin's rule: a release must still install cleanly ON TOP OF the version that is
# already running on a school server. This job installs the newest published release
Expand Down Expand Up @@ -402,7 +417,7 @@ jobs:
gh release download "$tag" --repo "$GITHUB_REPOSITORY" --pattern '*.deb' --dir previous && break
echo "download attempt $i failed, retrying"; sleep 10
done
test -n "$(ls previous/*.deb 2>/dev/null)"
test -n "$(ls previous/linuxmuster-squid_*_amd64.deb 2>/dev/null)"
echo "tag=$tag" >> "$GITHUB_OUTPUT"
echo "::notice::upgrading from $tag"

Expand All @@ -411,7 +426,7 @@ jobs:
run: |
set -eux
sudo apt-get update -qq
sudo apt-get install -y ./previous/*.deb
sudo apt-get install -y ./previous/linuxmuster-squid_*_amd64.deb
# v1.3.0 (the pre-conventions line) ships no /usr/bin/lmnsquid, so the OLD
# version is always driven through its venv entry point.
LMN=/opt/linuxmuster-squid/venv/bin/lmnsquid
Expand Down Expand Up @@ -541,7 +556,7 @@ jobs:
# to the release, and a plain install would say "already the newest version"
# and test nothing. dpkg must run the postinst with $2 set, or its upgrade
# branch (restart, update-all, reconcile) never runs.
sudo apt-get install -y --reinstall --allow-downgrades ./packages/*.deb 2>&1 \
sudo apt-get install -y --reinstall --allow-downgrades ./packages/linuxmuster-squid_*_amd64.deb 2>&1 \
| tee upgrade.log

- name: Assert that nothing was lost
Expand Down Expand Up @@ -586,6 +601,15 @@ jobs:
sudo test -f "$noauth_file" || { echo "missing: $noauth_file"; exit 1; }
if sudo test -s "$noauth_file"; then echo "not empty: $noauth_file"; exit 1; fi
done < <(awk '$3 ~ /^\/etc\/linuxmuster-squid\/blocklists\/[^\/]+\/blocked\.domains$/' before/etc-modes)
# (since 7.3.11, ADR-018) the postinst makes the TLS listener's self-signed
# certificate once: tls/ (0700) with api.key (0600) and api.crt (0644), owned like
# the tree, where the previous release had none.
if ! awk '$3 == "/etc/linuxmuster-squid/tls" { f = 1 } END { exit !f }' before/etc-modes; then
owner=$(awk '$3 == "/etc/linuxmuster-squid" { print $2 }' before/etc-modes)
printf '%s\n' "700 $owner /etc/linuxmuster-squid/tls" \
"600 $owner /etc/linuxmuster-squid/tls/api.key" \
"644 $owner /etc/linuxmuster-squid/tls/api.crt" >> before/etc-modes.expected
fi
sort -o before/etc-modes.expected before/etc-modes.expected
diff -u before/etc-modes.expected after/etc-modes

Expand Down Expand Up @@ -677,14 +701,14 @@ jobs:
STATE=/var/lib/systemd/deb-systemd-helper-enabled/$U.dsh-also
sudo apt-get purge -y linuxmuster-squid
test ! -e "$STATE" # purge forgot the state: the release starts from scratch
sudo apt-get install -y ./previous/*.deb
sudo apt-get install -y ./previous/linuxmuster-squid_*_amd64.deb
test "$(systemctl is-enabled $U)" = enabled
sudo systemctl disable --now $U
test "$(systemctl is-active $U || true)" = inactive
for pass in 1 2; do
cursor="$(sudo journalctl -q -n 0 --show-cursor | sed -n 's/^-- cursor: //p')"
test -n "$cursor"
sudo apt-get install -y --reinstall --allow-downgrades ./packages/*.deb 2>&1 \
sudo apt-get install -y --reinstall --allow-downgrades ./packages/linuxmuster-squid_*_amd64.deb 2>&1 \
| tee "disabled-$pass.log"
grep -E 'Unpacking linuxmuster-squid \([^)]+\) over \([^)]+\)' "disabled-$pass.log"
test "$(systemctl is-enabled $U || true)" = disabled
Expand Down
45 changes: 32 additions & 13 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,10 +89,14 @@ jobs:
# dpkg-buildpackage writes one level above the source tree.
mkdir -p output && mv ../*.deb ../*.changes ../*.buildinfo ../*.dsc ../*.tar.xz output/
# DEBIAN/md5sums must cover every shipped regular file, or `dpkg --verify` is a no-op.
deb=$(ls output/*.deb)
dpkg-deb -I "$deb"
dpkg-deb --ctrl-tarfile "$deb" | tar -tf - | grep -qx './md5sums'
test "$(dpkg-deb -c "$deb" | grep -c '^-')" = "$(dpkg-deb --ctrl-tarfile "$deb" | tar -xOf - ./md5sums | wc -l)"
# Two binary packages: linuxmuster-squid (amd64) and linuxmuster-squid-webui (all).
test "$(ls output/*.deb | wc -l)" = 2
for deb in output/linuxmuster-squid_*_amd64.deb output/linuxmuster-squid-webui_*_all.deb; do
dpkg-deb -I "$deb"
dpkg-deb --ctrl-tarfile "$deb" | tar -tf - | grep -qx './md5sums'
test "$(dpkg-deb -c "$deb" | grep -c '^-')" = "$(dpkg-deb --ctrl-tarfile "$deb" | tar -xOf - ./md5sums | wc -l)"
echo "$deb md5sums: $(dpkg-deb --ctrl-tarfile "$deb" | tar -xOf - ./md5sums | wc -l) files"
done
- name: Lintian (the .deb only)
run: |
# Never lint the .changes: `lmn73` is not a known distribution (see ci.yml).
Expand Down Expand Up @@ -153,7 +157,7 @@ jobs:
gh release download "$tag" --repo "$GITHUB_REPOSITORY" --pattern '*.deb' --dir previous && break
echo "download attempt $i failed, retrying"; sleep 10
done
test -n "$(ls previous/*.deb 2>/dev/null)"
test -n "$(ls previous/linuxmuster-squid_*_amd64.deb 2>/dev/null)"
echo "tag=$tag" >> "$GITHUB_OUTPUT"
- name: Compare the file tree with the released package
if: steps.prev.outputs.skip != '1'
Expand All @@ -165,8 +169,8 @@ jobs:
# unnoticed in a file-only comparison); a symlink prints "path -> target", so a
# retargeted link (/usr/bin/lmnsquid, the venv's python and lib64) is drift too.
norm() { dpkg-deb -c "$1" | awk '{t = ($7 == "->" ? " " $7 " " $8 : ""); print $1, $2, $6 t}' | LC_ALL=C sort; }
norm previous/*.deb > old.txt
norm packages/*.deb > new.txt
norm previous/linuxmuster-squid_*_amd64.deb > old.txt
norm packages/linuxmuster-squid_*_amd64.deb > new.txt
python3 - old.txt new.txt linuxmuster-squid lmnsquid "$PREV_TAG" <<'PY' | tee -a "$GITHUB_STEP_SUMMARY"
import re
import sys
Expand Down Expand Up @@ -231,7 +235,7 @@ jobs:
run: |
set -eux
sudo apt-get update -qq
sudo apt-get install -y ./packages/*.deb
sudo apt-get install -y ./packages/linuxmuster-squid_*_amd64.deb
test "$(command -v lmnsquid)" = /usr/bin/lmnsquid
sudo lmnsquid --help >/dev/null
ok=0
Expand All @@ -257,6 +261,12 @@ jobs:
# race, so the same .deb is configured 30 more times, failing on the first error.
- name: Configure loop (15x purge + fresh install, 15x reinstall/dpkg-reconfigure)
run: sudo bash scripts/tests/install_loop.sh packages/linuxmuster-squid_*_amd64.deb 15
# The WebUI plugin package depends on linuxmuster-webui7, which only a school server has:
# installed with --force-depends next to recording stand-ins of merge-permissions.py and
# sophomorix-ui (file tree, permissions.yml, configure/remove/purge). The WebUI itself is
# tested in the lab.
- name: WebUI plugin package (without linuxmuster-webui7)
run: sudo bash scripts/tests/webui_deb_smoke.sh packages/linuxmuster-squid-webui_*_all.deb

# Kevin's rule: a release must still install cleanly ON TOP OF the version that is
# already running on a school server. This job installs the newest published release
Expand Down Expand Up @@ -313,7 +323,7 @@ jobs:
gh release download "$tag" --repo "$GITHUB_REPOSITORY" --pattern '*.deb' --dir previous && break
echo "download attempt $i failed, retrying"; sleep 10
done
test -n "$(ls previous/*.deb 2>/dev/null)"
test -n "$(ls previous/linuxmuster-squid_*_amd64.deb 2>/dev/null)"
echo "tag=$tag" >> "$GITHUB_OUTPUT"
echo "::notice::upgrading from $tag"

Expand All @@ -322,7 +332,7 @@ jobs:
run: |
set -eux
sudo apt-get update -qq
sudo apt-get install -y ./previous/*.deb
sudo apt-get install -y ./previous/linuxmuster-squid_*_amd64.deb
# v1.3.0 (the pre-conventions line) ships no /usr/bin/lmnsquid, so the OLD
# version is always driven through its venv entry point.
LMN=/opt/linuxmuster-squid/venv/bin/lmnsquid
Expand Down Expand Up @@ -452,7 +462,7 @@ jobs:
# to the release, and a plain install would say "already the newest version"
# and test nothing. dpkg must run the postinst with $2 set, or its upgrade
# branch (restart, update-all, reconcile) never runs.
sudo apt-get install -y --reinstall --allow-downgrades ./packages/*.deb 2>&1 \
sudo apt-get install -y --reinstall --allow-downgrades ./packages/linuxmuster-squid_*_amd64.deb 2>&1 \
| tee upgrade.log

- name: Assert that nothing was lost
Expand Down Expand Up @@ -497,6 +507,15 @@ jobs:
sudo test -f "$noauth_file" || { echo "missing: $noauth_file"; exit 1; }
if sudo test -s "$noauth_file"; then echo "not empty: $noauth_file"; exit 1; fi
done < <(awk '$3 ~ /^\/etc\/linuxmuster-squid\/blocklists\/[^\/]+\/blocked\.domains$/' before/etc-modes)
# (since 7.3.11, ADR-018) the postinst makes the TLS listener's self-signed
# certificate once: tls/ (0700) with api.key (0600) and api.crt (0644), owned like
# the tree, where the previous release had none.
if ! awk '$3 == "/etc/linuxmuster-squid/tls" { f = 1 } END { exit !f }' before/etc-modes; then
owner=$(awk '$3 == "/etc/linuxmuster-squid" { print $2 }' before/etc-modes)
printf '%s\n' "700 $owner /etc/linuxmuster-squid/tls" \
"600 $owner /etc/linuxmuster-squid/tls/api.key" \
"644 $owner /etc/linuxmuster-squid/tls/api.crt" >> before/etc-modes.expected
fi
sort -o before/etc-modes.expected before/etc-modes.expected
diff -u before/etc-modes.expected after/etc-modes

Expand Down Expand Up @@ -588,14 +607,14 @@ jobs:
STATE=/var/lib/systemd/deb-systemd-helper-enabled/$U.dsh-also
sudo apt-get purge -y linuxmuster-squid
test ! -e "$STATE" # purge forgot the state: the release starts from scratch
sudo apt-get install -y ./previous/*.deb
sudo apt-get install -y ./previous/linuxmuster-squid_*_amd64.deb
test "$(systemctl is-enabled $U)" = enabled
sudo systemctl disable --now $U
test "$(systemctl is-active $U || true)" = inactive
for pass in 1 2; do
cursor="$(sudo journalctl -q -n 0 --show-cursor | sed -n 's/^-- cursor: //p')"
test -n "$cursor"
sudo apt-get install -y --reinstall --allow-downgrades ./packages/*.deb 2>&1 \
sudo apt-get install -y --reinstall --allow-downgrades ./packages/linuxmuster-squid_*_amd64.deb 2>&1 \
| tee "disabled-$pass.log"
grep -E 'Unpacking linuxmuster-squid \([^)]+\) over \([^)]+\)' "disabled-$pass.log"
test "$(systemctl is-enabled $U || true)" = disabled
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ debian/files
debian/*.substvars
debian/debhelper-build-stamp
debian/linuxmuster-squid/
debian/linuxmuster-squid-webui/
*.deb
*.buildinfo
*.changes
Expand Down
16 changes: 15 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,18 @@ the same AD/Kerberos infrastructure the school already operates.
**updates digest-pinned with health-check auto-rollback**. Shipped as a
signed `.deb`.

- **WebUI plugin (optional):** `linuxmuster-squid-webui` adds the page *Squid proxy* to the
linuxmuster.net 7.3 WebUI for global administrators; it manages one or more proxy hosts over
their opt-in TLS listener with a pinned certificate.

| Package | Install on | What |
|---|---|---|
| `linuxmuster-squid` (amd64) | the proxy host (Docker VM) | control plane, CLI, service |
| `linuxmuster-squid-webui` (all) | the linuxmuster server (WebUI) | the WebUI plugin `lmn_squid` |

Both come from this repository with the same version; they talk over HTTPS, neither depends on
the other being installed on the same host.

Details: [`docs/architecture.md`](docs/architecture.md).

## Usage
Expand Down Expand Up @@ -132,7 +144,9 @@ Docker**. Aggregator:
Keytabs are domain credentials (secret/tmpfs, least-privilege). **No
HTTPS decryption** (privacy-friendly, no client CA rollout). Control-plane
Docker socket access is **root-equivalent** — API only on
localhost/mgmt network, token/TLS, behind a socket proxy. More:
localhost, or the opt-in TLS listener on the management network (pinned certificate, client
allowlist), token, behind a socket proxy. The WebUI plugin holds those tokens: global
administrators only. More:
[`docs/threat-model.md`](docs/threat-model.md) · [`docs/keytab-and-dns.md`](docs/keytab-and-dns.md).

## License
Expand Down
Loading
Loading