mirror of
https://github.com/mumble-voip/grumble.git
synced 2025-12-20 06:10:00 -08:00
Refine auto-keypair regen functionality. Complain loudly if only one of (cert.pem, key.pem) exists.
This commit is contained in:
parent
76747e0b71
commit
b94b04d2de
4 changed files with 67 additions and 42 deletions
|
|
@ -1190,7 +1190,9 @@ func (s *Server) ListenAndMurmur() {
|
|||
go s.SendUDP()
|
||||
|
||||
// Create a new listening TLS socket.
|
||||
cert, err := tls.LoadX509KeyPair(filepath.Join(Args.DataDir, "cert"), filepath.Join(Args.DataDir, "key"))
|
||||
certFn := filepath.Join(Args.DataDir, "cert.pem")
|
||||
keyFn := filepath.Join(Args.DataDir, "key.pem")
|
||||
cert, err := tls.LoadX509KeyPair(certFn, keyFn)
|
||||
if err != nil {
|
||||
s.Printf("Unable to load x509 key pair: %v", err)
|
||||
return
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue