Skip to content

Instantly share code, notes, and snippets.

View AmolVyawahare's full-sized avatar

AmolVyawahare

View GitHub Profile
@joegasper
joegasper / ConvertFrom-DN
Last active June 5, 2024 02:37
Convert between DistinguishedName and CanonicalName
#Updated ConvertFrom-DN to support container objects
function ConvertFrom-DN {
[cmdletbinding()]
param(
[Parameter(Mandatory, ValueFromPipeline = $True, ValueFromPipelineByPropertyName = $True)]
[ValidateNotNullOrEmpty()]
[string[]]$DistinguishedName
)
process {