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

Unified Diff: third_party/WebKit/LayoutTests/http/tests/credentialmanager/resources/echo-post.php

Issue 1918253002: CREDENTIAL: Credentials should be submitted within a registrable domain. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: vabr@ Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/http/tests/credentialmanager/resources/echo-post.php
diff --git a/third_party/WebKit/LayoutTests/http/tests/credentialmanager/resources/echo-post.php b/third_party/WebKit/LayoutTests/http/tests/credentialmanager/resources/echo-post.php
index 907680f45a223b978cf25cb9ebab50e9a4f04ff3..c02093f2fa3dfad0f9c60e47b4ca069cb2cc7931 100644
--- a/third_party/WebKit/LayoutTests/http/tests/credentialmanager/resources/echo-post.php
+++ b/third_party/WebKit/LayoutTests/http/tests/credentialmanager/resources/echo-post.php
@@ -1,3 +1,9 @@
<?php
+ $request_origin_value = $_SERVER["HTTP_ORIGIN"];
+ if (!is_null($request_origin_value)) {
+ header("Access-Control-Allow-Origin: $request_origin_value");
+ header("Access-Control-Allow-Credentials: true");
+ header("Access-Control-Allow-Methods: GET,POST,OPTIONS");
+ }
echo json_encode($_POST);
?>

Powered by Google App Engine
This is Rietveld 408576698