openvpn.is
English
简体中文繁體中文EnglishРусскийفارسی

HomeGuidesIssue and revoke papers

Issue and revoke papers

Manage OpenVPN certificates with easy-rsa: issue one for a new device, see what expires, revoke a lost one, refresh the CRL, and plan for the CA.

A certificate is like a sealed document: issued, and revocable
A certificate is like a sealed document: issued, and revocable Brendan Riley from Chicago, USA, CC BY 2.0

Issue one

On the issuer's machine
./easyrsa build-client-full tablet nopass

One per device, with a name that says whose it is. Do not let a whole family share one.

What expires soon

Look at one certificate
./easyrsa show-cert tablet | grep -A2 Validity
./easyrsa show-expire 60

Revoke one

A lost phone, someone who left
./easyrsa revoke phone
./easyrsa gen-crl
sudo cp pki/crl.pem /etc/openvpn/server/crl.pem

No restart is needed; new connections consult the list. Existing ones are cut when they reconnect. If it is urgent, restart the service.

When something expires

What expiredWhat to do
A client certificateIssue one under a new name and revoke the old
The server certificateSign again, replace the files, restart
The CANew CA, all certificates reissued

Keeping the seal

  1. WhereAn offline computer or an encrypted USB stick
  2. PasswordDo not use nopass with build-ca
  3. BackupTwo copies in different places
  4. NeverOn the server that runs OpenVPN
The CA private key
I forgot the CA password?

There is no way to recover it. Build a new CA and reissue everything.

Certificates together with passwords?

Yes, with an authentication plugin on the server. A lost phone then still needs the password.

Walk onBuild your own gate

Nearby gates

Signposts: OpenVPN add user, revoke OpenVPN certificate, easy-rsa revoke