Who has Registered for SSPR
Published Nov 01 2019 12:14 PM 194 Views
Microsoft

First published on MSDN on Oct 08, 2014

The Following script can be used to determine who has Registered for Self Service Password Reset for Forefront Identity Manager 2010 R2 Special thanks to Markus Vilcinskas

 

### http://social.technet.microsoft.com/wiki/contents/articles/3616.how-to-use-powershell-to-export-all... ###

 


set-variable -name URI -value " http://localhost:5725/resourcemanagementservice' " -option constant

 

set-variable -name CSV -value "RegistredResetPassUsers.csv"

 

clear

 

If(@(Get-PSSnapin | Where-Object {$_.Name -eq "FIMAutomation"} ).count -eq 0) {Add-PSSnapin FIMAutomation}

 

$WFDFilter = "/WorkflowDefinition[DisplayName='Password Reset AuthN Workflow']"

 

$curObjectWFD = export-fimconfig -uri $URI –onlyBaseResources -customconfig ($WFDFilter) -ErrorVariable Err -ErrorAction SilentlyContinue

 

$WFDObjectID = (($curObjectWFD.ResourceManagementObject.ResourceManagementAttributes | Where-Object {$_.AttributeName -eq "ObjectID"}).value).split(":")[2]

 

$Filter = "/Person[AuthNWFRegistered = '$WFDObjectID']"

 

$curObject = export-fimconfig -uri $URI –onlyBaseResources -customconfig ($Filter) -ErrorVariable Err -ErrorAction SilentlyContinue

 

[array]$users = $null

 

foreach($Object in $curObject)

 

{

 

$ResetPass = New-Object PSObject

 

$UserDisplayName = (($Object.ResourceManagementObject.ResourceManagementAttributes | Where-Object {$_.AttributeName -eq "DisplayName"}).Value)

 

$ResetPass | Add-Member NoteProperty "DisplayName" $UserDisplayName

 

$Users += $ResetPass

 

}

 

$users | export-csv -path $CSV

 

 

 

## http://blogs.msdn.com/connector_space ##

 

RegistredResetPassUsers.ps1

Version history
Last update:
‎Feb 20 2020 12:21 PM
Updated by: