OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_WEBCRYPTO_NSS_KEY_NSS_H_ | 5 #ifndef COMPONENTS_WEBCRYPTO_NSS_KEY_NSS_H_ |
6 #define CONTENT_CHILD_WEBCRYPTO_NSS_KEY_NSS_H_ | 6 #define COMPONENTS_WEBCRYPTO_NSS_KEY_NSS_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
11 #include "crypto/scoped_nss_types.h" | 11 #include "crypto/scoped_nss_types.h" |
12 #include "third_party/WebKit/public/platform/WebCryptoKey.h" | 12 #include "third_party/WebKit/public/platform/WebCryptoKey.h" |
13 | 13 |
14 namespace content { | |
15 | |
16 namespace webcrypto { | 14 namespace webcrypto { |
17 | 15 |
18 class CryptoData; | 16 class CryptoData; |
19 class PrivateKeyNss; | 17 class PrivateKeyNss; |
20 class PublicKeyNss; | 18 class PublicKeyNss; |
21 class SymKeyNss; | 19 class SymKeyNss; |
22 | 20 |
23 // Base key class for all NSS keys, used to safely cast between types. Each key | 21 // Base key class for all NSS keys, used to safely cast between types. Each key |
24 // maintains a copy of its serialized form in either 'raw', 'pkcs8', or 'spki' | 22 // maintains a copy of its serialized form in either 'raw', 'pkcs8', or 'spki' |
25 // format. This is to allow structured cloning of keys synchronously from the | 23 // format. This is to allow structured cloning of keys synchronously from the |
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
97 } | 95 } |
98 | 96 |
99 private: | 97 private: |
100 crypto::ScopedSECKEYPrivateKey key_; | 98 crypto::ScopedSECKEYPrivateKey key_; |
101 | 99 |
102 DISALLOW_COPY_AND_ASSIGN(PrivateKeyNss); | 100 DISALLOW_COPY_AND_ASSIGN(PrivateKeyNss); |
103 }; | 101 }; |
104 | 102 |
105 } // namespace webcrypto | 103 } // namespace webcrypto |
106 | 104 |
107 } // namespace content | 105 #endif // COMPONENTS_WEBCRYPTO_NSS_KEY_NSS_H_ |
108 | |
109 #endif // CONTENT_CHILD_WEBCRYPTO_NSS_KEY_NSS_H_ | |
OLD | NEW |