blob: 7251f12c969ac54a208f8dbe431e69c22a7e56a5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
# SPDX-License-Identifier: GPL-3.0-or-later
# CA
certtool --generate-privkey > ca-key.pem
certtool --generate-self-signed --load-privkey ca-key.pem --template ca.tmpl --outfile ca.pem
# server cert signed by CA above
certtool --generate-privkey > server-key.pem
certtool --generate-certificate --load-privkey server-key.pem --load-ca-certificate ca.pem --load-ca-privkey ca-key.pem --template server.tmpl --outfile server.pem
# wrong CA - unrelated to others
certtool --generate-privkey > wrongca-key.pem
certtool --generate-self-signed --load-privkey wrongca-key.pem --template wrongca.tmpl --outfile wrongca.pem
|