Send client certificate using XHR

2019-07-02 23:53发布

I'm trying to open an ssl service with java script. In order to do so, I need to send my certificate with xmlhttp object. Can I do it with java script? I could not find how to do it anywhere.

my code looks like this:

xmlhttp.open("post","https://[some ip]:[some secured port]",false);
xmlhttp.send();

However it's not working. On the other hand, when using: "https://[some ip]:[some secured port]" - directly from my browser - It is telling me to choose a certificate and it's working well.

How can I make it work straight from the java script? What should be the solution to my situation?

1条回答
疯言疯语
2楼-- · 2019-07-03 00:43

I don't think that's possible.

Besides that, the same origin policy would most likely cause problems for you.

查看更多
登录 后发表回答