Re: NPAPI replacement for those of us who still need system API access

Benjamin Smedberg <[email protected]> Mon, 12 Oct 2015 16:38:15 -0400
Newsgroups gmane.comp.mozilla.devel.plugins
Message-ID <[email protected]>

On 10/9/2015 4:38 PM, Richard Bateman wrote:
> What is your strategy going forward with that?  Google has given us Native Messaging.  It's a terribly obnoxious API to deal with and extremely inefficient in a lot of ways, but it does provide us with a method of communicating with a native application.  Does FireFox have something similar? If not, do you plan to add something similar or at least something that could be used for a similar purpose by the time that NPAPI is deprecated?

As I hope you're aware, we recently announced[1] plans to focus our 
addons ecosystem on WebExtensions, which is designed to use compatible 
APIs with Chrome where possible. So I do believe that we will have 
native messaging which is compatible with Chrome. I'm cc'ing Kev 
Needham, our product manager for addons, to provide more details if he 
has them.

The Addon SDK already has something similar, the system/child_process 
API which allows pipe-based communication with an external binary: 
https://developer.mozilla.org/en-US/Add-ons/SDK/Low-Level_APIs/system_child_process

Also, we expect to implement the USB interface so that extensions have 
direct access to USB devices via a stream API. I don't know whether that 
will help your particular use-case, since you'd still need to know the 
USB protocol details for the devices, but that might be a solution 
available to you.

I'm sure our addons team would appreciate any assistance with building 
and testing the native messaging or USB APIs. I'm happy to make 
introductions if you like.

--BDS

[1] 
https://blog.mozilla.org/addons/2015/08/21/the-future-of-developing-firefox-add-ons/