manifest file for native messaging app

Andrew Swan aswan at mozilla.com
Thu Sep 28 19:48:26 UTC 2017


no bug needed, we have bug 1361459


On Thu, Sep 28, 2017 at 12:34 PM, Andrew McKay <amckay at mozilla.com> wrote:

> It sounds like we shouldn't throw an error if the allowed_origins key
> exists and just ignore it. Would you be so kind as to file a bug about
> that? I can't remember why different keys were decided upon though.
>
> https://bugzilla.mozilla.org/enter_bug.cgi?product=Toolkit&
> component=WebExtensions:%20Untriaged
>
> On 28 September 2017 at 07:18, Steinhour, Wayne
> <W.Steinhour at techsmith.com> wrote:
> > I’m porting a Chrome extension to a Firefox extension that will use the
> > WebExtension API.  These extensions use Native Messaging to communicate
> with
> > an application.  I had expected to be able to use the same manifest
> (json)
> > file for the application.  The specs for the manifest in Chrome and
> Firefox
> > are very similar, differing only in the keywords used to set the IDs of
> the
> > extensions that the application can communicate with.
> >
> >
> >
> > Chrome uses this in the json:
> >
> >      "allowed_origins": [ "<ID of the extension>" ]
> >
> >
> >
> > Firefox uses:
> >
> >     "allowed_extensions": [ "<ID of the extension>" ]
> >
> >
> >
> >
> >
> > I had expected that I could just add the “allowed_extensions” keyword and
> > array to the manifest, allowing the use of a single manifest file for
> both
> > browsers.  Chrome seems happy to have both keywords present in the
> file.  It
> > just ignores the one it does not care about.  Firefox does not like it so
> > much.  It refuses to establish the Port connection between the extension
> and
> > the app when the “allowed_origins” is present.
> >
> >
> >
> > Is this the expected behavior or is it a bug in how Firefox is parsing
> the
> > json?
> >
> >
> >
> > The work-around is no big deal.  I will need to use a separate manifest
> file
> > for Chrome and Firefox.  It just seems unexpected to me.
> >
> >
> >
> > Wayne
> >
> >
> > _______________________________________________
> > Webextensions-support mailing list
> > Webextensions-support at mozilla.org
> > https://mail.mozilla.org/listinfo/webextensions-support
> >
> _______________________________________________
> Webextensions-support mailing list
> Webextensions-support at mozilla.org
> https://mail.mozilla.org/listinfo/webextensions-support
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/webextensions-support/attachments/20170928/d9225531/attachment.html>


More information about the Webextensions-support mailing list