Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multicast sample has invalid permissions. #119

Closed
mckoss opened this issue Jul 8, 2013 · 5 comments
Closed

Multicast sample has invalid permissions. #119

mckoss opened this issue Jul 8, 2013 · 5 comments
Labels

Comments

@mckoss
Copy link

mckoss commented Jul 8, 2013

On Chrome version 27 (stable), I can't get this sample to load properly.

Could not load extension from '/Users/<username>/src/chrome-app-samples/multicast'. Invalid value for 'permissions[socket]'.

If I remove the socket['udp-multicast-membership'] permission, the app will load (though I don't think it works properly).

@Robbert
Copy link

Robbert commented May 13, 2014

"sockets": {
  "udp": {
    "bind": "*",
    "send": "*",
    "multicastMembership": ""
  }
}

The empty string value for "multicastMembership" isn't obvious at all, I had to resort to reading the C++ unit tests to find out the correct value.

The manifest.json documentation states the value requires a "host:port" value, but "*" and any other valid host:port value is regarded invalid.
https://developer.chrome.com/apps/manifest/sockets
https://chromium.googlesource.com/chromium/chromium/+/6697478358bc016fd5acffdb1401d79f405713f5/chrome/common/extensions/api/manifest_types.json

These are unit tests:
https://code.google.com/p/chromium/codesearch#chromium/src/extensions/common/api/sockets/sockets_manifest_permission_unittest.cc&q=multicastMembership&sq=package:chromium&dr=C&l=264

@beaufortfrancois
Copy link
Member

@Robbert Thank you for your feedback.

@ikarienator It looks this sample App still uses the old chrome.socket API with the deprecated way of setting permission ;( Would you have time to upgrade this App?

@rpaquay May you update the official documentation at https://chromium.googlesource.com/chromium/src/+/master/chrome/common/extensions/docs/templates/articles/manifest/sockets.html so that it's more clear regarding the multicastMembership value?

@beaufortfrancois
Copy link
Member

@Robbert The "multicastMembership" option is now shown at https://developer.chrome.com/apps/manifest/sockets

I will update soon the mutilcast sample app based on @rpaquay's work.

@beaufortfrancois
Copy link
Member

For info, there is an issue on Chrome OS: http://crbug.com/233052.
The firewall seems to block chrome.sockets.

@beaufortfrancois
Copy link
Member

Multicast sample has been updated to use the new chrome.sockets.udp API.
Please reopen if you're still experiencing any issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants