1.4.5.2
This commit is contained in:
67
EdgeAPI/internal/acme/providers_ext_plus.go
Normal file
67
EdgeAPI/internal/acme/providers_ext_plus.go
Normal file
@@ -0,0 +1,67 @@
|
||||
// Copyright 2022 Liuxiangchao iwind.liu@gmail.com. All rights reserved. Official site: https://goedge.cn .
|
||||
//go:build plus
|
||||
|
||||
package acme
|
||||
|
||||
import teaconst "github.com/TeaOSLab/EdgeAPI/internal/const"
|
||||
|
||||
func FindAllProviders() []*Provider {
|
||||
var providers = []*Provider{
|
||||
{
|
||||
Name: "Let's Encrypt",
|
||||
Code: DefaultProviderCode,
|
||||
Description: "非盈利组织Let's Encrypt提供的免费证书。",
|
||||
APIURL: "https://acme-v02.api.letsencrypt.org/directory",
|
||||
RequireEAB: false,
|
||||
},
|
||||
}
|
||||
|
||||
// 商业版
|
||||
if teaconst.IsPlus {
|
||||
providers = append(providers, []*Provider{
|
||||
{
|
||||
Name: "Buypass",
|
||||
Code: "buypass",
|
||||
Description: "Buypass提供的免费证书。",
|
||||
APIURL: "https://api.buypass.com/acme/directory",
|
||||
TestAPIURL: "https://api.test4.buypass.no/acme/directory",
|
||||
RequireEAB: false,
|
||||
},
|
||||
}...)
|
||||
}
|
||||
|
||||
providers = append(providers, []*Provider{
|
||||
{
|
||||
Name: "ZeroSSL",
|
||||
Code: "zerossl",
|
||||
Description: "官方相关文档 <a href=\"https://zerossl.com/documentation/acme/\" target=\"_blank\">https://zerossl.com/documentation/acme/</a>。",
|
||||
APIURL: "https://acme.zerossl.com/v2/DV90",
|
||||
RequireEAB: true,
|
||||
EABDescription: "在官网<a href=\"https://app.zerossl.com/developer\" target=\"_blank\">[Developer]</a>页面底部点击\"Generate\"按钮生成。",
|
||||
},
|
||||
}...)
|
||||
|
||||
// 商业版
|
||||
if teaconst.IsPlus {
|
||||
providers = append(providers, []*Provider{
|
||||
{
|
||||
Name: "SSL.com",
|
||||
Code: "sslcom",
|
||||
Description: "官方相关文档 <a href=\"https://www.ssl.com/guide/ssl-tls-certificate-issuance-and-revocation-with-acme/\" target=\"_blank\">https://www.ssl.com/guide/ssl-tls-certificate-issuance-and-revocation-with-acme/</a>。",
|
||||
APIURL: "https://acme.ssl.com/sslcom-dv-rsa",
|
||||
RequireEAB: true,
|
||||
EABDescription: "登录SSL.com后,点击Dashboard中的api credentials链接,可以查看和创建密钥,EAB Kid对应界面中的Account/ACME Key,EAB HMAC Key对应界面中的HMAC Key。",
|
||||
},
|
||||
{
|
||||
Name: "Google Cloud",
|
||||
Code: "googleCloud",
|
||||
Description: "官方相关文档 <a href=\"https://cloud.google.com/certificate-manager/docs/public-ca-tutorial\" target=\"_blank\">https://cloud.google.com/certificate-manager/docs/public-ca-tutorial</a>",
|
||||
APIURL: "https://dv.acme-v02.api.pki.goog/directory",
|
||||
RequireEAB: true,
|
||||
EABDescription: "请根据Google Cloud官方文档运行 <code-label>gcloud publicca external-account-keys create</code-label> 获得Kid(对应keyId)和Key(对应b64MacKey)。",
|
||||
},
|
||||
}...)
|
||||
}
|
||||
|
||||
return providers
|
||||
}
|
||||
Reference in New Issue
Block a user