Things To Do On Blank Server

Yes. We can provision a blank OVHcloud server and turn it into our own private Certificate Authority (CA). That server would issue certificates to MariaDB and the ServiceNow application server.

For our proof of concept, we don’t need FreeIPA, Active Directory Certificate Services, or a full PKI platform. OpenSSL is sufficient.

Proposed architecture

OVHcloud CA Server

Private CA signing key + CA certificate

Issues and signs certificates

MariaDB Server

Server certificate + private key

ServiceNow App Server

Client certificate + private key

MariaDB ↔ ServiceNow: verified mutual TLS

The CA server signs certificates. It does not need to participate in each database connection.

What we’d install on the blank CA server

Assuming another RHEL 9.8 server:

ComponentRequirement
RHEL 9.8Existing OS
OpenSSLRequired
OpenSSL CA configurationCreate
Private CA signing keyGenerate
Root CA certificateGenerate
Certificate signing directoryCreate
Web serverNot required
MariaDBNot required
JavaNot required
Running CA daemonNot required

Initial CA setup

First, confirm OpenSSL exists:

openssl version

Create the CA directory structure using an authorized administrative account:

sudo mkdir -p /opt/private-ca/{private,certs,csr,newcerts}

sudo chmod 700 /opt/private-ca/private

Generate the CA signing key:

sudo openssl genpkey \

  -algorithm RSA \

  -pkeyopt rsa_keygen_bits:4096 \

  -aes-256-cbc \

  -out /opt/private-ca/private/ca-key.pem

This prompts for a passphrase to protect the CA’s private key.

Generate the CA certificate:

sudo openssl req \

  -new -x509 \

  -sha256 \

  -days 3650 \

  -key /opt/private-ca/private/ca-key.pem \

  -out /opt/private-ca/certs/ca.pem \

  -subj “/CN=OVHcloud Private Test CA” \

  -addext “basicConstraints=critical,CA:TRUE” \

  -addext “keyUsage=critical,keyCertSign,cRLSign”

Now we have a private CA capable of signing certificates.

How certificates get issued

The preferred process is:

  1. MariaDB generates its own private key and certificate signing request (CSR).
  2. The CSR is transferred to the CA server.
  3. The CA signs the CSR with the MariaDB server identity and serverAuth usage.
  4. The signed certificate and public CA certificate are returned to MariaDB.
  5. Repeat for the ServiceNow application server, using clientAuth usage.

The private keys stay on their respective servers. Only CSRs and signed certificates are transferred.

The CA signing key stays on the CA server.

How this changes Anthony’s runbook

We insert a new phase before the existing Phase 2:

Phase 2A — Provision private CA server

  • Verify OpenSSL.
  • Create the private CA.
  • Generate the CA signing key and certificate.
  • Sign MariaDB’s CSR.
  • Sign the application’s CSR.

Then Anthony resumes the existing Phase 3 using:

[mariadb]

ssl_ca=/path/to/ca.pem

ssl_cert=/path/to/server-cert.pem

ssl_key=/path/to/server-key.pem

These are the files issued by our new CA.

One architectural decision

For the OVHcloud proof of concept, I’d use a dedicated CA server that can be shut down after issuing certificates.

That gives us a separate trust authority without introducing another always-running dependency. It also demonstrates how the client can use its own approved CA later in TEST/PROD.

We still need to configure MariaDB to require client certificates, verify both sides of TLS, and prove the connection fails without the required certificates under SELinux enforcing.

Comments

No comments yet. Why don’t you start the discussion?

Leave a Reply

Your email address will not be published. Required fields are marked *