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 #ifndef CONTENT_CHILD_SITE_ISOLATION_STATS_GATHERER_H_ | 5 #ifndef CONTENT_CHILD_SITE_ISOLATION_STATS_GATHERER_H_ |
6 #define CONTENT_CHILD_SITE_ISOLATION_STATS_GATHERER_H_ | 6 #define CONTENT_CHILD_SITE_ISOLATION_STATS_GATHERER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/gtest_prod_util.h" | 10 #include "base/gtest_prod_util.h" |
(...skipping 12 matching lines...) Expand all Loading... |
23 // see the compatibility impact of actual deployment of the policy. The UMA stat | 23 // see the compatibility impact of actual deployment of the policy. The UMA stat |
24 // categories SiteIsolationStatsGatherer gathers are as follows: | 24 // categories SiteIsolationStatsGatherer gathers are as follows: |
25 // | 25 // |
26 // SiteIsolation.AllResponses : # of all network responses. | 26 // SiteIsolation.AllResponses : # of all network responses. |
27 // SiteIsolation.XSD.DataLength : the length of the first packet of a response. | 27 // SiteIsolation.XSD.DataLength : the length of the first packet of a response. |
28 // SiteIsolation.XSD.MimeType (enum): | 28 // SiteIsolation.XSD.MimeType (enum): |
29 // # of responses from other sites, tagged with a document mime type. | 29 // # of responses from other sites, tagged with a document mime type. |
30 // 0:HTML, 1:XML, 2:JSON, 3:Plain, 4:Others | 30 // 0:HTML, 1:XML, 2:JSON, 3:Plain, 4:Others |
31 // SiteIsolation.XSD.[%MIMETYPE].Blocked : | 31 // SiteIsolation.XSD.[%MIMETYPE].Blocked : |
32 // blocked # of cross-site document responses grouped by sniffed MIME type. | 32 // blocked # of cross-site document responses grouped by sniffed MIME type. |
33 // SiteIsolation.XSD.[%MIMETYPE].Blocked.RenderableStatusCode : | 33 // SiteIsolation.XSD.[%MIMETYPE].Blocked.RenderableStatusCode2 : |
34 // # of responses with renderable status code, | 34 // # of responses with renderable status code, |
35 // out of SiteIsolation.XSD.[%MIMETYPE].Blocked. | 35 // out of SiteIsolation.XSD.[%MIMETYPE].Blocked. |
36 // SiteIsolation.XSD.[%MIMETYPE].Blocked.NonRenderableStatusCode : | 36 // SiteIsolation.XSD.[%MIMETYPE].Blocked.NonRenderableStatusCode : |
37 // # of responses with non-renderable status code, | 37 // # of responses with non-renderable status code, |
38 // out of SiteIsolation.XSD.[%MIMETYPE].Blocked. | 38 // out of SiteIsolation.XSD.[%MIMETYPE].Blocked. |
39 // SiteIsolation.XSD.[%MIMETYPE].NoSniffBlocked.RenderableStatusCode : | 39 // SiteIsolation.XSD.[%MIMETYPE].NoSniffBlocked.RenderableStatusCode2 : |
40 // # of responses failed to be sniffed for its MIME type, but blocked by | 40 // # of responses failed to be sniffed for its MIME type, but blocked by |
41 // "X-Content-Type-Options: nosniff" header, and with renderable status code | 41 // "X-Content-Type-Options: nosniff" header, and with renderable status code |
42 // out of SiteIsolation.XSD.[%MIMETYPE].Blocked. | 42 // out of SiteIsolation.XSD.[%MIMETYPE].Blocked. |
43 // SiteIsolation.XSD.[%MIMETYPE].NoSniffBlocked.NonRenderableStatusCode : | 43 // SiteIsolation.XSD.[%MIMETYPE].NoSniffBlocked.NonRenderableStatusCode : |
44 // # of responses failed to be sniffed for its MIME type, but blocked by | 44 // # of responses failed to be sniffed for its MIME type, but blocked by |
45 // "X-Content-Type-Options: nosniff" header, and with non-renderable status | 45 // "X-Content-Type-Options: nosniff" header, and with non-renderable status |
46 // code out of SiteIsolation.XSD.[%MIMETYPE].Blocked. | 46 // code out of SiteIsolation.XSD.[%MIMETYPE].Blocked. |
47 // SiteIsolation.XSD.[%MIMETYPE].NotBlocked : | 47 // SiteIsolation.XSD.[%MIMETYPE].NotBlocked : |
48 // # of responses, but not blocked due to failure of mime sniffing. | 48 // # of responses, but not blocked due to failure of mime sniffing. |
49 // SiteIsolation.XSD.[%MIMETYPE].NotBlocked.MaybeJS : | 49 // SiteIsolation.XSD.[%MIMETYPE].NotBlocked.MaybeJS : |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
91 | 91 |
92 // Imprecise JS sniffing; only appropriate for collecting UMA stat. | 92 // Imprecise JS sniffing; only appropriate for collecting UMA stat. |
93 static bool SniffForJS(base::StringPiece data); | 93 static bool SniffForJS(base::StringPiece data); |
94 | 94 |
95 DISALLOW_COPY_AND_ASSIGN(SiteIsolationStatsGatherer); | 95 DISALLOW_COPY_AND_ASSIGN(SiteIsolationStatsGatherer); |
96 }; | 96 }; |
97 | 97 |
98 } // namespace content | 98 } // namespace content |
99 | 99 |
100 #endif // CONTENT_CHILD_SITE_ISOLATION_STATS_GATHERER_H_ | 100 #endif // CONTENT_CHILD_SITE_ISOLATION_STATS_GATHERER_H_ |
OLD | NEW |