Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(542)

Issue 668983003: Enable chrome.mdns for Chrome Apps (Closed)

Created:
6 years, 2 months ago by Red Daly
Modified:
5 years, 9 months ago
CC:
chromium-reviews, chromium-apps-reviews_chromium.org, extensions-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Allows all packaged apps to use the chrome.mdns API, and removes whitelist that restricts the set of service type that can be discovered. R=mkwst@chromium.org,mfoltz@chromium.org BUG=426500 Committed: https://crrev.com/68ea490084597d5d4640e782989c0a6a094dcd21 Cr-Commit-Position: refs/heads/master@{#322671}

Patch Set 1 #

Patch Set 2 : Add one more extension to mdns whitelist. #

Patch Set 3 : Open up access to chrome.mdns API to all packaged apps #

Total comments: 6

Patch Set 4 : Reinstate mdns service type whitelist for extensions and fix formatting. #

Total comments: 13

Patch Set 5 : Respond to kalman's comments. #

Total comments: 13

Patch Set 6 : Fix unsubscription bug and refactor according to comments #

Total comments: 4

Patch Set 7 : Get extension object using different means, and modify line spacing. #

Patch Set 8 : Add unit test for MDnsAPI #

Total comments: 6

Patch Set 9 : Enable chrome.mdns for Chrome Apps #

Patch Set 10 : Rebase chrome.mdns changes onto master HEAD before submission #

Patch Set 11 : Revert additions to chrome.mdns whitelist accidentally reintroduced during rebase #

Patch Set 12 : Squash all changes into a single git commit #

Unified diffs Side-by-side diffs Delta from patch set Stats (+252 lines, -16 lines) Patch
M chrome/browser/extensions/api/mdns/mdns_api.cc View 1 2 3 4 5 6 7 8 9 7 chunks +26 lines, -14 lines 0 comments Download
A chrome/browser/extensions/api/mdns/mdns_api_unittest.cc View 1 2 3 4 5 6 7 8 9 1 chunk +217 lines, -0 lines 0 comments Download
M chrome/browser/extensions/api/mdns/mdns_apitest.cc View 1 2 3 4 5 6 7 8 9 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/chrome_tests_unit.gypi View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -0 lines 0 comments Download
M chrome/common/extensions/api/_permission_features.json View 1 2 3 4 5 6 7 8 9 10 2 chunks +6 lines, -2 lines 0 comments Download

Messages

