all repos — flounder @ ef38711cb270ef6e6e709bac3678a653d9cf05eb

A small site builder for the Gemini protocol

Hopefully fix cert issues
alex wennerberg alex@alexwennerberg.com
Tue, 03 Nov 2020 12:55:08 -0800
commit

ef38711cb270ef6e6e709bac3678a653d9cf05eb

parent

c9d21573cbaeac8450ec41492ea4199db09b7ab7

3 files changed, 8 insertions(+), 3 deletions(-)

jump to
M gemini.gogemini.go

@@ -2,12 +2,12 @@ package main

import ( "crypto/tls" - "strings" - // "fmt" + "crypto/x509/pkix" gmi "git.sr.ht/~adnano/go-gemini" "log" "path" "path/filepath" + "strings" "text/template" "time" )

@@ -63,6 +63,9 @@ }

server.CreateCertificate = func(h string) (tls.Certificate, error) { log.Println("Generating certificate for", h) return gmi.CreateCertificate(gmi.CertificateOptions{ + Subject: pkix.Name{ + CommonName: hostname, + }, DNSNames: []string{h}, Duration: time.Hour * 760, // one month })
M go.modgo.mod

@@ -3,7 +3,7 @@

go 1.15 require ( - git.sr.ht/~adnano/go-gemini v0.1.5 + git.sr.ht/~adnano/go-gemini v0.1.6-0.20201103041146-01670647d2e2 github.com/BurntSushi/toml v0.3.1 github.com/gorilla/handlers v1.5.1 github.com/gorilla/sessions v1.2.1
M go.sumgo.sum

@@ -2,6 +2,8 @@ git.sr.ht/~adnano/go-gemini v0.1.3 h1:uClB4mzTkHBMKBde63/EzrsIhRuHxxaNHVRf1/gApXU=

git.sr.ht/~adnano/go-gemini v0.1.3/go.mod h1:If1VxEWcZDrRt5FeAFnGTcM2Ud1E3BXs3VJ5rnZWKq0= git.sr.ht/~adnano/go-gemini v0.1.5 h1:zHTrQe47+ubCpGTEFgVVJ2Un2x17GAqyN1H5bghDEXc= git.sr.ht/~adnano/go-gemini v0.1.5/go.mod h1:If1VxEWcZDrRt5FeAFnGTcM2Ud1E3BXs3VJ5rnZWKq0= +git.sr.ht/~adnano/go-gemini v0.1.6-0.20201103041146-01670647d2e2 h1:fwY7TBwxzSXcauWnAZAeA+X0SFbIFXy8n7mFtHWabX0= +git.sr.ht/~adnano/go-gemini v0.1.6-0.20201103041146-01670647d2e2/go.mod h1:If1VxEWcZDrRt5FeAFnGTcM2Ud1E3BXs3VJ5rnZWKq0= github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/felixge/httpsnoop v1.0.1 h1:lvB5Jl89CsZtGIWuTcDM1E/vkVs49/Ml7JJe07l8SPQ=