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

Side by Side Diff: chrome/common/safe_browsing/permission_report.proto

Issue 2001963003: Add protocol buffer for reporting permission actions to Safe Browsing servers (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rename proto Created 4 years, 7 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 unified diff | Download patch
« no previous file with comments | « chrome/common/safe_browsing/BUILD.gn ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 // Protocol buffer for permission reports sent to the safe browsing client-side
6 // detection (CSD) frontends.
7
8 syntax = "proto2";
9
10 option optimize_for = LITE_RUNTIME;
11
12 package safe_browsing;
13
14 // A single Permission Report sent to Safe Browsing client-side detection
15 // frontends.
16 message PermissionReport {
17 // The origin (scheme/host/port) of the site requesting the permission.
18 optional string origin = 1;
19
20 // The permission being requested/acted upon.
21 optional PermissionType permission = 2;
22
23 // The platform.
24 optional PlatformType platform_type = 3;
25
26 // When the request was initiated.
27 repeated RequestTrigger request_trigger = 4;
28
29 // The action the user took. Required.
30 optional Action action = 5;
31
32 // The UI used to complete the action.
33 optional SourceUI source_ui = 6;
34
35 // The relevant field trials enabled for this report.
36 repeated string field_trials = 7;
Nathan Parker 2016/05/25 21:13:02 Once you figure out what form the field trial stri
kcarattini 2016/05/26 01:53:26 Stefano, please add a TOTO in here to update the f
stefanocs 2016/05/26 03:13:37 Done.
37
38 // Platform
39 enum PlatformType {
40 PLATFORM_TYPE_UNSPECIFIED = 0;
41 DESKTOP = 1;
42 ANDROID = 2;
43 }
44
45 // Various request triggers we want to record, e.g. on page load.
46 enum RequestTrigger {
47 REQUEST_TRIGGER_UNSPECIFIED = 0;
48 ONLOAD = 1;
49 AFTER_GESTURE = 2;
50 }
51
52 // User Permission Actions
53 enum Action {
54 GRANTED = 0;
Nathan Parker 2016/05/25 21:13:02 I have a theory, not sure if it's a good one, that
kcarattini 2016/05/26 01:53:26 I don't disagree with you in theory, but in this c
kcarattini 2016/05/26 03:02:48 Just had a lengthy discussion about PB enums! I ag
stefanocs 2016/05/26 03:13:37 Done.
55 DENIED = 1;
56 DISMISSED = 2;
57 IGNORED = 3;
58 REVOKED = 4;
59 }
60
61 // Places in the UI that a permission change can occur.
62 enum SourceUI {
63 SOURCE_UI_UNSPECIFIED = 0;
64 PROMPT = 1;
65 OIB = 2;
66 // TODO(stefanocs): Remove CONTENT_SETTINGS from the corresponding Safe
67 // Browsing logs proto.
68 SITE_SETTINGS = 3;
69 }
70
71 // The various types of permissions. This should stay in sync with the
72 // corresponding Safe Browsing logs enum.
Nathan Parker 2016/05/25 21:13:02 How about a comment up top to make it easy for peo
kcarattini 2016/05/26 01:53:26 Do we usually put pointers into google3 code in ch
stefanocs 2016/05/26 06:48:25 Done.
73 enum PermissionType {
74 UNKNOWN_PERMISSION = 0;
75 MIDI_SYSEX = 1;
76 PUSH_MESSAGING = 2;
77 NOTIFICATIONS = 3;
78 GEOLOCATION = 4;
79 PROTECTED_MEDIA_IDENTIFIER = 5;
80 MIDI = 6;
81 DURABLE_STORAGE = 7;
82 AUDIO_CAPTURE = 8;
83 VIDEO_CAPTURE = 9;
84 }
85 }
OLDNEW
« no previous file with comments | « chrome/common/safe_browsing/BUILD.gn ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698