OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 <include src="post_message_channel.js"> | 5 <include src="post_message_channel.js"> |
6 | 6 |
7 /** | 7 /** |
8 * @fileoverview Saml support for webview based auth. | 8 * @fileoverview Saml support for webview based auth. |
9 */ | 9 */ |
10 | 10 |
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
98 this.abortedTopLevelUrl_ = null; | 98 this.abortedTopLevelUrl_ = null; |
99 | 99 |
100 /** | 100 /** |
101 * The domain of the Saml IdP. | 101 * The domain of the Saml IdP. |
102 * @type {string} | 102 * @type {string} |
103 */ | 103 */ |
104 this.authDomain = ''; | 104 this.authDomain = ''; |
105 | 105 |
106 /** | 106 /** |
107 * Scraped password stored in an id to password field value map. | 107 * Scraped password stored in an id to password field value map. |
108 * @type {Object.<string, string>} | 108 * @type {Object<string, string>} |
109 * @private | 109 * @private |
110 */ | 110 */ |
111 this.passwordStore_ = {}; | 111 this.passwordStore_ = {}; |
112 | 112 |
113 /** | 113 /** |
114 * Whether Saml API is initialized. | 114 * Whether Saml API is initialized. |
115 * @type {boolean} | 115 * @type {boolean} |
116 */ | 116 */ |
117 this.apiInitialized_ = false; | 117 this.apiInitialized_ = false; |
118 | 118 |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
192 /** | 192 /** |
193 * Returns the number of scraped passwords. | 193 * Returns the number of scraped passwords. |
194 * @return {number} | 194 * @return {number} |
195 */ | 195 */ |
196 get scrapedPasswordCount() { | 196 get scrapedPasswordCount() { |
197 return this.getConsolidatedScrapedPasswords_().length; | 197 return this.getConsolidatedScrapedPasswords_().length; |
198 }, | 198 }, |
199 | 199 |
200 /** | 200 /** |
201 * Gets the de-duped scraped passwords. | 201 * Gets the de-duped scraped passwords. |
202 * @return {Array.<string>} | 202 * @return {Array<string>} |
203 * @private | 203 * @private |
204 */ | 204 */ |
205 getConsolidatedScrapedPasswords_: function() { | 205 getConsolidatedScrapedPasswords_: function() { |
206 var passwords = {}; | 206 var passwords = {}; |
207 for (var property in this.passwordStore_) { | 207 for (var property in this.passwordStore_) { |
208 passwords[this.passwordStore_[property]] = true; | 208 passwords[this.passwordStore_[property]] = true; |
209 } | 209 } |
210 return Object.keys(passwords); | 210 return Object.keys(passwords); |
211 }, | 211 }, |
212 | 212 |
(...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
444 | 444 |
445 onGetSAMLFlag_: function(channel, msg) { | 445 onGetSAMLFlag_: function(channel, msg) { |
446 return this.isSamlPage_; | 446 return this.isSamlPage_; |
447 }, | 447 }, |
448 }; | 448 }; |
449 | 449 |
450 return { | 450 return { |
451 SamlHandler: SamlHandler | 451 SamlHandler: SamlHandler |
452 }; | 452 }; |
453 }); | 453 }); |
OLD | NEW |