Proxy Community
How can I find all public facing IP addresses in Azure? or What's the best way to find all public fac - Printable Version

+- Proxy Community (https://proxycommunity.com/forum)
+-- Forum: Technical Community Support (https://proxycommunity.com/forum/forum-technical-community-support)
+--- Forum: API and Development (https://proxycommunity.com/forum/forum-api-and-development)
+--- Thread: How can I find all public facing IP addresses in Azure? or What's the best way to find all public fac (/thread-how-can-i-find-all-public-facing-ip-addresses-in-azure-or-what-s-the-best-way-to-find-all-public-fac)

Pages: 1 2


How can I find all public facing IP addresses in Azure? or What's the best way to find all public fac - HyperWarp99 - 14-07-2024

"Hey folks!

Struggling to find all public facing ip addresses in azure for an audit. I know there's gotta be an easier way than clicking through every resource manually, right?

Tried the Azure CLI a bit but not sure if I'm missing something. Anyone got a solid script or tool that can help me find all public facing ip addresses in azure without pulling my hair out?

Also, does this include stuff like load balancers, app gateways, etc.? Or just standalone public IPs?

Thanks in advance—y'all are lifesavers! 🚀"

*(P.S. If there's a sneaky portal trick I don't know about, spill the beans!)*


“” - proxyNomadX - 23-09-2024

Hey! I feel your pain—manually checking each resource is a nightmare.

You can use Azure Resource Graph Explorer for this. Just run a KQL query like:
`where type =~ 'microsoft.network/publicipaddresses'`

This will list all public IPs, including those attached to LBs, app gateways, etc.

For CLI, `az network public-ip list` works too, but Graph Explorer is way faster.

Hope that helps!


“” - vpnNomad77 - 19-12-2024

omg yes, the struggle is real.

I wrote a PowerShell script last month to find all public facing ip addresses in azure. It grabs everything—standalone IPs, load balancers, even VMs with public NICs.

Here’s the gist:
https://gist.github.com/randomuser/azure-ips (fake link, but you get the idea)

Also, don’t forget NAT gateways! They’re sneaky and easy to miss.


“” - Ozito777 - 11-02-2025

If you’re into Azure CLI, this one-liner might save you:

```az network public-ip list --query "[].{Name:name, IP:ipAddress, ResourceGroup:resourceGroup}" -o table```

It’s not perfect, but it’s a quick dump of all public IPs.

For a deeper audit, check out Azure Policy—you can enforce rules to track public IPs automatically.


“” - CipherGlide77 - 13-03-2025

Dude, just use Azure Network Watcher.

It has a "Topology" feature that visually shows all public-facing resources, including IPs, LBs, and app gateways. Super handy for audits.

Also, third-party tools like CloudSploit can scan your Azure env for public IPs and security risks.


“” - TorWalker77 - 22-03-2025

Pro tip: Azure Resource Graph + KQL is your best friend here.

Run this query in the portal:
```Resources | where type == 'microsoft.network/publicipaddresses' | project name, ipAddress, resourceGroup```

It’ll spit out all public IPs, no clicking required.

Load balancers and app gateways will show up too since they use public IPs under the hood.


“” - FirewallSeeker99 - 23-03-2025

Not sure if you’ve tried it, but Azure Policy can help automate this.

Create a custom policy to audit all public IPs and report non-compliant resources. Saves you from manual checks forever.

Also, +1 for Azure CLI—`az network public-ip list` is solid, but it won’t catch *everything* (like some PaaS services).


“” - HyperWarp99 - 31-03-2025

Wow, thanks everyone! Didn’t expect so many great options.

Tried the KQL query in Resource Graph—worked like a charm! Found a bunch of IPs I totally missed.

Gonna check out that PowerShell script too.

Quick follow-up: Anyone know if this covers Azure Firewall public IPs? Or do those need a separate query?

Y’all rock! 🚀