[Web Payment] Hosting manifest at payment method identifier URL.
Before this patch, the payment method manifest had to be hosted at a location that is pointed to from the payment method identifier URL via the HTTP Link rel=payment-method-manifest header. This complicated testing in Chrome and prevented hosting payment method manifests on popular hosting services, such as GitHub pages. This patch falls back to returning the content of the page if it does not have HTTP Link rel=payment-method-manifest header or that header is not valid. The downloader uses HTTP GET instead of HTTP HEAD for the payment method manifest, since the response body has to be considered. An empty response body now generates an error earlier: in the downloader instead of parser, because the parser always rejected empty input. After this patch, it's possible to host the payment method manifest directly at the URL of the payment method identifier, which makes testing Chrome and developing payment apps easier. Bug: 1035147 Change-Id: Id07c9023bac222ed45eecb8df91108f4df51e356 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2113735Reviewed-by:Danyao Wang <danyao@chromium.org> Commit-Queue: Rouslan Solomakhin <rouslan@chromium.org> Cr-Commit-Position: refs/heads/master@{#753569}
Showing
This diff is collapsed.
This diff is collapsed.
Please register or sign in to comment