Unregisters object identifier (OID) information from local computer, Active Directory or both sources.
Unregister-ObjectIdentifier [-Value] <Oid2> [-UseActiveDirectory] [-Force] [-WhatIf] [-Confirm] [<CommonParameters>]
Unregisters object identifier (OID) information from local computer, Active Directory or both sources. Additionally, the command accepts pipeline input from the following commands: Get-ObjectIdentifier and Get-ObjectIdentifierEx.
In order the command to succeed the caller must be granted with:
1) local administrator permissions — if an OID is registered locally.
2) Enterprise Admins permissions, or delegated Write permissions on OID container in Active Directory, if 'UseActiveDirectory' switch is enabled.
OID container in Active Directory is located under: CN=Public Key Services, CN=Services, <Configuration Naming Context>.
Specifies an OID friendly name, value or System.Security.Cryptography.Oid2 object that contains information about OID to unregister. Only specified instance is unregistered. By default, the command attempts to unregister specified OID information from local machine only. In order to unregister OID information in Active Directory, use 'UseActiveDirectory' switch.
Required? | True |
Position? | 0 |
Default value | |
Accept pipeline input? | true (ByValue, ByPropertyName) |
Accept wildcard characters? | False |
Specifies whether to perform registration removal from Active Directory too.
Required? | False |
Position? | named |
Default value | |
Accept pipeline input? | false |
Accept wildcard characters? | True |
By default, the script explicitly prompts you whether you want to remove OID registration with selected values. If you want to implement silent (quiet) installations — specify this parameter to suppress any prompts during OID registration removal.
Required? | False |
Position? | named |
Default value | |
Accept pipeline input? | false |
Accept wildcard characters? | False |
Describes what would happen if you executed the command without actually executing the command.
Required? | False |
Position? | named |
Default value | |
Accept pipeline input? | false |
Accept wildcard characters? | False |
Prompts you for confirmation before executing the command.
Required? | False |
Position? | named |
Default value | |
Accept pipeline input? | false |
Accept wildcard characters? | False |
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, InformationAction, InformationVariable,
WarningAction, WarningVariable, OutBuffer, PipelineVariable and OutVariable.
For more information, see about_CommonParameters (https://go.microsoft.com/fwlink/?LinkID=113216).
System.Security.Cryptography.Oid2
None.
Author: Vadims Podans
Blog: https://www.sysadmins.lv
PS C:\> Unregister-ObjectIdentifier -Value "Remote Desktop Authentication" -UseActiveDirectory
Unregisters a custom OID that was previously registered in Active Directory.
PS C:\> Get-ObjectIdentifierEx -Value "Company smart card policy" -UseActiveDirectory | Unregister-ObjectIdentifier
Gets information about OID registration with friendly name 'Company smart card policy' and deletes all OID registrations from local system and Active Directory.
Get-ObjectIdentifier
Get-ObjectIdentifierEx
Register-ObjectIdentifier