cancel
Showing results for 
Search instead for 
Did you mean: 
Create Post
Level 7

Sam Credential Password Modification

Hello,

I wanted to know if it is currently possible to modify the password of a SAM credential via the api?

I've found resources on modifying the password for wmi credentials, but nothing for Sam as of yet.

Also the credentials in the DB seem to be heavily encrypted so modifying them directly through the db does not seem to be an option.

 

0 Kudos
2 Replies
Level 13

Use the Orion.Credential entity and the UpdateUsernamePasswordCredentials action, like this (this is Python, but PowerShell is similar):

credParams = [
credentialID, --ID of a credential in Orion.Credential
CredentialName,
Username,
Password --plain text
]

swis.invoke(
'Orion.Credential',
'UpdateUsernamePasswordCredentials',
*credParams
)

0 Kudos

Ya I don't believe that verb works on SAM creds, when referencing the CredID it acts as if it doesn't exist.

Capture.PNG

 

The info at "https://github.com/solarwinds/OrionSDK/wiki/Credential-Management#update-userpassword-wmi-credentials" shows the creds must be a SNMP v1/v2 cred though that could just be a typo because i'm pretty sure I got it to work on regular Orion creds.

pcostello1_1-1593177034677.png

 

 

0 Kudos