capam_command : Mandatory parameters are missing when using remote CLI from PS script
search cancel

capam_command : Mandatory parameters are missing when using remote CLI from PS script

book

Article ID: 229611

calendar_today

Updated On:

Products

CA Privileged Access Manager (PAM)

Issue/Introduction

We are trying to use powershell scripts with remote CLI calls. It seemed to work in one environment, but doesn't work in another. We have a configuration file containing parameters including the PAM server name and additional parameters for the remote CLI commands. The command we are running has the right syntax and the list of parameters is correct, but when we run the script, we get error

.\capam_command : Mandatory parameters are missing

We submit the command as

Invoke-Expression "$Command"

with $Command as follows

.\capam_command capam=$CAPAMServerName adminUserId=$AdminUser adminPassword=$AdminPwd cmdName=...

$AdminUser and $AdminPwd are passed in as command line parameters

It doesn't matter which remote CLI command we run, we always get the same error.

 

 

Environment

Release : any

Component : PRIVILEGED ACCESS MANAGEMENT

Cause

The admin password contained special characters.

Resolution

Change the password of the PAM user to one that doesn't include special characters such as backslashes, quotes or dollar signs. Increase the length of the password as needed to retain its strength.