简体   繁体   English

未对等身份验证:使用WizTool的REST服务错误

[英]Peer Not Authenticated: REST Service Error using WizTool

I am using WizTool.org's RESTClient v3.4.2 to test a remote .NET endpoint that is on a Windows 2012 box, IIS 8.0. 我正在使用WizTool.org的RESTClient v3.4.2测试Windows 2012框IIS 8.0上的远程.NET终结点。

I've used this tool many times to debug the same REST services on my local machine in debug mode, but this is the first time I've tried to use it on the actual production server. 我已经多次使用此工具在调试模式下在本地计算机上调试相同的REST服务,但这是我第一次尝试在实际的生产服务器上使用它。 (Well, it's actually a QA server, but close enough.) The main difference between what I've done in the past and now is that on my local dev box, I don't have an SSL cert, so it was all done with an HTTP url. (嗯,它实际上是一台QA服务器,但是足够接近了。)我过去和现在所做的主要区别是,在我的本地开发机器上,我没有SSL证书,因此全部完成了使用HTTP网址。 On the QA server, we have a cert, so I'm using HTTPS. 在质量检查服务器上,我们有一个证书,因此我正在使用HTTPS。

I am getting this error: 我收到此错误:

peer not authenticated
javax.net.ssl.SSLPeerUnverifiedException: peer not authenticated
    at sun.security.ssl.SSLSessionImpl.getPeerCertificates(Unknown Source)
    at org.apache.http.conn.ssl.AbstractVerifier.verify(AbstractVerifier.java:128)
    at org.apache.http.conn.ssl.SSLSocketFactory.connectSocket(SSLSocketFactory.java:339)
    at     org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:123)
at org.apache.http.impl.conn.AbstractPoolEntry.open(AbstractPoolEntry.java:147)
at org.apache.http.impl.conn.AbstractPooledConnAdapter.open(AbstractPooledConnAdapter.java:108)
at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:415)
at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:641)
at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:576)
at org.wiztools.restclient.HTTPClientRequestExecuter.execute(HTTPClientRequestExecuter.java:303)
at org.wiztools.restclient.ui.RESTView$26.run(RESTView.java:1061)

I found these two threads that relate to this error, but neither provided any clues: 我发现了与该错误有关的以下两个线程,但均未提供任何线索:

peer not authenticated in web service? 对等未在Web服务中通过身份验证?

Peer not authenticated exception while consuming https REST service 使用https REST服务时对等方未通过身份验证异常

I also found this thread which more directly addressed the tool I am using, but I'm not sure I follow the proposed solution. 我还发现了该线程,它更直接地解决了我正在使用的工具,但是我不确定我是否遵循建议的解决方案。 Scratch that... I am sure that I do not understand the proposed solution. 从头开始...我确信我不理解建议的解决方案。

https://code.google.com/p/rest-client/issues/detail?id=135 https://code.google.com/p/rest-client/issues/detail?id=135

In the RESTClient tool, SSL > General tab, I have played around with all combinations of "Trust self-signed certificates" and "Hostname verifier". 在RESTClient工具的“ SSL”>“常规”选项卡中,我使用了“信任自签名证书”和“主机名验证程序”的所有组合。 No luck. 没运气。 (The server is using a full wild-card cert, so I don't think the "Trust self-signed certificates" has any impact anyway.) (服务器使用的是完整的通配符证书,因此我认为“信任自签名证书”不会产生任何影响。)

In IIS, I also exported a copy of the cert to a .pfx file (with a password) and then in the RESTClient tool, SSL > Truestore / Keystore, I imported the file. 在IIS中,我还将证书的副本导出到.pfx文件(带有密码),然后在RESTClient工具(SSL> Truestore / Keystore)中导入了该文件。 Still no luck. 仍然没有运气。

Any ideas? 有任何想法吗?

Thanks! 谢谢!

In case anyone else ends up here looking for a solution, I did find one, but not one with the WizTool.org REST tool. 万一其他人最终在这里寻找解决方案,我确实找到了一个,但使用WizTool.org REST工具却找不到。 The process of importing the SSL cert into that thing proved too challenging, and instead I ended up using a REST testing tool that is Firefox plugin. 事实证明,将SSL证书导入该过程非常困难,因此我最终使用了Firefox插件REST测试工具。

http://restclient.net/ http://restclient.net/

Quick little plugin. 快速的小插件。 Worked like a charm right out of the box. 就像开箱即用的魅力一样工作。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM