-
Notifications
You must be signed in to change notification settings - Fork 3
CUPS SSL Certificates
James Perrin edited this page Jul 30, 2020
·
1 revision
- Login into the Linux server.
- Create a folder called
certs
and navigate to the new folder location.mkdir certs && cd certs
- Display the contents of the CUPS SSL folder
sudo ls -alt /etc/cups/ssl/
- Create copies of the current CUPS SSL certificate public and private parts appending the date when they were created.
sudo cp /etc/cups/ssl/server.key /etc/cups/ssl/server_YYYYMMDD.key && sudo cp /etc/cups/ssl/server.crt /etc/cups/ssl/server_YYYYMMDD.crt
- Using OpenSSL to create a Certificate Signing Request (CSR).
- Example
openssl req -new -newkey rsa:2048 -nodes -out server.csr -keyout server.key -subj "/C=US/ST=WA/L=Seattle/O=Your Company, Inc,/OU=IT/CN=www.example.com" -addext "subjectAltName=DNS:www.example.com"
- Using OpenSSL to review a CSR server.csr file.
openssl req -text -noout -in server.csr
- To display the contents of the CSR server.csr file.
cat server.csr
- Login into the Linux server.
- Navigate to the folder
certs
.cd certs
- Create and Open a file called
server.crt
touch server.crt && nano server.crt
- Paste in the contents from a Base64 encoded X.509 digital certificate
.cer
file into the fileserver.crt
. - Save and close the file
server.crt
. - Copy the server.key and server.crt files to the CUPS SSL certificate folder.
sudo cp server.key /etc/cups/ssl/server.key && sudo cp server.crt /etc/cups/ssl/server.crt
- Create copies of the new CUPS SSL certificate public and private parts appending the date when they were created.
sudo cp /etc/cups/ssl/server.key /etc/cups/ssl/server_YYYYMMDD.key && sudo cp /etc/cups/ssl/server.crt /etc/cups/ssl/server_YYYYMMDD.crt
- Log off Linux server.
exit