Note

Access to this page requires authorization. You can try signing in or .

Access to this page requires authorization. You can try .

Add-SignerRule

Module:
ConfigCI Module

Creates a signer rule and adds it to a policy.

Syntax

Certificate

Add-SignerRule
 -FilePath <String>
 -CertificatePath <String>
 [-Kernel]
 [-User]
 [-Update]
 [-Supplemental]
 [-Deny]
 [<CommonParameters>]

CertStore

Add-SignerRule
 -FilePath <String>
 -CertStorePath <String>
 [-Kernel]
 [-User]
 [-Update]
 [-Supplemental]
 [-Deny]
 [<CommonParameters>]

Description

The Add-SignerRule cmdlet creates a signer rule based on a certificate, and then adds the rule to a Code Integrity policy. By default, this cmdlet creates allow rules. Specify at least one scenario for the rule in the policy from the following scenarios:

  • User
  • Kernel
  • Update

Examples

Example 1: Create and add a signer rule for User mode

PS C:\> Add-SignerRule -FilePath '.\Policy.xml' -CertificatePath '.\certificate07.cer' -User

This command generates a signer rule for the certificate in certificate07.cer. The command adds the rule to policy.xml for the User mode scenario.

Parameters

-CertificatePath

Specifies the path of a certificate (.cer) file that this cmdlet uses for the rule.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False
Aliases:c

Parameter sets

-CertStorePath

Specifies the path to a certificate store to export certificates into the policy.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

-Deny

Indicates that this cmdlet creates a deny rule instead of the default allow rule.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

-FilePath

Specifies the path of the policy .xml file to which this cmdlet adds the rule.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False
Aliases:f

Parameter sets

-Kernel

Indicates that this cmdlet adds the rule as a Kernel mode rule. You can add a rule as more than one scenario.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

-Supplemental

Indicates that this cmdlet adds the rule as a Supplemental policy signers rule. You can add a rule as more than one scenario.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

-Update

Indicates that this cmdlet adds the rule as an Update policy signers rule. You can add a rule as more than one scenario.

Update policy signers rules to determine which signers can sign a policy in signed policy scenario.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

-User

Indicates that this cmdlet adds the rule as a User mode rule. You can add a rule as more than one scenario.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

Related Links


Feedback

Was this page helpful?