OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // This proto file includes: | 5 // This proto file includes: |
6 // (1) Client side phishing and malware detection request and response | 6 // (1) Client side phishing and malware detection request and response |
7 // protocol buffers. Those protocol messages should be kept in sync | 7 // protocol buffers. Those protocol messages should be kept in sync |
8 // with the server implementation. | 8 // with the server implementation. |
9 // | 9 // |
10 // (2) Safe Browsing reporting protocol buffers. | 10 // (2) Safe Browsing reporting protocol buffers. |
(...skipping 817 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
828 optional bool did_proceed = 8; | 828 optional bool did_proceed = 8; |
829 | 829 |
830 // Whether user visited this origin before. | 830 // Whether user visited this origin before. |
831 optional bool repeat_visit = 9; | 831 optional bool repeat_visit = 9; |
832 | 832 |
833 // The same token in ClientDownloadResponse. This field is only set if its | 833 // The same token in ClientDownloadResponse. This field is only set if its |
834 // report type is DANGEROUS_DOWNLOAD_RECOVERY, DANGEROUS_DOWNLOAD_WARNING or | 834 // report type is DANGEROUS_DOWNLOAD_RECOVERY, DANGEROUS_DOWNLOAD_WARNING or |
835 // DANGEROUS_DOWNLOAD_BY_API. | 835 // DANGEROUS_DOWNLOAD_BY_API. |
836 optional bytes token = 15; | 836 optional bytes token = 15; |
837 } | 837 } |
838 | |
839 // Canonical representation of raster image data. | |
840 message ImageData { | |
841 // Image bitmap encoded as PNG, after downscaling to <= 512x512. | |
842 optional bytes png_data = 1; | |
843 | |
844 message Dimensions { | |
845 optional int32 width = 1; | |
846 optional int32 height = 2; | |
847 } | |
848 | |
849 optional Dimensions dimensions = 2; | |
850 optional Dimensions original_dimensions = 3; // iff downscaled | |
851 } | |
852 | |
853 // Reporting protobuf for an image served as part of a browser notification. | |
854 message NotificationImageReportRequest { | |
855 optional string notification_origin = 1; // Src-origin of the notification. | |
856 optional ImageData image = 2; // The bitmap of the image. | |
857 | |
858 // Note that the image URL is deliberately omitted as it would be untrusted, | |
859 // since the notification image fetch may be intercepted by a Service Worker | |
860 // (even if the image URL is cross-origin). Otherwise a website could mislead | |
861 // Safe Browsing into associating phishing image bitmaps with safe image URLs. | |
862 } | |
863 // Response: None (empty body). | |
Peter Beverloo
2017/01/11 18:23:56
Stray line?
johnme
2017/01/11 20:05:07
Done (moved to comment above NotificationImageRepo
| |
OLD | NEW |