简体   繁体   English

Firefox 附加组件可以侦听 UNIX 套接字吗?

[英]Can a Firefox add-on listen on a UNIX socket?

I know how to listen on a dedicated port using nsISocketTransportService in Add-on sdk.我知道如何在 Add-on sdk 中使用 nsISocketTransportService 侦听专用端口。 But, is it possible to use UNIX socket in Add-on SDK to communicate with oher applications.但是,是否可以在 Add-on SDK 中使用 UNIX 套接字与其他应用程序通信。

It seems you can't: https://support.mozilla.org/en-US/kb/permission-request-messages-firefox-extensions )看来你不能: https : //support.mozilla.org/en-US/kb/permission-request-messages-firefox-extensions

This would make sense, since:这是有道理的,因为:

  1. UNIX sockets are a special file on *nix UNIX 套接字是 *nix 上的一个特殊文件
  2. they are not available across platforms它们不能跨平台使用
  3. this would be a huge security issue.这将是一个巨大的安全问题。

If you need to communicate with other software on the computer you can probably safely use regular network sockets, websockets, etc...如果您需要与计算机上的其他软件进行通信,您可能可以安全地使用常规网络套接字、websockets 等...

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

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