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 syntax = "proto2"; | 5 syntax = "proto2"; |
6 | 6 |
7 option optimize_for = LITE_RUNTIME; | 7 option optimize_for = LITE_RUNTIME; |
8 | 8 |
9 package gcm; | 9 package gcm; |
10 | 10 |
(...skipping 11 matching lines...) Expand all Loading... | |
22 // The private key matching the size requirements of |type|. | 22 // The private key matching the size requirements of |type|. |
23 optional bytes private_key = 2; | 23 optional bytes private_key = 2; |
24 | 24 |
25 // The public key as an X.509 SubjectPublicKeyInfo block. | 25 // The public key as an X.509 SubjectPublicKeyInfo block. |
26 optional bytes public_key_x509 = 3; | 26 optional bytes public_key_x509 = 3; |
27 | 27 |
28 // The public key as an uncompressed EC point according to SEC 2.3.3. | 28 // The public key as an uncompressed EC point according to SEC 2.3.3. |
29 optional bytes public_key = 4; | 29 optional bytes public_key = 4; |
30 } | 30 } |
31 | 31 |
32 // Stores a vector of public/private key-pairs associated with an app id. | 32 // Stores a vector of public/private key-pairs associated with an app id and |
33 // optionally the authorized entity of an instance id token. | |
33 // | 34 // |
34 // In the current implementation, each app id will have a single encryption key- | 35 // In the current implementation, each (app_id, instance_id_authorized_entity) |
35 // pair associated with it at most. The message allows for multiple key pairs | 36 // pair will have a single encryption key-pair associated with it at most. The |
36 // in case we need to force-cycle all keys, allowing the old keys to remain | 37 // message allows for multiple key pairs in case we need to force-cycle all |
37 // valid for a period of time enabling the web app to update. | 38 // keys, allowing the old keys to remain valid for a period of time enabling the |
39 // web app to update. | |
38 // | 40 // |
39 // Next tag: 4 | 41 // Next tag: 4 |
Peter Beverloo
2016/05/09 14:10:10
5
johnme
2016/05/09 18:15:55
Done.
| |
40 message EncryptionData { | 42 message EncryptionData { |
41 // The app id to whom this encryption data belongs. | 43 // The app id to whom this encryption data belongs. |
42 required string app_id = 1; | 44 required string app_id = 1; |
43 | 45 |
46 // The sender id of the instance id token to whom this encryption data | |
47 // belongs. Must not be empty. Must be omitted for legacy GCM registrations. | |
48 optional string instance_id_authorized_entity = 4; | |
49 | |
44 // The actual public/private key-pairs. | 50 // The actual public/private key-pairs. |
45 repeated KeyPair keys = 2; | 51 repeated KeyPair keys = 2; |
46 | 52 |
47 // The authentication secret associated with the subscription. Must be a | 53 // The authentication secret associated with the subscription. Must be a |
48 // cryptographically secure number of at least 12 bytes. | 54 // cryptographically secure number of at least 12 bytes. |
49 optional bytes auth_secret = 3; | 55 optional bytes auth_secret = 3; |
50 } | 56 } |
OLD | NEW |