Azure bgp oscillation route leak

From XuShuwenn/RedAct · View interactive version

Azure bgp oscillation route leak is an AI agent skill from the GitHub repository XuShuwenn/RedAct. Detect BGP route oscillation and route leaks in Azure Virtual WAN topology, and evaluate which solutions can fix them.

How to use this skill

Skill file

Azure BGP Route Leak Detection

When to Use

Execution Discipline

Execution Discipline

Key Concepts

Input Files

Required Analysis Workflow

  1. Do not create auxiliary scripts or write intermediate files unless the task explicitly allows them; only write the required output file(s).
  2. If any loaded input or produced report appears partial or malformed at any point, do not continue from it; re-read, regenerate, or rewrite it and validate the full contents first.
  3. Make the derivation auditable before writing the report: parse and normalize the loaded inputs, identify the supported preference graph and any advertisement/relationship evidence, then determine oscillation, leak status, and per-solution outcomes from that evidence rather than jumping directly from raw file reads to a completed report.
  4. Do not change detection logic, solution judgments, or final conclusions based on a truncated terminal view of the report. First retrieve or parse the complete saved JSON, then decide whether any correction is needed.

14a. Do not claim that a script, report, or solution evaluation exists unless its substantive contents are visible or directly validated in-session.

14b. If any output readback is truncated, cut off mid-field, or hidden behind a placeholder or summary, treat the analysis as unverified and re-read the artifact before making conclusions.

  1. You may use delegation only for non-critical assistance; do not outsource the core determinations of oscillation detection, route leak detection, or per-solution outcomes unless the task explicitly requires it.

15a. Do not delegate the end-to-end evaluation of candidate solutions. If any helper is used for partial assistance, recompute each solution's oscillation_resolved and route_leak_resolved values yourself from the loaded inputs before writing the report.

15b. Treat delegated analytical output as hints only; do not copy solution judgments, oscillation findings, or leak findings into the final JSON until you can point to the specific input evidence and normalized logic supporting each one.

  1. If any delegated tool or subagent provides analytical conclusions, treat them as untrusted until you verify the substantive claims directly against the loaded inputs before using them in the report.
  2. Before final completion, read back /app/output/oscillation_report.json, parse or inspect the full contents, and confirm the on-disk artifact is complete, valid JSON matching the required schema rather than a placeholder, summary, or partial write.
  3. Do not finalize from a write confirmation or assumption about what was written; finalization requires explicit post-write verification visible in the interaction log.
  4. If any verification readback is truncated, cut off mid-JSON, omits any solution entry or closing structure, or shows status text/commentary instead of the serialized report object, treat verification as failed: re-read or rewrite the full file and validate again before continuing.
  5. Do not claim that solutions were evaluated, or state exact counts, rankings, or recommendations, unless the interaction log shows the full possible_solutions.json was read and the per-solution results were derived from that complete input.
  6. Before the final response, run a termination check only after complete readback/validation succeeds: confirm the output file is fully written and validated, reconcile the confirmed solution list with the saved solution_results keys and count, and confirm the final response itself matches the exact task-required completion format/token with identical spelling, punctuation, and casing.
  1. Do not use a single opaque command or summary step that claims to have loaded files, analyzed topology, evaluated all solutions, and written the report at once. Make the workflow inspectable: show the file reads, normalization, issue detection, and per-solution evaluation in separate visible steps or clearly scoped commands.
  2. Keep the execution trail observable: list files with a real command, read each required input with real commands, write the report with a real command, then read back the saved file with a real command before claiming completion.
  3. After any normalization change, audit every downstream consumer before continuing; do not leave cycle detection, leak checks, or solution evaluation reading the pre-normalized structure.
  4. When you claim the inputs are consistent, valid, or sufficient, make the supporting checks observable in the log first: show concrete cross-checks such as matching ASNs across files, confirming relationship labels and directions, and tracing the relevant advertised path against the policy rule used.
  5. Keep the evaluated solution set auditable while you work: record the exact confirmed list from possible_solutions.json, and ensure the final saved solution_results covers that same set completely with no dropped item, duplicate collapse, or summary-only evaluation.

Required Analysis Workflow

  1. Read all four input files completely before deciding anything.
  2. Normalize the parsed JSON into stable internal structures before analysis.
  3. Build preference, relationship, and advertisement relationships from the input data, not from assumptions about Azure topology.
  4. Detect baseline issues from the provided evidence only:
  1. If the inputs do not show enough topology, relationship, or advertisement data to prove a specific route leak, set route_leak_detected to false and route_leaks to [] rather than guessing.
  2. Evaluate every entry in possible_solutions.json separately by recomputing whether the demonstrated cycle and prohibited advertisement would still exist after applying that solution's stated effect.
  3. Mark oscillation_resolved true only if the solution breaks the observed preference cycle, and mark route_leak_resolved true only if it prevents the specific prohibited advertisement path evidenced in the inputs.
  4. Do not classify solutions by keyword matching, generic networking intuition, or unsupported assumptions.
  5. Produce exactly one solution_results entry per input solution and no extra entries.
  6. Only after completing the per-solution evaluation, write /app/output/oscillation_report.json and validate it.

Output Format

JSON at /app/output/oscillation_report.json:

{
  "oscillation_detected": true/false,
  "oscillation_cycle": [AS1, AS2],
  "affected_ases": [AS_numbers],
  "route_leak_detected": true/false,
  "route_leaks": [{"leaker_as": N, "source_as": M, "destination_as": K, ...}],
  "solution_results": {"solution_name": {"oscillation_resolved": bool, "route_leak_resolved": bool}}
}

Tips

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.