I'm running:
Get-AzExemptions -pacEnvironment "production"
against an existing pacEnvironment
I have verified that the script manages to retrieve all exemptions within the scope, the issue seems to be with the Helper function Output-PolicyExemptions
Expected behavior
My expectation is that the script will output a all exemptions in the scope of the pacEnvironment
Screenshots
===================================================================================================
Policy Resources found for EPAC environment 'production' at root scope /managementGroups/<GUID>
===================================================================================================
Policy counts:
BuiltIn = 3518
Managed (30) by:
This PaC = 30
Other PaC = 0
Unknown = 0
Inherited = 0
Excluded = 0
Policy Set counts:
BuiltIn = 130
Managed (12) by:
This PaC = 12
Other PaC = 0
Unknown = 0
Inherited = 0
Excluded = 0
Policy Assignment counts:
Managed (72) by:
This PaC = 24
Other PaC = 0
Unknown = 0
DfC Security Policies = 0
DfC Defender Plans = 48
With identity = 12
Excluded = 3
Policy Exemptions:
Managed (38) by:
This PaC = 37
Other PaC = 0
Unknown = 1
Expired = 0
Excluded = 0
===================================================================================================
Output Exemption list (38)
===================================================================================================
===================================================================================================
Output 0 Exemptions (all) for epac environment 'production'
===================================================================================================
EPAC Version
Currently on v10.2.2, but couldn't get it working with v9.1.5 either
Describe the bug I'm running the script against our
pacEnvironment
with a few exemptions, the output files contain an empty JSON array of exemptions:To Reproduce
I'm running:
Get-AzExemptions -pacEnvironment "production"
against an existingpacEnvironment
I have verified that the script manages to retrieve all exemptions within the scope, the issue seems to be with the Helper function
Output-PolicyExemptions
Expected behavior
My expectation is that the script will output a all exemptions in the scope of the
pacEnvironment
Screenshots
EPAC Version
Currently on
v10.2.2
, but couldn't get it working withv9.1.5
either