Wildcard SSL Certificate Deployment: Using the Same Certificate Across Multiple Servers and IP Addresses


2 views

When deploying a wildcard SSL certificate (e.g., *.example.com) across multiple servers with different IP addresses, many developers wonder about the technical validity and implementation details. The answer is yes - a single wildcard certificate can indeed be installed on multiple servers and IP addresses, as long as all hostnames fall under the covered domain pattern.

Wildcard certificates are explicitly designed to secure multiple subdomains under a parent domain. The certificate's validity depends on:

  • Hostname matching the wildcard pattern (e.g., hostEU.example.com matches *.example.com)
  • Proper certificate installation on each server
  • Correct private key management

Consider this DNS setup:

hostEU.example.com  A  60.70.80.90
hostUS.example.com  A  200.210.220.240

To implement this properly:

1. Certificate Installation

On each server (EU and US instances), you would:

# For Apache
SSLCertificateFile /path/to/wildcard.crt
SSLCertificateKeyFile /path/to/wildcard.key
SSLCertificateChainFile /path/to/intermediate.crt

# For Nginx
ssl_certificate /path/to/wildcard_bundle.crt;
ssl_certificate_key /path/to/wildcard.key;

2. Key Considerations

  • Private Key Security: The same private key must be securely distributed to all servers
  • Certificate Bundling: Include intermediate certificates properly
  • SNI Support: Required when hosting multiple SSL sites on a single IP

Load Balancer Configurations

When using load balancers (AWS ALB, NGINX Plus, etc.), you typically:

# AWS CLI example for uploading cert
aws iam upload-server-certificate \
  --server-certificate-name star-example-com \
  --certificate-body file://wildcard.crt \
  --private-key file://wildcard.key \
  --certificate-chain file://intermediate.crt

Automation with Configuration Management

For infrastructure-as-code deployments:

# Ansible example
- name: Deploy wildcard certificate
  copy:
    src: "/ssl_certs/{{ inventory_hostname }}/"
    dest: "/etc/ssl/"
    owner: root
    group: root
    mode: '0600'

Remember that while technically valid, some organizations prefer separate certificates for security segmentation. The wildcard approach offers simplicity but requires careful key management.


Yes, your assumption is absolutely correct. A wildcard SSL certificate for *.example.com can indeed be installed on multiple servers with different IP addresses. This is one of the primary advantages of using wildcard certificates in distributed infrastructure.

Consider this DNS configuration:

hostEU.example.com  A  60.70.80.90
hostUS.example.com  A  200.210.220.240

Both servers can use the same wildcard certificate. Here's how you might configure it in Apache:

<VirtualHost *:443>
    ServerName hostEU.example.com
    SSLEngine on
    SSLCertificateFile /path/to/wildcard.crt
    SSLCertificateKeyFile /path/to/wildcard.key
    SSLCertificateChainFile /path/to/intermediate.crt
</VirtualHost>

<VirtualHost *:443>
    ServerName hostUS.example.com
    SSLEngine on
    SSLCertificateFile /path/to/wildcard.crt
    SSLCertificateKeyFile /path/to/wildcard.key
    SSLCertificateChainFile /path/to/intermediate.crt
</VirtualHost>
  • Geographically distributed servers
  • Load-balanced environments
  • Development/staging/production environments
  • Microservices architecture

While technically possible, there are some factors to consider:

  1. Private Key Security: The same private key will be on multiple servers, increasing exposure risk
  2. Certificate Management: Renewals need to be synchronized across all servers
  3. Revocation Impact: Revoking the certificate affects all servers simultaneously

For some use cases, Subject Alternative Name (SAN) certificates might be preferable:

openssl req -new -newkey rsa:2048 -nodes -keyout example.com.key \
-out example.com.csr -subj "/CN=example.com" \
-addext "subjectAltName=DNS:hostEU.example.com,DNS:hostUS.example.com"