什么是套接字库?
在阅读有关 OpenSSL 的内容时,我偶然发现了这样一句话:“如果安全性也像 就像在构建程序时链接到不同的套接字库一样简单”。
所提到的套接字库是什么?它的用途是什么(即在 Java 或 C# 中)?
While reading about OpenSSL I've stumbled upon sentence: "It would be nice if security was as
simple as linking in a different socket library when building a program".
What is this mentioned socket library? What is it used for (i.e. in Java or C#)?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
套接字是互联网连接的端点。套接字库是实现套接字的库,以便您可以在程序中使用它们进行 Internet 通信。
文本建议的是,如果您可以用不同的版本替换常规套接字库(例如 Windows 上的 DLL),那就太好了,这会自动添加 SSL 功能以实现安全、加密的连接 - 但添加 SSL 功能事情并没有那么简单。
在 Java 或 C# 中,您不会直接使用这样的库。例如,Java 在其标准 API 中包含用于处理 Internet 连接的类。您可以在 Java 程序中使用该 API,并且 JVM 将使用操作系统提供的套接字库来进行实际通信。
A socket is the endpoint of an Internet connection. A socket library is a library that implements sockets so that you can use them in your program for Internet communication.
What the text suggests is that it would be nice if you could replace your regular socket library (which would be for example a DLL on Windows) with a different version, which would automatically add SSL functionality for secure, encrypted connections - but adding SSL functionality is not as simple as that.
In Java or C#, you wouldn't use such a library directly. Java for example has classes in its standard API for working with Internet connections. You'd use that API in your Java program, and the JVM will use the socket library that the operating system provides to do the actual communication.