Generating Certificate Signing Requests (CSR)
Generating Certificate Signing Requests (CSR)
The Certificate Signing Request (CSR) serves as the foundation of the certificate application process. This cryptographically signed message contains information about your organization and the domain you're securing, along with your public key. The CSR generation process creates both the CSR itself and a private key, which must be carefully protected throughout the certificate's lifetime. Loss or compromise of the private key renders the certificate useless and potentially exposes encrypted communications.
Generating a CSR varies by platform but follows similar principles across systems. On Linux servers using OpenSSL, the command openssl req -new -newkey rsa:2048 -nodes -keyout private.key -out domain.csr
creates a 2048-bit RSA key pair and CSR. Windows servers using IIS provide a graphical interface through the Server Certificates feature, guiding administrators through the process. Regardless of platform, the generation process prompts for information including country, state, organization name, and common name (the domain being secured).
The common name field deserves special attention, as it must exactly match the domain name users will access. For a website accessible at www.example.com, the common name must be "www.example.com", not "example.com" or any variation. Wildcard certificates require the common name format "*.example.com". This precision prevents certificate errors that could alarm users and damage trust. Modern certificates use the Subject Alternative Name field to support multiple domains, but the common name remains important for compatibility.
Key strength and algorithm selection impact both security and compatibility. While 2048-bit RSA keys currently provide adequate security, many organizations choose 4096-bit keys for extended protection. Elliptic curve cryptography offers equivalent security with smaller key sizes, improving performance. However, administrators must verify that their server software and client base support their chosen algorithms. Balancing security, performance, and compatibility requires understanding your specific environment and user needs.