Total messages: 31 (6 generated)
Red Daly
6 years, 2 months ago (2014-10-21 22:00:01 UTC) #1
reddaly
This is my first Chromium change, so I don't exactly know what I'm doing :)
6 years, 2 months ago (2014-10-21 22:04:14 UTC) #2
Mike West
kalman@ is a better reviewer for this than I.
6 years, 2 months ago (2014-10-22 03:00:32 UTC) #4
not at google - send to devlin
Let's discuss this on the bug.
6 years, 2 months ago (2014-10-22 15:27:49 UTC) #5
not at google - send to devlin
I don't see anything wrong with the way these are whitelisted. If you want, add ...
6 years, 2 months ago (2014-10-23 17:37:49 UTC) #7
Red Daly
On 2014/10/23 17:37:49, kalman wrote: > I don't see anything wrong with the way these ...
6 years, 1 month ago (2014-10-29 23:09:36 UTC) #9
mark a. foltz
https://codereview.chromium.org/668983003/diff/40001/chrome/browser/extensions/api/mdns/mdns_api.cc File chrome/browser/extensions/api/mdns/mdns_api.cc (right): https://codereview.chromium.org/668983003/diff/40001/chrome/browser/extensions/api/mdns/mdns_api.cc#newcode102 chrome/browser/extensions/api/mdns/mdns_api.cc:102: registry->RegisterDnsSdListener(*it); To preserve existing behavior, I think extensions should ...
6 years, 1 month ago (2014-10-31 06:29:15 UTC) #10
Red Daly
Responded to Mark's comments. PTAL. https://codereview.chromium.org/668983003/diff/40001/chrome/browser/extensions/api/mdns/mdns_api.cc File chrome/browser/extensions/api/mdns/mdns_api.cc (right): https://codereview.chromium.org/668983003/diff/40001/chrome/browser/extensions/api/mdns/mdns_api.cc#newcode102 chrome/browser/extensions/api/mdns/mdns_api.cc:102: registry->RegisterDnsSdListener(*it); On 2014/10/31 06:29:15, ...
6 years, 1 month ago (2014-11-17 22:50:01 UTC) #11
not at google - send to devlin
https://codereview.chromium.org/668983003/diff/60001/chrome/browser/extensions/api/mdns/mdns_api.cc File chrome/browser/extensions/api/mdns/mdns_api.cc (right): https://codereview.chromium.org/668983003/diff/60001/chrome/browser/extensions/api/mdns/mdns_api.cc#newcode122 chrome/browser/extensions/api/mdns/mdns_api.cc:122: const extensions::ExtensionRegistry* ext_registry = This file is in the ...
6 years, 1 month ago (2014-11-17 23:22:15 UTC) #12
Red Daly
https://codereview.chromium.org/668983003/diff/60001/chrome/browser/extensions/api/mdns/mdns_api.cc File chrome/browser/extensions/api/mdns/mdns_api.cc (right): https://codereview.chromium.org/668983003/diff/60001/chrome/browser/extensions/api/mdns/mdns_api.cc#newcode122 chrome/browser/extensions/api/mdns/mdns_api.cc:122: const extensions::ExtensionRegistry* ext_registry = On 2014/11/17 23:22:15, kalman wrote: ...
6 years, 1 month ago (2014-11-19 21:31:50 UTC) #13
mark a. foltz
The extension vs. app behavior should be unit tested if possible (failing that, a browser ...
6 years ago (2014-12-09 23:56:34 UTC) #14
not at google - send to devlin
https://codereview.chromium.org/668983003/diff/80001/chrome/browser/extensions/api/mdns/mdns_api.cc File chrome/browser/extensions/api/mdns/mdns_api.cc (right): https://codereview.chromium.org/668983003/diff/80001/chrome/browser/extensions/api/mdns/mdns_api.cc#newcode30 chrome/browser/extensions/api/mdns/mdns_api.cc:30: // whitelisted set of service types. Note that a ...
6 years ago (2014-12-10 18:23:05 UTC) #15
Red Daly
Uploading my changes in response to the comments. I still need to write an accompanying ...
5 years, 11 months ago (2015-01-26 21:55:33 UTC) #16
not at google - send to devlin
lgtm https://codereview.chromium.org/668983003/diff/100001/chrome/browser/extensions/api/mdns/mdns_api.cc File chrome/browser/extensions/api/mdns/mdns_api.cc (right): https://codereview.chromium.org/668983003/diff/100001/chrome/browser/extensions/api/mdns/mdns_api.cc#newcode105 chrome/browser/extensions/api/mdns/mdns_api.cc:105: GetExtensionById((*it)->extension_id(), ExtensionRegistry::ENABLED); Just do: ... = ExtensionRegistry::Get(...)->enabled_extensions().Get(extension_id()); https://codereview.chromium.org/668983003/diff/100001/chrome/browser/extensions/api/mdns/mdns_api.cc#newcode133 ...
5 years, 11 months ago (2015-01-26 22:13:35 UTC) #17
Red Daly
https://chromiumcodereview.appspot.com/668983003/diff/100001/chrome/browser/extensions/api/mdns/mdns_api.cc File chrome/browser/extensions/api/mdns/mdns_api.cc (right): https://chromiumcodereview.appspot.com/668983003/diff/100001/chrome/browser/extensions/api/mdns/mdns_api.cc#newcode105 chrome/browser/extensions/api/mdns/mdns_api.cc:105: GetExtensionById((*it)->extension_id(), ExtensionRegistry::ENABLED); On 2015/01/26 22:13:35, kalman wrote: > Just ...
5 years, 11 months ago (2015-01-26 23:46:23 UTC) #18
Red Daly
I am trying to unit test the whitelisting functionality, as suggested by Mark. The code ...
5 years, 11 months ago (2015-01-27 00:39:57 UTC) #19
not at google - send to devlin
On 2015/01/27 00:39:57, Red Daly wrote: > I am trying to unit test the whitelisting ...
5 years, 11 months ago (2015-01-27 00:50:52 UTC) #20
mark a. foltz
lgtm You should be able to mock out just the parts of BrowserContext that you ...
5 years, 11 months ago (2015-01-27 00:57:20 UTC) #21
Red Daly
On 2015/01/27 00:57:20, mark a. foltz wrote: > lgtm > > You should be able ...
5 years, 9 months ago (2015-03-16 22:15:48 UTC) #22
Vitaly Buka (NO REVIEWS)
lgtm https://codereview.chromium.org/668983003/diff/140001/chrome/browser/extensions/api/mdns/mdns_api.cc File chrome/browser/extensions/api/mdns/mdns_api.cc (right): https://codereview.chromium.org/668983003/diff/140001/chrome/browser/extensions/api/mdns/mdns_api.cc#newcode132 chrome/browser/extensions/api/mdns/mdns_api.cc:132: for (std::set<std::string>::iterator it = added_service_types.begin(); maybe: for (const ...
5 years, 9 months ago (2015-03-18 19:07:00 UTC) #24
Vitaly Buka (NO REVIEWS)
lgtm https://codereview.chromium.org/668983003/diff/140001/chrome/common/extensions/api/_permission_features.json File chrome/common/extensions/api/_permission_features.json (right): https://codereview.chromium.org/668983003/diff/140001/chrome/common/extensions/api/_permission_features.json#newcode728 chrome/common/extensions/api/_permission_features.json:728: "channel": "stable", Please ignore this one, we are ...
5 years, 9 months ago (2015-03-18 21:09:14 UTC) #25
Red Daly
Responded to all comments. I'll now rebase onto HEAD, upload a new patch set and ...
5 years, 9 months ago (2015-03-27 20:06:08 UTC) #26
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/668983003/220001
5 years, 9 months ago (2015-03-27 22:31:40 UTC) #29
commit-bot: I haz the power
Committed patchset #12 (id:220001)
5 years, 9 months ago (2015-03-27 23:18:38 UTC) #30
commit-bot: I haz the power
5 years, 9 months ago (2015-03-27 23:19:14 UTC) #31
Message was sent while issue was closed.
Patchset 12 (id:??) landed as
https://crrev.com/68ea490084597d5d4640e782989c0a6a094dcd21
Cr-Commit-Position: refs/heads/master@{#322671}

Powered by Google App Engine
This is Rietveld 408576698