| Commit-Queue | +1 |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
You should probably add email verification to https://source.chromium.org/chromium/chromium/src/+/main:services/network/cors/cors_url_loader_factory.cc;l=767 as well
Set Sec-Fetch-Dest to email-verification for those requestsMaybe add a link to https://github.com/WICG/email-verification-protocol in the description
network::mojom::RequestDestination destination,why this change? isn't this always WebIdentity?
network::mojom::RequestDestination::kWebIdentity,I almost wonder if this should be a constructor argument, since the IDP subclass always uses webidentity and the email verification subclass alwas uses email verification
TEST_F(IdpNetworkRequestManagerTest, FetchWellKnownRequestDestination) {guess these can't hurt but fwiw we do check this in wpt as well (https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/web_tests/external/wpt/fedcm/support/request-params-check.py;l=1?q=commonchec%20fedcm&ss=chromium)
constexpr char kEmailVerification[] = "email-verification";No other destination uses a dash, I don't think this one should be the exception
"email-verification",Weird, not sure why https://crrev.com/c/5925915 added webidentity here, the renderer should never see it.
Anyway, this should probably not be under the FedCM heading, maybe link to https://github.com/WICG/email-verification-protocol ?
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
You should probably add email verification to https://source.chromium.org/chromium/chromium/src/+/main:services/network/cors/cors_url_loader_factory.cc;l=767 as well
Done
Set Sec-Fetch-Dest to email-verification for those requestsMaybe add a link to https://github.com/WICG/email-verification-protocol in the description
Done
why this change? isn't this always WebIdentity?
Done
network::mojom::RequestDestination::kWebIdentity,I almost wonder if this should be a constructor argument, since the IDP subclass always uses webidentity and the email verification subclass alwas uses email verification
Oh good idea. Done
TEST_F(IdpNetworkRequestManagerTest, FetchWellKnownRequestDestination) {guess these can't hurt but fwiw we do check this in wpt as well (https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/web_tests/external/wpt/fedcm/support/request-params-check.py;l=1?q=commonchec%20fedcm&ss=chromium)
Acknowledged
constexpr char kEmailVerification[] = "email-verification";No other destination uses a dash, I don't think this one should be the exception
Hmm maybe it should be `emailverification`?
Weird, not sure why https://crrev.com/c/5925915 added webidentity here, the renderer should never see it.
Anyway, this should probably not be under the FedCM heading, maybe link to https://github.com/WICG/email-verification-protocol ?
I guess we can add notreached for these in the converter since it is only used for the request destination attribute getter which should never return these... Done
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
lgtm.
Now that https://crrev.com/c/7017375 has landed you could consider adding kEmailVerification here as well:
https://chromium-review.googlesource.com/c/chromium/src/+/7017375/20/services/network/url_loader_util.cc
https://chromium-review.googlesource.com/c/chromium/src/+/7017375/20/services/network/cors/cors_url_loader_factory.cc
(and maybe https://chromium-review.googlesource.com/c/chromium/src/+/7017375/20/content/browser/devtools/devtools_url_loader_interceptor.cc)
constexpr char kEmailVerification[] = "email-verification";Nicolás PeñaNo other destination uses a dash, I don't think this one should be the exception
Hmm maybe it should be `emailverification`?
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
lgtm.
Now that https://crrev.com/c/7017375 has landed you could consider adding kEmailVerification here as well:
https://chromium-review.googlesource.com/c/chromium/src/+/7017375/20/services/network/url_loader_util.cc
https://chromium-review.googlesource.com/c/chromium/src/+/7017375/20/services/network/cors/cors_url_loader_factory.cc
(and maybe https://chromium-review.googlesource.com/c/chromium/src/+/7017375/20/content/browser/devtools/devtools_url_loader_interceptor.cc)
I don't follow what the last one does but the other two done
PTAL
mpdenton@: third_party/blink/renderer/core/fetch/request_util.cc and services/network/public/mojom/fetch_api.mojom
blundell@: rest of services/network and components/services/storage/service_worker
sophiechang@: chrome/browser/predictors
constexpr char kEmailVerification[] = "email-verification";Nicolás PeñaNo other destination uses a dash, I don't think this one should be the exception
Christian BiesingerHmm maybe it should be `emailverification`?
Yeah I think that would be better.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Commit-Queue | +1 |
Missed one :( kelvinjiang@ PTAL extensions/browser/api/web_request/ web_request_resource_type.cc
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
// Only the browser process is allowed to initiate FedCM or email
// verification requests.Can we do an allowlist here instead of a denylist? Otherwise it seems quite easy to miss adding something here.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Thanks! ->horo@ as closer OWNER of //components/services/storage and //services/network
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Commit-Queue | +1 |
// Only the browser process is allowed to initiate FedCM or email
// verification requests.Can we do an allowlist here instead of a denylist? Otherwise it seems quite easy to miss adding something here.
Done but I don't know what should belong in the allowlist. And for the purpose of not introducing changes in this CL, I have added all except the two we checked below.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
| Code-Review | +1 |
// Only the browser process is allowed to initiate FedCM or email
// verification requests.Nicolás PeñaCan we do an allowlist here instead of a denylist? Otherwise it seems quite easy to miss adding something here.
Done but I don't know what should belong in the allowlist. And for the purpose of not introducing changes in this CL, I have added all except the two we checked below.
Sounds good, thanks!
// Allowed destinations from the browser process:I think this should say unprivileged process or something
```suggestion
// Allowed destinations from unprivileged process:
```
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Code-Review | +1 |
lgtm with some nits.
default:Could you please avoid using a default case here? That way, we'll be forced to update this code whenever a new RequestDestination is added.
// https://w3c-fedid.github.io/FedCM/
"webidentity",I believe you are removing webidentity here because the RequestDestination for webidentity is never set on the Blink side. Please write about it in the commit comment.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
| Commit-Queue | +2 |
I think this should say unprivileged process or something
```suggestion
// Allowed destinations from unprivileged process:
```
Done
Could you please avoid using a default case here? That way, we'll be forced to update this code whenever a new RequestDestination is added.
Done
// https://w3c-fedid.github.io/FedCM/
"webidentity",I believe you are removing webidentity here because the RequestDestination for webidentity is never set on the Blink side. Please write about it in the commit comment.
Done
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
6 is the latest approved patch-set.
The change was submitted with unreviewed changes in the following files:
```
The name of the file: services/network/cors/cors_url_loader_factory.cc
Insertions: 3, Deletions: 2.
@@ -765,7 +765,7 @@
}
switch (request.destination) {
- // Allowed destinations from the browser process:
+ // Allowed destinations from unprivileged process:
case network::mojom::RequestDestination::kEmpty:
case network::mojom::RequestDestination::kAudio:
case network::mojom::RequestDestination::kAudioWorklet:
@@ -794,7 +794,8 @@
case network::mojom::RequestDestination::kJson:
case network::mojom::RequestDestination::kSharedStorageWorklet:
break;
- default:
+ case network::mojom::RequestDestination::kWebIdentity:
+ case network::mojom::RequestDestination::kEmailVerification:
mojo::ReportBadMessage(
"CorsURLLoaderFactory: attempt to use forbidden destination from "
"renderer");
```
Set Sec-Fetch-Dest to email-verification for those requests
This CL aligns the implementation with the design described in
https://github.com/WICG/email-verification-protocol.
Also remove 'webidentity' from request.idl on Blink, since it is never
set on the Blink side.
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |