Forum / Remote Desktop Manager - PowerShell Repository

Update Session Credential to use a specific Private Connection entry?

  • Create an Issue
  • Cancel

Hi All

Couple weeks back all of my Group sessions that were assigned a specific Private Connection entry just lost that information (don't know why nor didn't notice when, as when I figured out it was generalized, couple days had passed). Don't want to troubleshoot the why, just want to fix.

In PowerShell, I can figure out the list of folders that are affected
Get-RDMSession | ?{ (-not $_.CredentialConnectionID) -and $_.ConnectionType -eq 'Group' -and $_.OverrideMode -ne 'User'}

Is there a way to pipe this into a Set-RDMSession and use a specific Private Credential?

Tkx

Clock4 yrs

Hello,

You can refer to these posts to set the CredentialConnectionID property.

https://forum.devolutions.net/topic23912-programmatically-assigning-various-credentials-to-entries.aspx
https://forum.devolutions.net/topic18904-how-to-programatically-change-group-fiolder-properties-and-session-properties.aspx#post72155


Best regards,



Érica Poirier

signaturesignature

Clock4 yrs

Hi

I started with those two smile Doesn't say how to get the private credential information.

Tkx

Clock4 yrs

Hello,

Actually, you can set the Credentials to the value Private vault search, but you will have to fill in the search field with the correct name of the Private Vault credential name.

Here is an example in PowerShell :


$sessions = Get-RDMSession | ?{ (-not $_.CredentialConnectionID) -and $_.ConnectionType -eq 'Group' -and $_.OverrideMode -ne 'User'}
foreach ($sess in $sessions) {
$sess.CredentialConnectionID = "88E4BE76-4C5B-4694-AA9C-D53B7E0FE0DC"
$sess.CredentialPrivateVaultSearchString = "MyPrivateCred"
}
Set-RDMSession $sessions

Please note that the value for the CredentialConnectionID property for a Private Vault search is "88E4BE76-4C5B-4694-AA9C-D53B7E0FE0DC".
The CredentialPrivateVaultSearchString value can be unset or it can be an exact or a part of a private vault entry name.

Best regards,



Érica Poirier

signaturesignature

Clock4 yrs

Bonsoir Erica

OK not quite what I had in mind although works.

That said would it be possible to change the "User Specific Settings" like in the screenshot attached?

Merci

2016-05-31_15-39-05.png
Clock4 yrs