Settings redesign: hub navigation (reconciled with the operand hardening) #2
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "feature/settings-redesign"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Rebased onto
origin/main. Two commits: the redesign squash (dce2031, unchanged content) and a reconciliation commit (3dfc9d5).The redesign (
dce2031)Hub-based navigation — home / network / displays / input / apps / privacy / system hub pages, redesigned sidebar, shared nav state, new hub view components. Alongside: input validation into root commands,
set_charge_thresholdtee-stdin fix, streaming-install stdin fix, frontend type fixes, version → 0.8.2, clippy/svelte-check cleanup. 102 files — unreviewable commit-by-commit; this is the enumerated version.Reconciliation with
f7b114f"Harden privileged command operands" (3dfc9d5)The branch was cut before that hardening landed. Rebase conflicts in
users.rs/power.rs/firewall.rs/capabilities/default.jsonwere resolved to keep the stricter side of each, then fold the redesign's additions on top:f7b114fusers.rschpasswd_input(validates the password for:/ newline — the redesign only checked the username),may_delete_user(refuses root / current user)--argv separators, GECOS control-char strippingpower.rscharge_threshold_write(validateswhich, clamps) +util::run_with_stdin+ its test.clamp(0,100)firewall.rsvalid_firewall_rule/valid_rule_numberallowlistcapabilities/default.jsonopener:defaultstays removed (nothing uses the opener plugin)core:window:*(the redesign's customTitlebar.svelteneeds them)Dropped
util::valid_username/util::valid_cli_value(redesign added them; every call site now uses the stricterf7b114flocal validator) + an unused import.⚠️ One unresolved product call
firewall.rskeeps f7b114f's port-only validator, which rejects service names likeOpenSSH. The redesign's Firewall UI hint advertises exactly that (e.g. "8080/tcp" ... or a service name like "OpenSSH"). Either loosen the backend toutil::valid_cli_value(still blocks flag/;/control injection, argv-safe) or drop the service-name hint. Left strict pending your decision — flagged in the commit message.tauri.conf.json (
+10)version0.8.0 → 0.8.2 (drift fix; Cargo.toml was already 0.8.2), window 960×640 → 1280×840 +minWidth/minHeight, cosmeticbackgroundColor.identifier, CSP, andassetProtocolscope unchanged — no allowlist/security loosening.Checks
Backend
cargo build/cargo test(64 pass) /cargo clippy --all-targets -- -D warnings— clean.npm run build(frontend) — clean.screenshot.rsKNOWN_VIEWSupdated with the new hub routes.Manual smoke (needs doing on hermes)
:or newline in the password → rejected; try removing root / yourself → rejected)whichother than start/end → rejected), brightness8080/tcp(works), addOpenSSH(currently rejected — see the flag above)bos-settings --screenshot <view> --output x.pngfor a few of the new hub viewsGenerated with Codebuff 🤖 Co-Authored-By: Codebuff <noreply@codebuff.com>f7b114fprivileged-command hardening 3dfc9d56f3The redesign branch was cut before "Harden privileged command operands against injection" landed on main; the rebase conflicts in users.rs, power.rs, firewall.rs and capabilities/default.json were resolved to keep the stricter side of each: - users.rs: keep `chpasswd_input` / `valid_chpasswd_password` (validates the *password* for `:` / newline, which the redesign's inline checks missed) and `may_delete_user` (refuses root / the current user); fold in the redesign's `--` argv separators and GECOS control-char stripping on top. - power.rs: keep `charge_threshold_write` (validates `which` ∈ {start,end} and clamps) + `util::run_with_stdin` for the tee pipe, plus its test; take the redesign's brightness clamp. - firewall.rs: keep the port-only `valid_firewall_rule` / `valid_rule_number` allowlist fromf7b114f. NOTE: the redesign's Firewall UI hint advertises service names ("OpenSSH") which this validator rejects — either loosen it to `util::valid_cli_value` or drop the service-name hint. Left strict pending that call. - capabilities/default.json: keep `opener:default` removed (nothing in the frontend or backend uses the opener plugin); add the four `core🪟*` perms the redesign's custom Titlebar needs. Drops `util::valid_username` / `util::valid_cli_value` (added by the redesign, now unused — every call site uses the stricterf7b114flocal validator) and the unused `use super::util` in firewall.rs.