How to Use Keys and Certificates (Step-by-Step Guide)

Quick notes on OpenSSL, PEM/DER/CER formats, and practical tips.

Mar 9, 2022 · 1 min read · 78 Words · -Views -Comments · Digital Life
Security 🇨🇳 阅读中文版
Read with AI

Choose an AI assistant

ChatGPT Open in a new tab with the article link and prompt
Claude Copy the prompt, then open Claude

Open Claude
Trouble reading the article?

If the prompt is missing, copy the full prompt below into your AI assistant. If the AI cannot read the article, paste the visible passage you want to discuss and add your question.

OpenSSL

# 版本信息
$ openssl version -a

# 性能测试
$ openssl speed

PEM Basics

-----BEGIN <whatever>----- 
data
 -----END <whatever>----
  • Stores certificates or private keys.

  • Each line is 64 characters.

  • PEM is Base64-encoded DER.

    PEM or Privacy Enhanced Mail is a Base64 encoded DER certificate.

  • DER/CER are binary encodings (cer typically omits the private key).

  • The first 32 characters of a PEM file are cosmetic; they don’t affect usage.

Authors
Developer, digital product enthusiast, tinkerer, sharer, open source lover