123456789101112131415161718192021222324252627282930313233 |
- #!/bin/sh
- # *********************************************************************************************************************************
- # * Licensed Materials - Property of IBM *
- # * IBM Cognos Products: DLS *
- # * (C) Copyright IBM Corp. 2005, 2021 *
- # * US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. *
- # *********************************************************************************************************************************
- # *************** DLS SSL certificate import tool *********************
- # ** This tool is designed to import a SSL certificate in IBM Cognos Java Keystore
- # ********************************************************************
- # NOTE:
- # if successful this message will be shown: Certificate was added to keystore
- # if already imported keytool error: java.lang.Exception: Certificate not imported, alias <DLSKeystore> already exists
- if [[ -z "$1" ]]; then
- echo --------------------------------------------------------------
- echo Usage: $0 SSL_Certificate_PATH
- echo.
- echo e.g.
- echo.
- echo $0 /mailserver_ssl_keys/certificate.crt
- echo --------------------------------------------------------------
- exit 1
- fi
- cd ../ibm-jre/jre/bin
- echo importing certificate from $1
- keytool -import -alias DLSKeystore -file $1 -keystore ../lib/security/cacerts -storepass changeit -noprompt
- cd ../../../bin
- echo Done.
- exit 1
|