java - 服务器如何只允许预先批准的客户端与其通信

标签 java c++ c

<分区>

我想知道服务器如何确保来自客户端的请求仅来自有效的预先批准的客户端,谁能告诉我要使用什么算法以及我有哪些选择?

最佳答案

您希望实现相互身份验证 - 服务器和客户端都可以确保彼此身份的真实性。

这是一个相当新的概念,因为它通常是单方面的身份验证。我将从这里开始,在 oracle 站点上使用 Web 服务提供一个完整的示例。您无法获得比这更可靠的信息:)

链接摘录:

When you send messages with mutual authentication, a connection is possible only if the client trusts the server's certificate and the server trusts the client's certificate. The process of exchanging certificates and setting up connection properties is called the Secure Sockets Layer (SSL) handshake. For details, see the section, "SSL Protocol Overview," in the Java Secure Socket Extension (JSSE) Reference Guide.

http://developers.sun.com/appserver/reference/techart/mutual_auth.html

关于java - 服务器如何只允许预先批准的客户端与其通信,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10942389/

相关文章:

java - 无限循环线程中的问题

c++ - 在C++容器中作为模板参数提供的分配器与作为构造函数参数提供的分配器之间的区别?

c++ - 在 C++ 源代码中使用重音字符是不是很糟糕?

c - 如何知道尝试打开文件时是否有错误(在 C 中使用 fopen 时)

java - 如何定制 seam-gen 以支持另一个数据库?

java - RecyclerView 空指针异常

java - 通过 Runtime.exec() 命令在 java 中终止进程时如何获得异常?

c++ - 将 boost (asio) 错误消息翻译成自然语言

c - 使用 free 作为动态数组结构的问题

c++ - “CObject::CObject”:无法访问类 'CObject' d:\program files\microsoft visual studio 9.0\vc\atlmfc\include\afxcoll.h 中声明的私有(private)成员