Skip to content

Commit

Permalink
Merge pull request #1365 from microsoft/Dev
Browse files Browse the repository at this point in the history
Release 1.21.804.1
  • Loading branch information
NikCharlebois authored Aug 5, 2021
2 parents 921029d + e5e62f0 commit 66b1ed9
Show file tree
Hide file tree
Showing 181 changed files with 1,999 additions and 1,104 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/AzureCloud - Full-Circle - SC.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,6 @@ jobs:
$GlobalAdminAccount = New-Object System.Management.Automation.PSCredential ($env:PUBLIC_USERNAME, $GlobalAdminPassword)
Set-M365DSCTelemetryOption -Enabled $false
Write-Verbose -Message "Trying to connect to SC"
Test-MSCloudLogin -Platform SecurityComplianceCenter -CloudCredential $GlobalAdminAccount
Connect-M365Tenant -Workload SecurityComplianceCenter -Credential $GlobalAdminAccount
Write-Verbose -Message "Connected to SC"
Export-M365DSCConfiguration -Quiet -GlobalAdminAccount $GlobalAdminAccount -Path "." -FileName 'ExtractedSPO.ps1' -Workload 'SC' -Verbose
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
# Change log for Microsoft365DSC

# 1.21.804.1

* SCDLPComplianceRule
* Fixed issue where SCDLPCompliance rule failed when using senstitivy labels;
* DEPENDENCIES;
* Updated MSCloudLoginAssistant to version 1.0.62;
* MISC
* Added support for ApplicationSecret in SPO resources;
* Revamped the entire display from an Export;

# 1.21.728.1

* DEPENDENCIES;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ function Get-TargetResource
$CertificateThumbprint
)

$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' `
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' `
-InboundParameters $PSBoundParameters

Write-Verbose -Message "Getting configuration of Azure AD Application"
Expand Down Expand Up @@ -595,7 +595,7 @@ function Export-TargetResource
$CertificateThumbprint
)
#region Telemetry
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
$data = [System.Collections.Generic.Dictionary[[String], [String]]]::new()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ function Get-TargetResource
)

Write-Verbose -Message "Getting configuration of AzureAD Conditional Access Policy"
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

#region Telemetry
$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
Expand Down Expand Up @@ -1793,7 +1793,7 @@ function Export-TargetResource
$CertificateThumbprint
)
#region Telemetry
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
$data = [System.Collections.Generic.Dictionary[[String], [String]]]::new()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ function Get-TargetResource
Add-M365DSCTelemetryEvent -Data $data
#endregion

$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

$nullReturn = $PSBoundParameters
$nullReturn.Ensure = "Absent"
Expand Down Expand Up @@ -280,7 +280,7 @@ function Export-TargetResource
$CertificateThumbprint
)

$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

#region Telemetry
$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ function Get-TargetResource
)

Write-Verbose -Message "Getting configuration of AzureAD Groups Naming Policy"
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

#region Telemetry
$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
Expand Down Expand Up @@ -358,7 +358,7 @@ function Export-TargetResource
[System.String]
$CertificateThumbprint
)
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

#region Telemetry
$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
Expand All @@ -373,7 +373,7 @@ function Export-TargetResource

try
{
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters
$Params = @{
ApplicationId = $ApplicationId
TenantId = $TenantId
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ function Get-TargetResource
)

Write-Verbose -Message "Getting configuration of AzureAD Group"
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

#region Telemetry
$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
Expand Down Expand Up @@ -455,7 +455,7 @@ function Export-TargetResource
[System.String]
$CertificateThumbprint
)
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

#region Telemetry
$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ function Get-TargetResource
$CertificateThumbprint
)

$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

Write-Verbose -Message "Getting configuration of AzureAD Groups Lifecycle Policy"
#region Telemetry
Expand Down Expand Up @@ -195,7 +195,7 @@ function Set-TargetResource
Add-M365DSCTelemetryEvent -Data $data
#endregion

$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

try
{
Expand Down Expand Up @@ -353,7 +353,7 @@ function Export-TargetResource
[System.String]
$CertificateThumbprint
)
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

