Using a batch file for Apache SSL certificate file operations
When creating Apache SSL certificates, there are several batch files to execute and files to copy. Optionally automate the process by creating and running a batch file.
Use the following sample set of batch commands as a template for the batch file. Replace <installation_path> with the actual installation directory used on the management server machine (C:\Program Files (x86)\Websense, by default).
@echo off
set HOME=<installation_path>\Web Security
set WORKING_DIR=%HOME%\apache\conf\ssl\automation call "%WORKING_DIR%\s1_newreq.bat"
call "%WORKING_DIR%\s2_server_key.bat" call "%WORKING_DIR%\s3_server_crt.bat" call "%WORKING_DIR%\s4_server_p12.bat"
@echo on
copy "%HOME%\apache\conf\ssl\output\server.key" "%HOME%\ apache\conf\ssl\ssl.key\server.key"
copy "%HOME%\apache\conf\ssl\output\server.crt" "%HOME%\ apache\conf\ssl\ssl.crt\server.cr"
copy "%HOME%\apache\conf\ssl\output\cakey.pem" "%HOME%\ apache\conf\ssl\private\cakey.pem"
copy "%HOME%\apache\conf\ssl\output\manager.p12" "%HOME%\ tomcat\conf\keystore\tomcat\manager.p12"