V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
xinge666
V2EX  ›  SSL

免费的半年 IPv4 / IPv6 和通配符域名 acme SSL 证书 HiCA

  •  2
     
  •   xinge666 · 2022-07-24 13:10:34 +08:00 · 6545 次点击
    这是一个创建于 613 天前的主题,其中的信息可能已经有所发展或是发生改变。

    昨天 HiCA 正式上线了,可以提供免费的 IPv4 / IPv6 和通配符域名证书申请,有效期半年,支持自动续签

    使用 acme 协议进行签发,这里写了一篇教程,大家可以来试试看,我签了一个 IPv4 和一个通配符域名证书,都成功了。

    博客链接: https://taurusxin.com/hica-ssl/

    44 条回复    2023-06-09 21:37:41 +08:00
    Zerek
        1
    Zerek  
       2022-07-24 13:43:21 +08:00   ❤️ 1
    不一定要用 api 手动申请也可以
    ./acme.sh --issue -d \*.域名 -d 域名 --dns --yes-I-know-dns-manual-mode-enough-go-ahead-please
    配置完 TXT 记录后再跑
    ./acme.sh --renew -d \*.域名 -d 域名 --dns --yes-I-know-dns-manual-mode-enough-go-ahead-please
    就签发完事儿了,手动模式好像是给签发 90 天
    estk
        2
    estk  
       2022-07-24 13:44:52 +08:00 via Android
    ip 我一般都是自签用,反正也不是用来做网站
    xxfye
        3
    xxfye  
       2022-07-24 14:11:53 +08:00
    全球首家公开表示不提供且禁止代理商提供任何形式 Web UI 、 桌面 UI 等形式申请界面,还能卖得出去、收得回钱的 CA 。

    这段话什么意思啊,前面申请界面看的懂,后面看不懂。
    xiangyuecn
        4
    xiangyuecn  
       2022-07-24 14:14:58 +08:00
    🐶https:// www1.hi.cn
    ❌https:// hi.cn
    ❌https:// www.hi.cn

    小作坊的既视感。
    xinge666
        5
    xinge666  
    OP
       2022-07-24 14:15:41 +08:00 via iPhone
    @xxfye #3 就是你不能用他们的 API 来做一个 GUI 一键申请的那种网站,只能手动命令行申请
    xxfye
        6
    xxfye  
       2022-07-24 14:18:34 +08:00
    @xinge666 主要还是不懂”还能卖得出去、收得回钱“什么意思
    1423
        7
    1423  
       2022-07-24 15:15:46 +08:00
    "error": "registering account [] with server: directory missing newNonce endpoint"

    缺失了 caddy 要求的 newNonce api
    letsencrypt 是有的: https://acme-staging-v02.api.letsencrypt.org/directory
    lkk
        8
    lkk  
       2022-07-24 15:16:16 +08:00   ❤️ 1
    @xiangyuecn 乍一看,hi.cn 域名牛逼啊。其实 hi.cn 是我国的海南行政区划域名。amce 为二级域名。
    1423
        9
    1423  
       2022-07-24 15:17:08 +08:00
    @1423 可能我搞错了,请先忽略这条
    1423
        10
    1423  
       2022-07-24 15:30:40 +08:00
    caddy 报错似乎是因为服务只支持已被弃用的 ACME v1
    letsencrypt 现在好像只提供 ACME v2 了,caddy 也只支持 v2
    wzw
        11
    wzw  
       2022-07-24 15:36:36 +08:00
    @xiangyuecn #4 我也这样感觉, 但是也觉得奇怪, 并且备案号是上海的

    中国省级域名(海南)
    https://domain.miit.gov.cn/indexd.html
    https://zh.wikiversity.org/wiki/%E4%B8%AD%E5%9B%BD%E4%BA%8C%E7%BA%A7%E5%9F%9F%E5%90%8D%E5%88%86%E9%85%8D
    mercury233
        12
    mercury233  
       2022-07-24 16:16:26 +08:00
    必须 80 端口就很鸡肋了
    ZE3kr
        13
    ZE3kr  
       2022-07-24 16:17:37 +08:00 via iPhone
    https://publicsuffix.org/list/public_suffix_list.dat
    确实 hi.cn 是保留的“cn geographic names”
    ZE3kr
        14
    ZE3kr  
       2022-07-24 16:23:48 +08:00 via iPhone
    是不是应该再加上这个 Slogan:
    “自己的域名不用自己的 CA 的 CA”
    https://www.ssllabs.com/ssltest/analyze.html?d=www1.hi.cn&s=2606%3a4700%3a3030%3a0%3a0%3a0%3aac43%3a8cf9&latest
    liuxyon
        15
    liuxyon  
       2022-07-24 16:55:05 +08:00 via Android   ❤️ 1
    国产的建议不要用.
    ChineseTeacher
        16
    ChineseTeacher  
       2022-07-24 16:57:00 +08:00
    我能看到用了 SSL.com 的根证书,并且 OCSP 都是自己的,但是 ssllabs 扫出来的结果是 Cloudflare 的 Baltimore Security 根。
    buxiaozisun
        17
    buxiaozisun  
       2022-07-24 17:20:41 +08:00 via Android
    @mercury233 80 ( http-01 )不是 HiCA 强制的,是 ACME 标准只支持 80 端口 http 协议,不支持其他端口验证
    buxiaozisun
        18
    buxiaozisun  
       2022-07-24 17:22:21 +08:00 via Android
    @xiangyuecn hi.cn 是顶级域名
    1423
        19
    1423  
       2022-07-24 18:08:24 +08:00
    "issuer": "acme.hi.cn-directory", "error": "registering account [] with server: attempt 3: https://acme.hi.cn/acme/new-account: HTTP 500: {\n \"message\": \"Server Error\"\n}"}

    不建议尝试,会浪费时间。
    stevenhawking
        20
    stevenhawking  
       2022-07-24 19:40:57 +08:00
    @1423 他们屏蔽了除 `acme.sh` 之外的客户端,包括 Caddy
    stevenhawking
        21
    stevenhawking  
       2022-07-24 19:41:35 +08:00
    @Zerek 试过了,`https://acme.hi.cn/directory` 不支持手动
    fredcc
        22
    fredcc  
       2022-07-24 21:24:31 +08:00   ❤️ 1
    9544
        23
    9544  
       2022-07-24 21:27:50 +08:00
    国内不敢用,是不是有人通知下就得被注销
    1423
        24
    1423  
       2022-07-24 22:26:31 +08:00
    @stevenhawking 是的,是用 useragent 区分的,改 Caddy 一行代码就可以绕过。
    curl 的话 -A "acme.sh/3.0.1 ( https://github.com/acmesh-official/acme.sh)"
    然而 caddy 还是报上面的 500 ,已经放弃摆弄了。
    stevenhawking
        25
    stevenhawking  
       2022-07-24 23:10:55 +08:00
    @1423 每款客户端都有细微差异的,这家服务器应该是自己写的,没有用标准的 Boulder 来搭建,所以没有适配其他 ACME 客户端。
    aulayli
        26
    aulayli  
       2022-07-25 00:40:07 +08:00
    ip 证书没啥用,通配符证书免费的用 Let's Encrypt ,有效期 90 续签方便用着也放心
    realpg
        27
    realpg  
       2022-07-25 07:06:28 +08:00
    之前就有免费 6 个月的,acme.sh 的供应商之一,你 list 一下我忘了是哪个
    acme.sh 应该是有四个供应商, 一个默认,一个 le,剩下两个就有一个是 6 个月还支持 wildcard
    Love4Taylor
        28
    Love4Taylor  
       2022-07-25 07:20:33 +08:00
    > 推荐 150 天一续,需要指定--days 参数
    Love4Taylor
        29
    Love4Taylor  
       2022-07-25 07:23:05 +08:00
    @1423 所以他们用的是 pki-validation 这个目录而不是 acme-challenge 是因为 v1 ?
    whitehack
        30
    whitehack  
       2022-07-25 10:30:53 +08:00   ❤️ 1
    @fredcc #22 你这是暴击


    个人觉得国内的这种服务很难稳定. 上面一句话就得无理由的封, 上面一句话就得无理由的关.
    好像也没有政策保护或者鼓励这种服务吧?

    另外大厂的全要备案.
    这种给不备案的域名发证书能活多久的确是个问题.
    ZeroClover
        31
    ZeroClover  
       2022-07-25 14:50:28 +08:00
    @realpg https://github.com/acmesh-official/acme.sh/blob/master/acme.sh#L23

    Let's Encrypt / ZeroSSL / Google PKI 都是支持泛域名,但是只有 90 天

    SSL.com 90 天不支持泛域名

    Buypass 180 天不支持泛域名

    ---

    之前提供国内 OCPS 的 TrustOcean 环洋诚信已经吃上免费饭了,这家能坚持多久呢
    realpg
        32
    realpg  
       2022-07-25 15:02:10 +08:00
    @ZeroClover #31
    我记得 buypass 支持来的
    不过我正式项目基本都是按域名签,不用 wildcard
    只有自己玩的采用 wildcard
    stevenhawking
        33
    stevenhawking  
       2022-07-26 01:24:21 +08:00
    @ZeroClover TrustOcean 没有提供国内 OCSP 。而且经过测试,这个 HiCA 写了提供国内 OCSP ,但其实签发出来的没有提供。

    所以应该是有条件提供的。
    Cassius
        34
    Cassius  
       2022-07-26 08:45:33 +08:00 via Android
    IP 证书只能用 80 来解析基本就没啥适用了。。
    stevenhawking
        35
    stevenhawking  
       2022-07-26 13:54:50 +08:00
    @Cassius

    根据 CA / B Forum 的 《 Baseline Requirements Documents (SSL/TLS Server Certificates): https://cabforum.org/wp-content/uploads/CA-Browser-Forum-BR-1.8.4.pdf 》之定义:

    1.6.1 Definitions:
    Authorized Ports: One of the following ports: 80 ( http), 443 ( https), 25 (smtp), 22 (ssh).

    3.2.2.4.18 Agreed‑Upon Change to Website v2
    Confirming the Applicant’s control over a FQDN by validating domain control of the FQDN using the ACME HTTP Challenge method defined in Section 8.3 of RFC 8555. The following are additive requirements to RFC 8555. The CA MUST receive a successful HTTP response from the request (meaning a 2xx HTTP status code must be received). The token (as defined in RFC 8555, Section 8.3) MUST NOT be used for more than 30 days from its creation. The CPS MAY specify a shorter validity period for Random Values, in which case the CA MUST follow its CPS.
    If the CA follows redirects, the following apply:
    1. Redirects MUST be initiated at the HTTP protocol layer.
    a. For validations performed on or after July 1, 2021, redirects MUST be the result of a 301, 302, or 307 HTTP status code response, as defined in RFC 7231, Section 6.4, or a 308 HTTP status code response, as defined in RFC 7538, Section 3. Redirects MUST be to the final value of the Location HTTP response header, as defined in RFC 7231, Section 7.1.2.
    b. For validations performed prior to July 1, 2021, redirects MUST be the result
    of an HTTP status code result within the 3xx Redirection class of status codes, as defined in RFC 7231, Section 6.4. CAs SHOULD limit the accepted status codes and resource URLs to those defined within 1.a.
    2. Redirects MUST be to resource URLs with either the “http” or “https” scheme.
    3. Redirects MUST be to resource URLs accessed via Authorized Ports.
    Note: * For Certificates issued prior to 2021‐12‐01, the CA MAY also issue Certificates for other FQDNs that end with all the labels of the validated FQDN. This method is suitable for validating Wildcard Domain Names. * For Certificates issued on or after 2021‐12‐01, the CA MUST NOT issue Certificates for other FQDNs that end with all the labels of the
    validated FQDN unless the CA performs a separate validation for that FQDN using an authorized method. This method is NOT suitable for validating Wildcard Domain Names.

    3.2.2.4.19 Agreed‑Upon Change to Website ‑ ACME
    Confirming the Applicant’s control over a FQDN by validating domain control of the FQDN using the ACME HTTP Challenge method defined in Section 8.3 of RFC 8555. The following are additive requirements to RFC 8555.
    The CA MUST receive a successful HTTP response from the request (meaning a 2xx HTTP status code must be received).
    The token (as defined in RFC 8555, Section 8.3) MUST NOT be used for more than 30 days from its creation. The CPS MAY specify a shorter validity period for Random Values, in which case the CA MUST follow its CPS.
    If the CA follows redirects, the following apply:
    1. Redirects MUST be initiated at the HTTP protocol layer.
    a. For validations performed on or after July 1, 2021, redirects MUST be the result of a 301, 302, or 307 HTTP status code response, as defined in RFC 7231, Section 6.4, or a 308 HTTP status code response, as defined in RFC 7538,
    Section 3. Redirects MUST be to the final value of the Location HTTP response header, as defined in RFC 7231, Section 7.1.2.
    b. For validations performed prior to July 1, 2021, redirects MUST be the result of an HTTP status code result within the 3xx Redirection class of status codes, as defined in RFC 7231, Section 6.4. CAs SHOULD limit the accepted status codes and resource URLs to those defined within 1.a.
    2. Redirects MUST be to resource URLs with either the “http” or “https” scheme.
    3. Redirects MUST be to resource URLs accessed via Authorized Ports.
    Note: * For Certificates issued prior to 2021‐12‐01, the CA MAY also issue Certificates for other FQDNs that end with all the labels of the validated FQDN. This method is suitable for validating Wildcard Domain Names. * For Certificates issued on or after 2021‐12‐01, the CA MUST NOT issue Certificates for other FQDNs that end with all the labels of the validated FQDN unless the CA performs a separate validation for that FQDN using an authorized method. This method is NOT suitable for validating Wildcard Domain Names.

    可以看到,HTTP 验证只能使用 80 端口。部分 CA 可以用 HTTPS ( 443 端口)、SMTP ( 25 端口)、SSH ( 22 端口,目前无 CA 支持)验证。

    所以,IP 证书必须 80 端口验证,是他们做错了吗?
    Cassius
        36
    Cassius  
       2022-07-26 17:59:55 +08:00
    @stevenhawking
    我的意思是,非 ICP 备案的都没办法用这个了。因为上海电信查 ddns 很神经,已经被 ban 过一次了。
    我现在都是直接 IP 访问。
    如果可以其他端口可用的话就好了。
    buxiaozisun
        37
    buxiaozisun  
       2022-07-26 22:09:13 +08:00 via Android
    @Cassius 用其他端口验证的话 ca 就凉了
    stevenhawking
        38
    stevenhawking  
       2022-07-29 21:24:58 +08:00
    @Cassius 这是中国局部的特殊情况,标准和合规不能随便因为局部就乱改的。否则亚洲诚信总结的 《违规被浏览器列入黑名单的 CA 、SSL 证书》( https://blog.myssl.com/ca-blacklist/)就是下场
    stevenhawking
        39
    stevenhawking  
       2022-07-29 21:25:27 +08:00
    修复个楼上的链接:
    - 违规被浏览器列入黑名单的 CA 、SSL 证书 https://blog.myssl.com/ca-blacklist/
    liuxyon
        40
    liuxyon  
       2022-08-05 17:15:17 +08:00 via Android
    国内体制再没有改之前不要考虑, 注销都是轻的.
    stevenhawking
        41
    stevenhawking  
       2022-08-08 02:33:35 +08:00
    @liuxyon 做一个国家的生意就要遵守一个国家的法律。如果不想做,你大可以润
    vipwuping
        42
    vipwuping  
       2022-09-05 22:42:41 +08:00
    这个证书有 VIP 付费功能,但是付费后,如果服务器重装,或者更换电脑就要重新收费,官方目前没有解决付费用户账号数据备份导入到新服务器的功能
    stevenhawking
        43
    stevenhawking  
       2022-10-05 23:09:02 +08:00
    @vipwuping 已经解决了,EAB 应该可用了
    TheBlade
        44
    TheBlade  
       292 天前 via Android
    吃个瓜 https://github.com/acmesh-official/acme.sh/issues/4659 Notice: 官网已经打不开了
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   4906 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 45ms · UTC 09:52 · PVG 17:52 · LAX 02:52 · JFK 05:52
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.