Skip to content

Failing to connect to defender #1691

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
zachurrutia opened this issue May 7, 2025 · 3 comments
Open

Failing to connect to defender #1691

zachurrutia opened this issue May 7, 2025 · 3 comments
Labels
public-reported This issue is reported by the public users of the tool.

Comments

@zachurrutia
Copy link

Initializing SCuBA shows all modules are up to date.
Using an account assigned with Exchange Administrator role.

Recreate Issue
When running the invoke-scuba command with the defender product, I am receiving the following errors

WARNING: Error retrieving Tenant details using Get-EXOTenantDetail The term 'Get-OrganizationConfig' is not recognized as a name of a cmdlet, function, script file, or executable program.
Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
Write-Error: Error connecting to ExchangeOnline. Cannot validate argument on parameter 'M365Environment'. The argument is null or empty. Provide an argument that is not null or empty, and then try the command
again.
WARNING: Error running Get-AdminAuditLogConfig. The term 'Get-AdminAuditLogConfig' is not recognized as a name of a cmdlet, function, script file, or executable program.
Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
WARNING: Resulting JSON is truncated as serialization has exceeded the set depth of 2.
Exception: Fatal Error involving the Report Creation.              Ending ScubaGear execution. See the exception message for more details: Cannot validate argument on parameter 'Config'. The argument is null
or empty. Provide an argument that is not null or empty, and then try the command again.

I ran a Disconnect-SCuBATenant command and receiving the same results.

@buidav buidav added the public-reported This issue is reported by the public users of the tool. label May 7, 2025
@buidav
Copy link
Collaborator

buidav commented May 7, 2025

Hello, @zachurrutia

  • What type of tenant are your running against Commercial, GCC, or GCC High?
  • What PowerShell version are you running? PowerShell 5.1 or 7?
  • What's the OS of the system you're running on? Windows 10, 11, Server 2019 etc?

@zachurrutia
Copy link
Author

zachurrutia commented May 8, 2025 via email

@buidav
Copy link
Collaborator

buidav commented May 10, 2025

@zachurrutia ScubaGear currently only supports up to PowerShell 5.1
This is because the underlying Microsoft PowerShell modules ScubaGear uses (Exchange/Defender is one of them) still do not support PowerShell 7+ fully.
Please rerun on PowerShell 5.1 and let us know if there error persists.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
public-reported This issue is reported by the public users of the tool.
Projects
None yet
Development

No branches or pull requests

2 participants