Script recorder, Executing scripts, Displaying and deleting scripts – HP Secure Key Manager User Manual

Page 267: Installing certificates, 267 displaying and deleting scripts, 267 installing certificates

Advertising
background image

NOTE:

The Script Recorder takes care of all such formatting issues and hence is probably the best way to
create scripts initially.

Script recorder

The Script Recorder is started by typing in the command “record <script name>” as shown here:

hostname(script)#

record testscript

Recording to script testscript.

You can then type in any “show” or “configure” mode CLI commands and they will automatically be
written to the script specified in the correct format.

To stop the Script Recorder, type “no record” as show here:

hostname(script)# no record

Recording successfully stopped.

Executing scripts

To execute a script, you must first load it using the command “load <script name>”, as shown here:

hostname(script)# load testscript

Script testscript successfully loaded.

Once loaded, a script can either be stepped through (executed one line at a time), or the entire script
can be run. To step through a script, use the command “step”, as shown here:

hostname(script)# step

To run the entire script, use the command “go”, as shown here:

hostname(script)# go

Displaying and deleting scripts

To display the current scripts that have been created on the system, use the command “show script”.
To display the contents of a specified script, use the command “show script <script name>”, as shown
here:

hostname(script)# show script testscript

If you want to delete an existing script, use the command “no script <script name>” as shown here:

hostname(script)# no script testscript

Installing certificates

When you attempt to enter a command in a script that requires a certificate to be pasted in, the actual
certificate will not be stored in the script. Instead, the script will prompt you when it is run to paste in
the certificate.

Secure Key Manager

267

Advertising