Wondering whether anyone has come across this and been able to find a workaround. When I try to run
Import-Module dbatools
(or any of the functions within the dbatools module), it is blocked by Carbon Black Cloud. The error in the ISE includes the text: "This script contains malicious content and has been blocked by your antivirus software." It happens on machines where it used to run. I happens even after I pull down a fresh copy of dbatools for their GitHub repo. I tried the tack of installing the module (vs importing the module) and that worked, but the functions are still blocked when I try to run them. It only seems to happen on Windows Server 2019 (Carbon Black ignores it on Windows Server 2016).
In case it matters, dbatools is digitally signed.
Based on my experience, I was able to get around using following workarounds:
PS: Not a security advice. Just a workaround to work through.