-
Notifications
You must be signed in to change notification settings - Fork 6.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
SB: Modify referrer for copy paste navigation
When creating the referrer chain: - if the referrer is empty - the URL was the last copied URL to the clipboard Fill out the referrer and main-frame referrer with the frame and page where the copies were created. Bug: 754330 Change-Id: Iaaeb42d27ce8ee02f764fe728f7a100204dfd95e Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4528803 Reviewed-by: Xinghui Lu <xinghuilu@chromium.org> Reviewed-by: Daniel Rubery <drubery@chromium.org> Commit-Queue: Kristian Monsen <kristianm@chromium.org> Cr-Commit-Position: refs/heads/main@{#1150757}
- Loading branch information
1 parent
10a17e7
commit e10e236
Showing
8 changed files
with
476 additions
and
7 deletions.
There are no files selected for viewing
353 changes: 353 additions & 0 deletions
353
chrome/browser/safe_browsing/safe_browsing_navigation_observer_interactive_test.cc
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 12 additions & 0 deletions
12
chrome/test/data/safe_browsing/download_protection/navigation_observer/copy_referrer.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
<html> | ||
<body> | ||
<iframe id="iframe" src="copy_referrer_inner.html"></iframe> | ||
Main page contents | ||
|
||
<script> | ||
// The iframe needs to be focused to let the JS from test copy to | ||
// clipboard. | ||
document.getElementById('iframe').focus(); | ||
</script> | ||
</body> | ||
</html> |
5 changes: 5 additions & 0 deletions
5
.../test/data/safe_browsing/download_protection/navigation_observer/copy_referrer_inner.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<html> | ||
<body> | ||
Iframe contents | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters