Skip to main content

Agentless assessment

Get a shadow-AI and third-party-app risk report into NobleCloak Discover without connecting your identity provider or Google Workspace to us. You run a small open-source script on your own machine against data you already have access to, review the file it writes, and upload that file yourself. Nothing leaves your machine until you upload it. See the privacy statement for exactly what is in the file and what never leaves.

This page has everything you need: pick a script, download it, run it, upload the result.

1. Pick your script​

Your directoryUseNeeds
Google Workspacenc-export.pyPython 3.9+, Admin console access
Microsoft Entra ID, live from Graphnc-export-entra.ps1PowerShell 7+, consent to three read-only scopes
Microsoft Entra ID, from Graph Explorer exportsnc-export.pyPython 3.9+, Graph Explorer

2. Download and verify​

No code-signing is applied, so check the SHA-256 of what you downloaded before you run it. Each link goes straight to the release file.

Download (v0.1.1)SHA-256
nc-export.py635c5af758dea50e691e3fd32c265c8753209595d007521843edc793032c121d
nc-export-entra.ps192c14cc1924a7d8af925963a0a460313167c96b829bcec9988dc5a23ddd6c896

Verify on macOS or Linux with shasum -a 256 <file>, or on Windows with Get-FileHash <file> -Algorithm SHA256. A mismatch means do not run the script; contact support@noblecloak.com. The downloads page has the format spec, the SHA256SUMS.txt sidecar and how the checksums are produced.

3. Export and run​

You need: Python 3.9 or newer (no packages to install; macOS's built-in python3 is enough) and Google Admin console access to the audit logs and the Users list. On Windows, where python3 is often the Microsoft Store stub, use py nc-export.py ... instead.

  1. Export the OAuth log events. In the Admin console, open Reporting > Audit and investigation > OAuth log events, set the date range, then Download > CSV. Note the date range you chose and your console's UTC offset; you pass them in step 3. Google keeps OAuth Token log events for 6 months and admins can't change that, so an app authorized before then and never re-authorized since will not appear. The logs can also lag by up to a few hours, so grants from the last few hours may be missing. See Google's Data retention and lag times.

  2. Export the users (optional). Open Directory > Users > Download users > All user info columns > CSV. This gives the report an accurate userCountTotal. Skip it and that field is left null rather than guessed.

  3. Run the script from the folder you downloaded it into. Pass the CSV files exactly as downloaded; do not open and re-save them. The file names below are examples.

    python3 nc-export.py google \
    --audit-csv OauthLogEvents.csv \
    --users-csv users.csv \
    --export-window-start 2026-11-11T00:00:00-05:00 \
    --export-window-end 2026-11-18T23:59:59-05:00 \
    --out-dir ./out

    --audit-csv and --out-dir are required. --users-csv is optional. --export-window-start and --export-window-end go together: give the date range from step 1 with your UTC offset. Leave both out and the header's exportWindow is null; the script never guesses it from the event dates.

    Only Authorize events become grants. Other events in the download, such as Revoke, are left out, with a count printed to the terminal.

When the script finishes it prints:

Skipped rows: 0
Nothing has been sent anywhere. Review discover-export.ndjson, then upload it in the Discover app.

Skipped rows is always printed, even when it is 0. A row with a missing identity value is skipped with a warning rather than silently mangled.

4. Review and upload​

  1. Open ./out/discover-export.ndjson and read it. It is plain newline-delimited JSON; the export format page describes every field.
  2. Keep ./out/mapping.csv and ./out/salt.txt on your machine. They map the pseudonyms back to real users, and they are not meant to be shared.
  3. Go back to the setup wizard's Scan step. Under Export file (discover-export.ndjson), click Choose file, select discover-export.ndjson, then click Upload.

More detail per path, including what to do when something goes wrong: Google Workspace, Entra PowerShell, Entra Graph Explorer.

What this gives you​

An export-based report is a point-in-time snapshot:

  • It reflects the grants in the export you ran the script on. Nothing gets more current until you export and upload again.
  • For Google Workspace, the source is the OAuth log events the Admin console still holds. Google limits how long it keeps them, so an app authorized before that window and never re-authorized since will not appear.
  • Coverage is stated, not assumed. When the script cannot determine the total number of users or the export's time window, those fields are null in the file rather than guessed. The export format page shows what that looks like.

When to connect directly instead​

The Discover app also offers a direct connection to your identity provider, set up inside the app (look for Connect on the empty state). Choose it over this lane when you want a live view of grants, the sanctioned-app signal that tells a company-approved integration from a self-granted one, or continuous re-scanning without anyone re-running a script. This lane is for the opposite case: you want a report today, without connecting anything, and a snapshot is an acceptable trade.

Reference​