#region Telemetry
$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ function Get-TargetResource
)

Write-Verbose -Message "Getting configuration of AAD Named Location"
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

#region Telemetry
$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
Expand Down Expand Up @@ -334,7 +334,7 @@ function Export-TargetResource
[System.String]
$CertificateThumbprint
)
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

#region Telemetry
$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
Expand All @@ -349,10 +349,18 @@ function Export-TargetResource

$dscContent = ''
$i = 1
Write-Host "`r`n" -NoNewline

try
{
$AADNamedLocations = Get-AzureADMSNamedLocationPolicy -ErrorAction Stop
if ($AADNamedLocations.Length -eq 0)
{
Write-Host $Global:M365DSCEmojiGreenCheckMark
}
else
{
Write-Host "`r`n" -NoNewline
}
foreach ($AADNamedLocation in $AADNamedLocations)
{
Write-Host " |---[$i/$($AADNamedLocations.Count)] $($AADNamedLocation.DisplayName)" -NoNewline
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ function Get-TargetResource
)

Write-Verbose -Message "Getting configuration of AzureAD Policy"
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

#region Telemetry
$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
Expand Down Expand Up @@ -317,7 +317,7 @@ function Export-TargetResource
[System.String]
$CertificateThumbprint
)
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

#region Telemetry
$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
Expand All @@ -332,13 +332,21 @@ function Export-TargetResource

$dscContent = ''
$i = 1
Write-Host "`r`n" -NoNewline
try
{
$AADPolicys = Get-AzureADPolicy -ErrorAction Stop
foreach ($AADPolicy in $AADPolicys)
[array]$AADPolicies = Get-AzureADPolicy -ErrorAction Stop

if ($AADPolicies.Length -eq 0)
{
Write-Host $Global:M365DSCEmojiGreenCheckMark
}
else
{
Write-Host "`r`n" -NoNewline
}
foreach ($AADPolicy in $AADPolicies)
{
Write-Host " |---[$i/$($AADPolicys.Count)] $($AADPolicy.DisplayName)" -NoNewline
Write-Host " |---[$i/$($AADPolicies.Count)] $($AADPolicy.DisplayName)" -NoNewline
$Params = @{
GlobalAdminAccount = $GlobalAdminAccount
ApplicationId = $ApplicationId
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ function Get-TargetResource
)

Write-Verbose -Message "Getting configuration of Azure AD role definition"
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' `
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' `
-InboundParameters $PSBoundParameters
#region Telemetry
$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
Expand Down Expand Up @@ -352,7 +352,7 @@ function Export-TargetResource
[System.String]
$CertificateThumbprint
)
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

#region Telemetry
$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ function Get-TargetResource
)

Write-Verbose -Message "Getting configuration of Azure AD ServicePrincipal"
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' `
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' `
-InboundParameters $PSBoundParameters

#region Telemetry
Expand Down Expand Up @@ -449,7 +449,7 @@ function Export-TargetResource
[System.String]
$CertificateThumbprint
)
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

#region Telemetry
$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ function Get-TargetResource
)

Write-Verbose -Message "Getting configuration of AzureAD Tenant Details"
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

#region Telemetry
$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
Expand Down Expand Up @@ -292,7 +292,7 @@ function Export-TargetResource
[System.String]
$CertificateThumbprint
)
$ConnectionMode = New-M365DSCConnection -Platform 'AzureAD' -InboundParameters $PSBoundParameters
$ConnectionMode = New-M365DSCConnection -Workload 'AzureAD' -InboundParameters $PSBoundParameters

#region Telemetry
$ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,13 +58,13 @@ function Get-TargetResource

