Skip to content

gRPC使用TLS验证,TLS认证失败。 #16

@VayneYan

Description

@VayneYan

我按照 tutorial 给出的,使用 openssl 在本地生成了私钥和证书文件,服务端、客户端都添加上 TLS 认证。
但是当客户端调用远程过程时报错了:
rpc error: code = Unavailable desc = connection error: desc = "transport: authentication handshake failed: x509: certificate relies on legacy Common Name field, use SANs or temporarily enable Common Name matching with GODEBUG=x509ignoreCN=0"
我尝试了更换服务端、客户端的端口,但结果还是一样。
烦请知道的前辈指点一二。

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions