Index: chrome/browser/resources/net_internals/main.js |
=================================================================== |
--- chrome/browser/resources/net_internals/main.js (revision 78565) |
+++ chrome/browser/resources/net_internals/main.js (working copy) |
@@ -1,4 +1,4 @@ |
-// Copyright (c) 2010 The Chromium Authors. All rights reserved. |
+// Copyright (c) 2011 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. |
@@ -223,6 +223,11 @@ |
// When viewing a log file, all tabs are hidden except the event view, |
// and all received events are ignored. |
this.isViewingLogFile_ = false; |
+ |
+ // True when cookies and authentication information should be removed from |
+ // displayed events. When true, such information should be hidden from |
+ // all pages. |
+ this.enableSecurityStripping_ = true; |
} |
/* |
@@ -822,6 +827,27 @@ |
}; |
/** |
+ * Sets the value of |enableSecurityStripping_| and informs log observers |
+ * of the change. |
+ */ |
+BrowserBridge.prototype.setSecurityStripping = |
+ function(enableSecurityStripping) { |
+ this.enableSecurityStripping_ = enableSecurityStripping; |
+ for (var i = 0; i < this.logObservers_.length; ++i) { |
+ if (this.logObservers_[i].onSecurityStrippingChanged) |
+ this.logObservers_[i].onSecurityStrippingChanged(); |
+ } |
+}; |
+ |
+/** |
+ * Returns whether or not cookies and authentication information should be |
+ * displayed for events that contain them. |
+ */ |
+BrowserBridge.prototype.getSecurityStripping = function() { |
+ return this.enableSecurityStripping_; |
+}; |
+ |
+/** |
* Informs log observers whether or not future events will be from a log file. |
* Hides all tabs except the events and data tabs when viewing a log file, shows |
* them all otherwise. |