MQ Queue Manager SSL Checking Script

Hello everyone,

Newbie to the forum.

I have a requirement for a script to check Queue Manager SSL certificates - However I have no previous scripting skills what so ever. I need a script which from high level point of view does the following:

#For each Queue Manager on the server go to this directory
/var/mqm/qmgrs/QMGR1/ssl
#Create and Run unstash script against the *.sth file to get .kdb password
#execute unstash script then delete unstash script
#List all certs in the .kdb using unstashed password
#For each cert in the .kdb show the details of the cert
#Write output of cert details like common name, serial number, valid from, valid to & sha to a .csv file

I know the commands to individually and manually perform all these steps however like I said I have no previous scripting experience. How and where do I begin to even start scripting something like this?

Any help would be much appreciated.

If you know commands to do one queue manager, you are almost done.
That is your program and will probably be the biggest part of your script, depending on the error handling required.

You will start by considering what will be your variables in the program.

Since you have multiple queue managers, a variable and a loop is required for basic execution of your commands against multiple queue managers.

If you can post the commands and their output (obfuscate the data of course) for one queue manager, with your shell and operating system, that would be helpful to assist further.

Hope that helps
Regards
Peasant.