Skip to content

Latest commit

 

History

History
251 lines (181 loc) · 7.68 KB

Allow PDF_XPS Printer - File Evidence.md

File metadata and controls

251 lines (181 loc) · 7.68 KB

Device control policy sample: Allow PDF_XPS Printer - File Evidence

Description: This is a policy.
Device Type: Windows Printer

A device control policy is a combination of policy rules, groups and settings.
This sample is based on the sample files.
To configure the sample, follow the deployment instructions.

Policy Rules

Name Devices Rule Type Access Notification Conditions
Included Excluded Print
Allow PDF and XPS Printing
    Allow Create file evidence with file (8) -
    Audit Allowed 📄 Send event (2) -

    Groups

    PDF_XPS Printer

    This is a group of type Device. The match type for the group is MatchAny.

    Property Value
    PrinterConnectionId File
    View XML
    <Group Id="{e5170dfb-19a9-4466-8109-d36c9c912b4e}" Type="Device">
    	<!-- ./Vendor/MSFT/Defender/Configuration/DeviceControl/PolicyGroups/%7Be5170dfb-19a9-4466-8109-d36c9c912b4e%7D/GroupData -->
    	<Name>PDF_XPS Printer</Name>
    	<MatchType>MatchAny</MatchType>
    	<DescriptorIdList>
    		<PrinterConnectionId>File</PrinterConnectionId>
    	</DescriptorIdList>
    </Group>

    Settings

    Setting Name Setting Value Description Documentation
    DefaultEnforcement Deny Control Device Control default enforcement. This is the enforcement applied if there are no policy rules present or at the end of the policy rules evaluation none were matched. documentation
    DeviceControlEnabled True Enables/disables device control documentation

    Files

    This policy is based on information in the following files:

    Deployment Instructions

    Device control policy rules and groups can be deployed through the following management tools:

    Windows

    Intune UX

    Intune UX is not supported for this policy because:

    • Create file evidence with file is an unsupported notification.

    Use Intune custom settings to deploy the policy instead.

    Group Policy (GPO)

    Define device control policy groups
    1. Go to Computer Configuration > Administrative Templates > Windows Components > Microsoft Defender Antivirus > Device Control > Define device control policy groups.
    2. Save the XML below to a network share.
    <Groups>
    	<Group Id="{e5170dfb-19a9-4466-8109-d36c9c912b4e}" Type="Device">
    		<!-- ./Vendor/MSFT/Defender/Configuration/DeviceControl/PolicyGroups/%7Be5170dfb-19a9-4466-8109-d36c9c912b4e%7D/GroupData -->
    		<Name>PDF_XPS Printer</Name>
    		<MatchType>MatchAny</MatchType>
    		<DescriptorIdList>
    			<PrinterConnectionId>File</PrinterConnectionId>
    		</DescriptorIdList>
    	</Group>
    </Groups>
    1. In the Define device control policy groups window, select Enabled and specify the network share file path containing the XML groups data.
    Define device control policy rules
    1. Go to Computer Configuration > Administrative Templates > Windows Components > Microsoft Defender Antivirus > Device Control > Define device control policy rules.
    2. Save the XML below to a network share.
    <PolicyRules>
    	<PolicyRule Id="{07fb98fd-f25b-4aec-bb99-69d4abd4ec4d}" >
    		<!-- ./Vendor/MSFT/Defender/Configuration/DeviceControl/PolicyRules/%7B07fb98fd-f25b-4aec-bb99-69d4abd4ec4d%7D/RuleData -->
    		<Name>Allow PDF and XPS Printing</Name>
    		<IncludedIdList>
    			<GroupId>{e5170dfb-19a9-4466-8109-d36c9c912b4e}</GroupId>
    		</IncludedIdList>
    		<ExcludedIdList>
    		</ExcludedIdList>
    		<Entry Id="{e8cc55ec-17a8-4900-8df5-1af801342e9d}">
    			<Type>Allow</Type>
    			<AccessMask>64</AccessMask>
    			<Options>8</Options>
    		</Entry>
    		<Entry Id="{2b410b9c-c940-42ec-be1c-1fcb8cc32bc4}">
    			<Type>AuditAllowed</Type>
    			<AccessMask>64</AccessMask>
    			<Options>2</Options>
    		</Entry>
    	</PolicyRule>
    </PolicyRules>
    1. In the Define device control policy rules window, select Enabled, and enter the network share file path containing the XML rules data.

    Intune Custom Settings

    Create custom intune configuration
    1. Navigate to Devices > Configuration profiles
    2. Click Create (New Policy)
    3. Select Platform "Windows 10 and Later"
    4. Select Profile "Templates"
    5. Select Template Name "Custom"
    6. Click "Create"
    7. Under Name, enter **
    8. Optionally, enter a description
    9. Click "Next"
    Add a row for Allow PDF and XPS Printing
    1. Click "Add"

    2. For Name, enter Allow PDF and XPS Printing

    3. For Description, enter **

    4. For OMA-URI, enter ./Vendor/MSFT/Defender/Configuration/DeviceControl/PolicyRules/%7B07fb98fd-f25b-4aec-bb99-69d4abd4ec4d%7D/RuleData

    5. For Data type, select String (XML File)

    6. For Custom XML, select windows/printer/Intune OMA-URI/Allow PDF_XPS Printer - File Evidence.xml

    7. Click "Save"

    Add a row for PDF_XPS Printer
    1. Click "Add"

    2. For Name, enter PDF_XPS Printer

    3. For Description, enter **

    4. For OMA-URI, enter ./Vendor/MSFT/Defender/Configuration/DeviceControl/PolicyGroups/%7Be5170dfb-19a9-4466-8109-d36c9c912b4e%7D/GroupData

    5. For Data type, select String (XML File)

    6. For Custom XML, select windows/printer/Intune OMA-URI/PDF_XPS Printer.xml

    7. Click "Save"

    Add a row for DefaultEnforcement
    1. Click "Add"

    2. For Name, enter DefaultEnforcement

    3. For Description, enter **

    4. For OMA-URI, enter ./Vendor/MSFT/Defender/Configuration/DefaultEnforcement

    5. For Data type, select Integer

    6. For Value, enter 2

    7. Click "Save"

    Add a row for DeviceControlEnabled
    1. Click "Add"

    2. For Name, enter DeviceControlEnabled

    3. For Description, enter **

    4. For OMA-URI, enter ./Vendor/MSFT/Defender/Configuration/DeviceControlEnabled

    5. For Data type, select Integer

    6. For Value, enter 1

    7. Click "Save"