OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CHROME_BROWSER_EXTENSIONS_INSTALL_SIGNER_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_INSTALL_SIGNER_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_INSTALL_SIGNER_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_INSTALL_SIGNER_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 20 matching lines...) Expand all Loading... |
31 // The set of ids that have been signed. | 31 // The set of ids that have been signed. |
32 ExtensionIdSet ids; | 32 ExtensionIdSet ids; |
33 | 33 |
34 // Both of these are just arrays of bytes, NOT base64-encoded. | 34 // Both of these are just arrays of bytes, NOT base64-encoded. |
35 std::string salt; | 35 std::string salt; |
36 std::string signature; | 36 std::string signature; |
37 | 37 |
38 // The date that the signature should expire, in YYYY-MM-DD format. | 38 // The date that the signature should expire, in YYYY-MM-DD format. |
39 std::string expire_date; | 39 std::string expire_date; |
40 | 40 |
41 // The time this signature was obtained from the server. | 41 // The time this signature was obtained from the server. Note that this |
| 42 // is computed locally and *not* signed by the server key. |
42 base::Time timestamp; | 43 base::Time timestamp; |
43 | 44 |
| 45 // The set of ids that the server indicated were invalid (ie not signed). |
| 46 // Note that this is computed locally and *not* signed by the signature. |
| 47 ExtensionIdSet invalid_ids; |
| 48 |
44 InstallSignature(); | 49 InstallSignature(); |
45 ~InstallSignature(); | 50 ~InstallSignature(); |
46 | 51 |
47 // Helper methods for serialization to/from a base::DictionaryValue. | 52 // Helper methods for serialization to/from a base::DictionaryValue. |
48 void ToValue(base::DictionaryValue* value) const; | 53 void ToValue(base::DictionaryValue* value) const; |
49 | 54 |
50 static scoped_ptr<InstallSignature> FromValue( | 55 static scoped_ptr<InstallSignature> FromValue( |
51 const base::DictionaryValue& value); | 56 const base::DictionaryValue& value); |
52 }; | 57 }; |
53 | 58 |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
114 | 119 |
115 // The time the request to the server was started. | 120 // The time the request to the server was started. |
116 base::Time request_start_time_; | 121 base::Time request_start_time_; |
117 | 122 |
118 DISALLOW_COPY_AND_ASSIGN(InstallSigner); | 123 DISALLOW_COPY_AND_ASSIGN(InstallSigner); |
119 }; | 124 }; |
120 | 125 |
121 } // namespace extensions | 126 } // namespace extensions |
122 | 127 |
123 #endif // CHROME_BROWSER_EXTENSIONS_INSTALL_SIGNER_H_ | 128 #endif // CHROME_BROWSER_EXTENSIONS_INSTALL_SIGNER_H_ |
OLD | NEW |