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

Unified Diff: Source/devtools/front_end/audits/AuditRules.js

Issue 1294473004: DevTools: Remove proxy caching audit. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: rebase Created 5 years, 4 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
« no previous file with comments | « Source/devtools/front_end/audits/AuditCategories.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/devtools/front_end/audits/AuditRules.js
diff --git a/Source/devtools/front_end/audits/AuditRules.js b/Source/devtools/front_end/audits/AuditRules.js
index c3284fb7d0e27abca83fdf2cab459ff589f3bd4f..53122eecf8cf6652de95bba0158ebf7cabd402ee 100644
--- a/Source/devtools/front_end/audits/AuditRules.js
+++ b/Source/devtools/front_end/audits/AuditRules.js
@@ -747,7 +747,7 @@ WebInspector.AuditRules.CacheControlRule.prototype = {
_isExplicitlyNonCacheable: function(request)
{
var hasExplicitExp = this.hasExplicitExpiration(request);
- return !!this.responseHeaderMatch(request, "Cache-Control", "(no-cache|no-store|must-revalidate)") ||
+ return !!this.responseHeaderMatch(request, "Cache-Control", "(no-cache|no-store)") ||
!!this.responseHeaderMatch(request, "Pragma", "no-cache") ||
(hasExplicitExp && !this.freshnessLifetimeGreaterThan(request, 0)) ||
(!hasExplicitExp && !!request.url && request.url.indexOf("?") >= 0) ||
@@ -837,46 +837,6 @@ WebInspector.AuditRules.BrowserCacheControlRule.prototype = {
/**
* @constructor
- * @extends {WebInspector.AuditRules.CacheControlRule}
- */
-WebInspector.AuditRules.ProxyCacheControlRule = function() {
- WebInspector.AuditRules.CacheControlRule.call(this, "http-proxycache", WebInspector.UIString("Leverage proxy caching"));
-}
-
-WebInspector.AuditRules.ProxyCacheControlRule.prototype = {
- runChecks: function(requests, result, callback)
- {
- this.execCheck(WebInspector.UIString("Resources with a \"?\" in the URL are not cached by most proxy caching servers:"),
- this._questionMarkCheck, requests, result);
- this.execCheck(WebInspector.UIString("Consider adding a \"Cache-Control: public\" header to the following resources:"),
- this._publicCachingCheck, requests, result);
- this.execCheck(WebInspector.UIString("The following publicly cacheable resources contain a Set-Cookie header. This security vulnerability can cause cookies to be shared by multiple users."),
- this._setCookieCacheableCheck, requests, result);
- },
-
- _questionMarkCheck: function(request)
- {
- return request.url.indexOf("?") >= 0 && !this.hasResponseHeader(request, "Set-Cookie") && this.isPubliclyCacheable(request);
- },
-
- _publicCachingCheck: function(request)
- {
- return this.isCacheableResource(request) &&
- !this.isCompressible(request) &&
- !this.responseHeaderMatch(request, "Cache-Control", "public") &&
- !this.hasResponseHeader(request, "Set-Cookie");
- },
-
- _setCookieCacheableCheck: function(request)
- {
- return this.hasResponseHeader(request, "Set-Cookie") && this.isPubliclyCacheable(request);
- },
-
- __proto__: WebInspector.AuditRules.CacheControlRule.prototype
-}
-
-/**
- * @constructor
* @extends {WebInspector.AuditRule}
*/
WebInspector.AuditRules.ImageDimensionsRule = function()
« no previous file with comments | « Source/devtools/front_end/audits/AuditCategories.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698