From e94ca36335cbfc5678520fed7325ddcde279b507 Mon Sep 17 00:00:00 2001 From: Paolo Borelli Date: Fri, 5 Jun 2015 19:52:00 +0200 Subject: [PATCH] Add CommonName to the self signed certificate Without a CN the self signed certificate is considered invalid by chrome. You can check with: openssl x509 -in cert.pem -subject -noout --- cmd/cert.go | 1 + 1 file changed, 1 insertion(+) diff --git a/cmd/cert.go b/cmd/cert.go index 631c4c6823..0a09b00344 100644 --- a/cmd/cert.go +++ b/cmd/cert.go @@ -114,6 +114,7 @@ func runCert(ctx *cli.Context) { SerialNumber: serialNumber, Subject: pkix.Name{ Organization: []string{"Acme Co"}, + CommonName: "Gogs", }, NotBefore: notBefore, NotAfter: notAfter,