Botconnector无法用于自签名的Node.js Bot [英] Botconnector not working for a self signed nodejs bot

查看:92
本文介绍了Botconnector无法用于自签名的Node.js Bot的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建了一个简单的机器人.自签名ssl证书.显然,这不适用于bot连接器.几秒钟后,我从机器人收到以下错误消息.

I created a simple bot. Self signed the ssl cert. Apparently that does not work for bot connector . I get following error form the bot, after several seconds.

{
    "error": {
        "code": "BadCertificate",
        "message": "An error occurred while sending the request. The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel. The remote certificate is invalid according to the validation procedure. ",
        "statusCode": 500
    }
}

这是否意味着对于机器人来说,自签名证书毫无疑问?可以解决这个问题吗?

Does that mean self signed certificates are out of question for the bot? Any work around this problem?

推荐答案

简而言之,是的,不支持自签名证书.

In short, yes, self-signed certs are not supported.

如果使用HTTPS,则必须具有正确链接的证书. Bot连接器使用标准的服务器证书验证来确保您的网站符合要求.换句话说,如果您将浏览器指向您的漫游器,并且您的浏览器认为该证书是合法的,则Bot Connector也可能也会这样做.如果您的浏览器不喜欢它,则Bot Connector可能也不会.

If you use HTTPS, you must have a properly chained cert. The Bot Connector uses standard server certificate validation to make sure your site is what it claims to be. Put another way, if you point a browser to your bot and your browser thinks the cert is legit, the Bot Connector likely will, too. If your browser doesn't like it, the Bot Connector probably won't either.

对于以所有语言实现的漫游器都是如此.

This is true for bots implemented in all languages.

这篇关于Botconnector无法用于自签名的Node.js Bot的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