if ($Global:CurrentModeIsExport)
{
$ConnectionMode = New-M365DSCConnection -Platform 'ExchangeOnline' `
$ConnectionMode = New-M365DSCConnection -Workload 'ExchangeOnline' `
-InboundParameters $PSBoundParameters `
-SkipModuleReload $true
}
else
{
$ConnectionMode = New-M365DSCConnection -Platform 'ExchangeOnline' `
$ConnectionMode = New-M365DSCConnection -Workload 'ExchangeOnline' `
-InboundParameters $PSBoundParameters
}

Expand Down Expand Up @@ -207,7 +207,7 @@ function Set-TargetResource
Add-M365DSCTelemetryEvent -Data $data
#endregion

$ConnectionMode = New-M365DSCConnection -Platform 'ExchangeOnline' `
$ConnectionMode = New-M365DSCConnection -Workload 'ExchangeOnline' `
-InboundParameters $PSBoundParameters

$AcceptedDomainParams = @{
Expand Down Expand Up @@ -336,7 +336,7 @@ function Export-TargetResource
[System.Management.Automation.PSCredential]
$CertificatePassword
)
$ConnectionMode = New-M365DSCConnection -Platform 'ExchangeOnline' `
$ConnectionMode = New-M365DSCConnection -Workload 'ExchangeOnline' `
-InboundParameters $PSBoundParameters `
-SkipModuleReload $true
#region Telemetry
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,13 @@ function Get-TargetResource

if ($Global:CurrentModeIsExport)
{
$ConnectionMode = New-M365DSCConnection -Platform 'ExchangeOnline' `
$ConnectionMode = New-M365DSCConnection -Workload 'ExchangeOnline' `
-InboundParameters $PSBoundParameters `
-SkipModuleReload $true
}
else
{
$ConnectionMode = New-M365DSCConnection -Platform 'ExchangeOnline' `
$ConnectionMode = New-M365DSCConnection -Workload 'ExchangeOnline' `
-InboundParameters $PSBoundParameters
}

Expand Down Expand Up @@ -203,7 +203,7 @@ function Set-TargetResource
Add-M365DSCTelemetryEvent -Data $data
#endregion

$ConnectionMode = New-M365DSCConnection -Platform 'ExchangeOnline' `
$ConnectionMode = New-M365DSCConnection -Workload 'ExchangeOnline' `
-InboundParameters $PSBoundParameters

$NewActiveSyncDeviceAccessRuleParams = @{
Expand Down Expand Up @@ -360,7 +360,7 @@ function Export-TargetResource
[System.Management.Automation.PSCredential]
$CertificatePassword
)
$ConnectionMode = New-M365DSCConnection -Platform 'ExchangeOnline' `
$ConnectionMode = New-M365DSCConnection -Workload 'ExchangeOnline' `
-InboundParameters $PSBoundParameters `
-SkipModuleReload $true

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,13 +58,13 @@ function Get-TargetResource

if ($Global:CurrentModeIsExport)
{
$ConnectionMode = New-M365DSCConnection -Platform 'ExchangeOnline' `
$ConnectionMode = New-M365DSCConnection -Workload 'ExchangeOnline' `
-InboundParameters $PSBoundParameters `
-SkipModuleReload $true
}
else
{
$ConnectionMode = New-M365DSCConnection -Platform 'ExchangeOnline' `
$ConnectionMode = New-M365DSCConnection -Workload 'ExchangeOnline' `
-InboundParameters $PSBoundParameters
}

Expand Down Expand Up @@ -208,7 +208,7 @@ function Set-TargetResource
Add-M365DSCTelemetryEvent -Data $data
#endregion

$ConnectionMode = New-M365DSCConnection -Platform 'ExchangeOnline' `
$ConnectionMode = New-M365DSCConnection -Workload 'ExchangeOnline' `
-InboundParameters $PSBoundParameters

$NewAddressBookPolicyParams = @{
Expand Down Expand Up @@ -372,7 +372,7 @@ function Export-TargetResource
[System.Management.Automation.PSCredential]
$CertificatePassword
)
$ConnectionMode = New-M365DSCConnection -Platform 'ExchangeOnline' `
$ConnectionMode = New-M365DSCConnection -Workload 'ExchangeOnline' `
-InboundParameters $PSBoundParameters `
-SkipModuleReload $true

Expand Down
Loading

0 comments on commit 66b1ed9

Please sign in to comment.