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

Unified Diff: chrome/browser/resources/cryptotoken/googleapprovedorigins.js

Issue 799923007: Enable 3rd party support for Security Keys. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years 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: chrome/browser/resources/cryptotoken/googleapprovedorigins.js
diff --git a/chrome/browser/resources/cryptotoken/googleapprovedorigins.js b/chrome/browser/resources/cryptotoken/googleapprovedorigins.js
deleted file mode 100644
index 9b345d5fc6a0227fc9a76fb84ac1fe0ffbd2fa59..0000000000000000000000000000000000000000
--- a/chrome/browser/resources/cryptotoken/googleapprovedorigins.js
+++ /dev/null
@@ -1,32 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-/**
- * @fileoverview Provides an implementation of approved origins that always
- * (and only) allows google.com to use security keys.
- *
- */
-'use strict';
-
-/**
- * Allows the caller to check whether the user has approved the use of
- * security keys from an origin.
- * @constructor
- * @implements {ApprovedOrigins}
- */
-function GoogleApprovedOrigins() {}
-
-/**
- * Checks whether the origin is approved to use security keys. (If not, an
- * approval prompt may be shown.)
- * @param {string} origin The origin to approve.
- * @param {number=} opt_tabId A tab id to display approval prompt in, if
- * necessary.
- * @return {Promise.<boolean>} A promise for the result of the check.
- */
-GoogleApprovedOrigins.prototype.isApprovedOrigin = function(origin, opt_tabId) {
- var anchor = document.createElement('a');
- anchor.href = origin;
- return Promise.resolve(/google.com$/.test(anchor.hostname));
-};

Powered by Google App Engine
This is Rietveld 408576698