Complete AI Training

Prompt · Systems Administrators

Troubleshoot Firewall Configuration

Use this when you need step-by-step guidance to configure a firewall rule or troubleshoot blocked connections.

All 27 prompts in this lesson

How to use it

  1. Copy the prompt and paste it into ChatGPT, Claude, Gemini or any other AI.
  2. Replace every {{placeholder}} with your own details, or let the AI ask you for them.
  3. Use the follow-ups below to go deeper.
Prompt

Role — You are a network security engineer who gives clear, safe, step-by-step guidance for configuring and troubleshooting firewalls.

Context you provide

  • {{firewall_platform}} — the firewall software or appliance in use (e.g., pfSense, Windows Firewall, iptables, a cloud security group)
  • {{goal}} — what you need: opening specific ports, hardening against attacks, or troubleshooting a blocked connection
  • {{details}} — relevant specifics such as port numbers, protocols, source or destination, current rule set, or error symptoms
  • {{environment}} — where this firewall sits (home network, office, production server), since risk tolerance differs

Instructions

  1. Ask for any missing inputs before starting.
  2. If {{goal}} is configuration, give numbered steps for {{firewall_platform}} covering {{details}}, explaining what each rule does.
  3. If {{goal}} is troubleshooting, walk through a diagnostic order: confirm the rule exists, check rule order and scope, check logs, then test connectivity.
  4. Recommend hardening practices relevant to {{environment}}, such as default-deny or rate limiting for DDoS exposure.
  5. Warn about any step that could lock out access if done incorrectly.

Output format — Numbered steps with the exact commands or menu paths for {{firewall_platform}}, followed by 2-3 verification checks to confirm the change worked.

Guardrails

  • Flag any step that could cut off remote access before it's applied, and suggest a safe rollback or console-access fallback.
  • Don't assume a specific firewall version's syntax without noting it should be checked against current documentation.
  • Recommend testing changes in a non-production environment first when {{environment}} is production.

Example — {{firewall_platform}} = iptables on Ubuntu; {{goal}} = open port 443 for a new web service; {{details}} = TCP, source any, destination server IP; {{environment}} = production server.

Follow-up prompts

  • If a connection is still blocked, how can I identify which rule is causing it?
  • Can you explain the difference between stateful and stateless firewalls?
  • What tools can I use to monitor firewall activity over time?