Authentication

The EDK cmdlets support authentication using SSH to enable secure communication with the Crestron devices. The following key parameters are used to enable secure communication:

  • Secure Switch
  • Username
  • Password
  • Port

The secure switch directs the cmdlets to use a secure socket. The switch can be also be used with default credentials to open a secure socket. This allows using a secure link without enabling the authentication. If authentication is enabled, use the username and password to secure the link; otherwise, an exception is displayed.

For cmdlets that support pipeline input, such as Send-CrestronProgram, all the devices on the list should have the same mode of operation. The authentication for all the devices should be either on or off, and the credentials should be the same. In case the mode of operation is not the same across all the devices, break the code into different groups depending upon the same configuration.

Use the port parameter to secure a link if the CTPPort or the SSHPort of the device is changed. The default port is 22.

For example:

Use the following cmdlet to run the Invoke-CrestronCommand and authentication:

Copy
Invoke-CrestronCommand -Device 'CP3-7F123456' -Command 'INFO' ` -Secure -Username 'admin' -Password 'pa$$w0rd'