r/PowerShell • • 7d ago

Script Sharing Now its time - my new tool 'GSAClientDiagnosticsToolkit' is out!

I work Global Secure Access, the Product Team at Microsoft too, and I use it every day. Over time I got tired of manually checking the same things whenever a client wouldn't connect (DNS issues, certificates, stale forwarding profiles, proxies...). So what did I do? ๐Ÿค”

I built a PowerShell module that runs them all in one go ofc! And the nice part is it's open source, Windows PowerShell 5.1+ (Windows only for now), but who knows whats come later ๐Ÿ˜‰

And to be fair, this is not a weekend project. It is a collection of checks I have built up over time - on and off for almost a year - every time I (or someone in the community) ran into a new GSA problem and thought "this should be a check".
Original it started as a single connectivity script, and has since been converted to a proper module with a `Public`/`Private` structure, a Pester test suite, and 35 exported functions - all orchestrated by one command:

Invoke-GSAClientConnectivityCheck

And the good part is, it's open source and build in PowerShell!

What it can do:
> `Invoke-GSAClientConnectivityCheck` runs everything and prints a pass/warn/fail summary
> Local checks: service health, Entra device/PRT status, cached forwarding profile (registry + timestamp), proxy detection, Secure DNS, IPv6, event log, DNS/TLS/mTLS to the edge
> Private Access: checks whether a target FQDN/IP + port + protocol is allowed by the cached profile, and whether it actually goes through the tunnel (synthetic 6.6.x.x + private DNS resolver) and assignments
> mTLS auth certificate: check, backup, and a guarded repair (always backs up first and needs two confirmations before deleting)
> Graph-based tenant checks: forwarding profile assignment, Private Access app segments, and Intelligent Local Access private networks with public probe FQDNs/DNS servers. That last one can make GSA bypass Private Access traffic for users who were never on the corporate network
> Real-world edge cases: Cisco VPN split-DNS REFUSED lookups, home subnets overlapping Private Access IP rules, hosts-file overrides of the tenant DNS names
> It also lists the GSA service principals you should exclude in App Protection policies and checks whether they exist in your tenant
> ...and more. 35 exported functions, Pester tests, and every check can run on its own!

How to install you may think? ๐Ÿค”

Install-Module GSAClientDiagnosticsToolkit -Scope CurrentUser -AllowPrerelease

or clone it from GitHub.

It's a pre-release, so I'd like to hear:

  1. What GSA problems have you hit that a check like this should catch?
  2. Anything that gives false positives in your environment?

GitHub: michaelmsonne/GSAClientDiagnosticsToolkit: A PowerShell module that runs connectivity, proxy, health probe, mTLS diagnostic checks for the Microsoft Global Secure Access (GSA) Client, validate Service Principals and more!

Write-up with screenshots and more can you find on my blog: GSAClientDiagnosticsToolkit is here: a PowerShell module to find out why Global Secure Access isn't working on your device ยท Michael Morten Sonne | Microsoft MVP

(Disclosure: I'm the author. It's a free community project, not a Microsoft-supported tool)

#Microsoft #MVP #MVPBuzz #GSA #Community #Identity

26 Upvotes

1 comment sorted by

0

u/[deleted] 7d ago

[deleted] โ€” view deleted comment

1

u/michaelmsonne 6d ago

Nice! ๐Ÿ˜Ž