Skip to content
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

[SCAutoSensitivityLabelRule] Export does not use correct indentation which is causing issues with report generation (DSCParser) #4240

Closed
ykuijs opened this issue Jan 23, 2024 · 1 comment · Fixed by #4241
Assignees
Labels

Comments

@ykuijs
Copy link
Member

ykuijs commented Jan 23, 2024

Description of the issue

The export of the SCAutoSensitivityLabelRule resource does not create the code with correct indentation. This is causing DSCParser to incorrectly parse the resource, resulting in an incorrect report (HTML/Excel or JSON).

Have confirmed that correcting the indentation fixes the issue.

Microsoft 365 DSC Version

Dev

Which workloads are affected

Security & Compliance Center

The DSC configuration

SCAutoSensitivityLabelRule "SCAutoSensitivityLabelRule-General Data Protection Regulation (GDPR) High EXO-Exchange"
        {
            ApplicationId                       = $ConfigurationData.NonNodeData.ApplicationId;
            CertificateThumbprint               = $ConfigurationData.NonNodeData.CertificateThumbprint;
            ContentContainsSensitiveInformation = MSFT_SCDLPContainsSensitiveInformation
            {
                SensitiveInformation = @(
MSFT_SCDLPSensitiveInformation
            {
                name = 'Netherlands Citizen''s Service (BSN) Number'
                id = 'c5f54253-ef7e-44f6-a578-440ed67e946d'
                maxconfidence = '100'
                minconfidence = '85'
                classifiertype = 'Content'
                mincount = '51'
                maxcount = '-1'
            }
MSFT_SCDLPSensitiveInformation
            {
                name = 'Netherlands Driver''s License Number'
                id = '6247fbea-ab80-4be5-8233-308b7c031401'
                maxconfidence = '100'
                minconfidence = '75'
                classifiertype = 'Content'
                mincount = '51'
                maxcount = '-1'
            }
MSFT_SCDLPSensitiveInformation
            {
                name = 'Netherlands Passport Number'
                id = '61786727-bafd-45f6-94d9-888d815e228e'
                maxconfidence = '100'
                minconfidence = '75'
                classifiertype = 'Content'
                mincount = '51'
                maxcount = '-1'
            }
MSFT_SCDLPSensitiveInformation
            {
                name = 'Netherlands Physical Addresses'
                id = 'b3650e47-f2dc-4d29-a4fc-1b9154005c07'
                maxconfidence = '100'
                minconfidence = '75'
                classifiertype = 'Content'
                mincount = '51'
                maxcount = '-1'
            }
MSFT_SCDLPSensitiveInformation
            {
                name = 'Netherlands Tax Identification Number'
                id = '01f42a64-eba7-4892-a67b-398237e4ade2'
                maxconfidence = '100'
                minconfidence = '85'
                classifiertype = 'Content'
                mincount = '51'
                maxcount = '-1'
            }
MSFT_SCDLPSensitiveInformation
            {
                name = 'Netherlands Value Added Tax Number'
                id = '4f320d9b-4972-41ae-b337-88d499bb1ade'
                maxconfidence = '100'
                minconfidence = '85'
                classifiertype = 'Content'
                mincount = '51'
                maxcount = '-1'
            }
MSFT_SCDLPSensitiveInformation
            {
                name = 'International Banking Account Number (IBAN)'
                id = 'e7dc4711-11b7-4cb0-b88b-2c394a771f0e'
                maxconfidence = '100'
                minconfidence = '85'
                classifiertype = 'Content'
                mincount = '51'
                maxcount = '-1'
            }
            )            };
            Disabled                            = $False;
            DocumentIsPasswordProtected         = $False;
            DocumentIsUnsupported               = $False;
            Ensure                              = "Present";
            ExceptIfDocumentIsPasswordProtected = $False;
            ExceptIfDocumentIsUnsupported       = $False;
            ExceptIfProcessingLimitExceeded     = $False;
            Name                                = "General Data Protection Regulation (GDPR) High EXO";
            Policy                              = "Demo AutoLabeling High Restrictions";
            ProcessingLimitExceeded             = $False;
            ReportSeverityLevel                 = "Low";
            TenantId                            = $OrganizationName;
            Workload                            = "Exchange";
        }

Verbose logs showing the problem

N/A

Environment Information + PowerShell Version

PSv5.1
@ykuijs ykuijs added Bug Something isn't working Security & Compliance Center labels Jan 23, 2024
@ykuijs ykuijs self-assigned this Jan 23, 2024
@ykuijs
Copy link
Member Author

ykuijs commented Jan 23, 2024

Already working on a fix. Will submit a PR shortly.

ykuijs added a commit to ykuijs/Microsoft365DSC that referenced this issue Jan 23, 2024
NikCharlebois added a commit that referenced this issue Jan 24, 2024
Fixed issue in SCAutoSensitivityLabelRule (#4240)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant