Commit graph

7 commits

Author SHA1 Message Date
Nuno Duque Nunes
0e3f281519 feat: --json for hosts/subnet/policy list commands
- cmd::hosts::_output_json: hosts with type/tags array
- cmd::subnet::_output_json: subnets with is_group bool
- cmd::policy::_output_json: policies with proper booleans
2026-05-27 00:52:45 +00:00
Nuno Duque Nunes
14d2a78b78 feat: command mixin system, --json for list/inspect, tests
- core/command_mixins.sh: mixin infrastructure with auto-loader
- core/mixins/json_output.mixin.sh, no_color.mixin.sh
- commands/mixins/MIXIN_TEMPLATE.mixin.sh
- command::run: mixin preprocess with nameref, empty array guard
- list --json, inspect --json: structured JSON with envelope
- json::envelope, json::error_envelope
- tests: json output unit tests, group purge-stale, logs clean
2026-05-27 00:01:06 +00:00
Nuno Duque Nunes
cf71e9f51a test: add tests for all new features, fix bugs found by tests
- integration: logs query flags, hosts command, peer command sections
- unit: fmt::bytes, config::dns_string, parse_since, ui::group::status
- destructive: duplicate rule validation, peer update-dns/tunnel
- fix: config::allowed_ips_for used $2 instead of $1
- fix: identity rule assign exit_code unbound variable
- fix: ctx::identity → ctx::identities in peers::get_identity
- fix: peers::get_identity restored (needed for rule assign duplicate check)
- rule assign: blocks if rule already in peer's identity via peers::get_identity
- identity rule assign: --migrate removes conflicting direct peer rules
2026-05-26 00:09:30 +00:00
Nuno Duque Nunes
3378ec3e5e feat: logs query flags, json_helper module split, handshake logging
- wgctl logs --since: relative (2h/7d) and EU/ISO date formats
- wgctl logs --service: filter by service name, IP, or IP:port
- wgctl logs --event: filter wg events by type
- wgctl logs: no header when no logs found
- core/lib/util.py: shared utilities, parse_since, reverse_lookup
- core/lib/events.py: fw_events, wg_events with query params
- core/lib/peers.py: peer_data, peer_transfer
- core/lib/activity.py: activity_aggregate
- wgctl-monitor.py: handshake session poller thread with cache
2026-05-25 00:21:16 +00:00
Nuno Duque Nunes
4b2f2a846a feat: identity, subnet, policy systems + tableless layouts 2026-05-22 03:42:40 +00:00
Nuno Duque Nunes
de1a44a7e4 finish base implementation 2026-05-20 21:49:44 +00:00
Nuno Duque Nunes
8bb1de4976 init feature 2026-05-19 15:26:31 +00:00