Skip to content

rustpanosmcp: add get_panos_feed_status read for mecfeedmcp EDLs (#253) - #269

Merged
fastrevmd-lab merged 5 commits into
mainfrom
feat/feed-status-253
Oct 27, 2026
Merged

fastrevmd-lab merged 5 commits into
mainfrom
feat/feed-status-253

Conversation

@fastrevmd-lab

Copy link
Copy Markdown
Member

Adds get_panos_feed_status, a read-only typed tool reporting mecfeedmcp feed subscriptions (PAN-OS External Dynamic Lists) per device. Part of mechubsec/mecfeedmcp#6.

What it reports

For each EDL in the inventory vsys whose URL path is /feeds/panos-edl/{address,prefix,domain} (type must agree: ip ↔ address/prefix, domain ↔ domain):

  • url, with credentials, query and fragment stripped
  • valid, auth_valid and next_update, from request system external-list stats
  • total_valid, total_ignored and total_invalid, from request system external-list show
  • content_etag: sha256-<hex> over the sorted valid members joined with \n, plus a trailing \n. That is mecfeed-serve's ETag formula, so it matches serve's ETag when the firewall holds the whole document. It is null when the member count disagrees with total-valid.
  • last_event: the latest EDL(<name>) system-log line, redacted. EDL file was not updated at remote end means serve answered 304.

No subscription gives feeds: []. That covers a missing external-list node (No such node).

Trust boundary

edl_op is the only parameterised <request> path. The verb (stats/show) and type (ip/domain) are enums, so refresh cannot be represented. The EDL name must be 1–63 characters of [A-Za-z0-9 ._-]. That excludes every XML and log-filter metacharacter, and the same check guards the log query.

Docs

docs/OPERATIONS.md gets a new section, Subscribing to a mecfeedmcp feed. The EDL entry goes through the existing change-set flow without <auth>, and the Basic password is set once on the firewall out of band. Change sets keep the element verbatim in state and in get_panos_change_set output. README lists the new tool.

Verification

  • The fixtures are live responses captured from panosvm (PAN-OS lab VM) on 2026-10-27: stats, show, unknown-name error and the system-log EDL lines.
  • cargo fmt --check, cargo clippy --workspace --all-targets -D warnings and cargo test --workspace are clean. The tests are unit tests plus mock-server end-to-end tests in typed_reads.rs, and the tool is added to audit_completeness.rs.

Known limits

  • Only the inventory vsys is read. shared and Panorama-pushed EDLs are not.
  • The log filter assumes the EDL(<name>) message prefix this PAN-OS version emits.
  • The first commit is about 745 lines, so the codex review gate may need CI rather than a local run.

Closes #253

🤖 Generated with Claude Code

fastrevmd-lab and others added 5 commits October 27, 2026 17:11
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…253)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… truncated read (#253)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@fastrevmd-lab
fastrevmd-lab enabled auto-merge (squash) October 27, 2026 22:20
@fastrevmd-lab
fastrevmd-lab merged commit 419c26b into main Oct 27, 2026
11 checks passed
@fastrevmd-lab fastrevmd-lab mentioned this pull request Oct 27, 2026
@fastrevmd-lab
fastrevmd-lab deleted the feat/feed-status-253 branch October 27, 2026 23:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Read-only feed-status tool for mecfeedmcp feeds (PAN-OS External Dynamic List (EDL))

1 participant