草庐IT

Autocert

全部标签

linux - arm 上的 autocert 中缺少字段或方法签名方案

我正在用go编写一个程序,它向不同的服务器发出HTTP请求并读取响应。该程序在Windows/Mac上运行得非常好,但是当我在基于ARM的RaspPi3和RasbianOS上运行该程序时,它失败了。每次我尝试构建代码时都会抛出此错误,有什么可以提示我在这里做错了什么吗?#golang.org/x/crypto/acme/autocert../../go/src/golang.org/x/crypto/acme/autocert/autocert.go:301:hello.SupportedProtosundefined(type*tls.ClientHelloInfohasnofiel

ssl - 在 autocert.Manager 中省略 HostPolicy 是否有任何危险?

我想使用golang.org/x/crypto/acme/autocert在Golang中使用Let'sEncrypt设置TLS。为什么要在Manager中设置HostPolicy?似乎没有默认的autocert.HostWhitelist一切正常。http.HandleFunc("/",func(whttp.ResponseWriter,r*http.Request){w.Write([]byte("test"))})m:=autocert.Manager{Prompt:autocert.AcceptTOS,//HostPolicy:autocert.HostWhitelist("e

ssl - 通过 DNS 对多个子域和 IP 地址使用 autocert

我有两台独立的服务器,它们使用相同的域名和不同的前缀,一台做一些应用程序的事情,另一台做文件共享。使用autocert包,我如何才能配置证书管理器来生成我可以在两台服务器上使用的证书? 最佳答案 将两个域添加到证书管理器白名单:certManager:=autocert.Manager{Prompt:autocert.AcceptTOS,HostPolicy:autocert.HostWhitelist("domain.me","filesharing.domain.me"),//YourdomainhereCache:autoce

go - crypto/autocert 包停止工作,永远挂起等待 acme 挑战

我一直依赖这个库有一段时间了,没有任何问题,但突然间它完全忽略了缓存的证书,尝试获取新证书,但它只是永远等待显然永远不会出现的acme挑战。据我所知,我的用法是完全正确的(这在过去几周内一直有效,没有问题):certManager:=autocert.Manager{Prompt:autocert.AcceptTOS,HostPolicy:autocert.HostWhitelist("example.com"),Cache:autocert.DirCache("certs"),}c1:=make(chanerror)gofunc(){err:=http.ListenAndServe(

go - Docker 在完成 Golang 项目构建之前退出

我正在尝试使用Docker构建一个Golang项目,但该过程在完成之前一直退出,这是终端输出的一部分:github.com/kataras/go-template(download)Fetchinghttps://golang.org/x/crypto/acme/autocert?go-get=1Parsingmetatagsfromhttps://golang.org/x/crypto/acme/autocert?go-get=1(statuscode200)get"golang.org/x/crypto/acme/autocert":foundmetatagmain.metaImp

go - 使用 autocert 保护 websocket 服务器

我正在尝试使用acme/autocert在go中设置一个安全的websocket服务器(wss://)。程序启动,但当我尝试连接到它时出现以下错误:http:TLShandshakeerrorfrom:acme/autocert:unabletoauthorize"";challenge"tls-alpn-01"failedwitherror:acme:authorizationerrorfor:403urn:acme:error:unauthorized:CannotnegotiateALPNprotocol"acme-tls/1"fortls-alpn-01challenge这是我

go - 顶点 : authorization error for <domain> (acme/autocert)

运行以下代码时出现错误:acme:authorizationerrorfordomain(wheredomainisreplacedbymyactualdomain)有没有人遇到过这个问题?返回的错误并没有提供太多信息。packagemainimport("crypto/tls""net/http""golang.org/x/crypto/acme/autocert")funcmain(){certManager:=autocert.Manager{Prompt:autocert.AcceptTOS,HostPolicy:autocert.HostWhitelist(),//yourd

go - 顶点 : authorization error for <domain> (acme/autocert)

运行以下代码时出现错误:acme:authorizationerrorfordomain(wheredomainisreplacedbymyactualdomain)有没有人遇到过这个问题?返回的错误并没有提供太多信息。packagemainimport("crypto/tls""net/http""golang.org/x/crypto/acme/autocert")funcmain(){certManager:=autocert.Manager{Prompt:autocert.AcceptTOS,HostPolicy:autocert.HostWhitelist(),//yourd

go - 使用Echo时编译报错

我在运行时使用github.com/labstack/echo包做了一个简单的工作我得到了这个错误。github.com\labstack\echo\echo.go:624:e.AutoTLSManager.HTTPHandlerundefined(typeautocert.ManagerhasnofieldormethodHTTPHandlerpackagemainimport"github.com/labstack/echo"funcmain(){e:=echo.New()e.Start(":")} 最佳答案 此问题已在issu

go - 使用Echo时编译报错

我在运行时使用github.com/labstack/echo包做了一个简单的工作我得到了这个错误。github.com\labstack\echo\echo.go:624:e.AutoTLSManager.HTTPHandlerundefined(typeautocert.ManagerhasnofieldormethodHTTPHandlerpackagemainimport"github.com/labstack/echo"funcmain(){e:=echo.New()e.Start(":")} 最佳答案 此问题已在issu
12