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

Side by Side Diff: content/child/webcrypto/shared_crypto.h

Issue 197223007: [webcrypto] Remove support for null import algorithms. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 6 years, 9 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 | Annotate | Revision Log
OLDNEW
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_SHARED_CRYPTO_H_ 5 #ifndef CONTENT_CHILD_WEBCRYPTO_SHARED_CRYPTO_H_
6 #define CONTENT_CHILD_WEBCRYPTO_SHARED_CRYPTO_H_ 6 #define CONTENT_CHILD_WEBCRYPTO_SHARED_CRYPTO_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "content/common/content_export.h" 10 #include "content/common/content_export.h"
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
93 blink::WebCryptoKeyUsageMask usage_mask, 93 blink::WebCryptoKeyUsageMask usage_mask,
94 blink::WebCryptoKey* key); 94 blink::WebCryptoKey* key);
95 95
96 CONTENT_EXPORT Status 96 CONTENT_EXPORT Status
97 GenerateKeyPair(const blink::WebCryptoAlgorithm& algorithm, 97 GenerateKeyPair(const blink::WebCryptoAlgorithm& algorithm,
98 bool extractable, 98 bool extractable,
99 blink::WebCryptoKeyUsageMask usage_mask, 99 blink::WebCryptoKeyUsageMask usage_mask,
100 blink::WebCryptoKey* public_key, 100 blink::WebCryptoKey* public_key,
101 blink::WebCryptoKey* private_key); 101 blink::WebCryptoKey* private_key);
102 102
103 CONTENT_EXPORT Status 103 CONTENT_EXPORT Status ImportKey(blink::WebCryptoKeyFormat format,
104 ImportKey(blink::WebCryptoKeyFormat format, 104 const CryptoData& key_data,
105 const CryptoData& key_data, 105 const blink::WebCryptoAlgorithm& algorithm,
106 const blink::WebCryptoAlgorithm& algorithm_or_null, 106 bool extractable,
107 bool extractable, 107 blink::WebCryptoKeyUsageMask usage_mask,
108 blink::WebCryptoKeyUsageMask usage_mask, 108 blink::WebCryptoKey* key);
109 blink::WebCryptoKey* key);
110 109
111 CONTENT_EXPORT Status ExportKey(blink::WebCryptoKeyFormat format, 110 CONTENT_EXPORT Status ExportKey(blink::WebCryptoKeyFormat format,
112 const blink::WebCryptoKey& key, 111 const blink::WebCryptoKey& key,
113 blink::WebArrayBuffer* buffer); 112 blink::WebArrayBuffer* buffer);
114 113
115 CONTENT_EXPORT Status Sign(const blink::WebCryptoAlgorithm& algorithm, 114 CONTENT_EXPORT Status Sign(const blink::WebCryptoAlgorithm& algorithm,
116 const blink::WebCryptoKey& key, 115 const blink::WebCryptoKey& key,
117 const CryptoData& data, 116 const CryptoData& data,
118 blink::WebArrayBuffer* buffer); 117 blink::WebArrayBuffer* buffer);
119 118
120 CONTENT_EXPORT Status 119 CONTENT_EXPORT Status
121 VerifySignature(const blink::WebCryptoAlgorithm& algorithm, 120 VerifySignature(const blink::WebCryptoAlgorithm& algorithm,
122 const blink::WebCryptoKey& key, 121 const blink::WebCryptoKey& key,
123 const CryptoData& signature, 122 const CryptoData& signature,
124 const CryptoData& data, 123 const CryptoData& data,
125 bool* signature_match); 124 bool* signature_match);
126 125
127 CONTENT_EXPORT Status 126 CONTENT_EXPORT Status ImportKeyJwk(const CryptoData& key_data,
128 ImportKeyJwk(const CryptoData& key_data, 127 const blink::WebCryptoAlgorithm& algorithm,
129 const blink::WebCryptoAlgorithm& algorithm_or_null, 128 bool extractable,
130 bool extractable, 129 blink::WebCryptoKeyUsageMask usage_mask,
131 blink::WebCryptoKeyUsageMask usage_mask, 130 blink::WebCryptoKey* key);
132 blink::WebCryptoKey* key);
133 131
134 CONTENT_EXPORT Status 132 CONTENT_EXPORT Status
135 ExportKeyJwk(const blink::WebCryptoKey& key, blink::WebArrayBuffer* buffer); 133 ExportKeyJwk(const blink::WebCryptoKey& key, blink::WebArrayBuffer* buffer);
136 134
137 CONTENT_EXPORT Status 135 CONTENT_EXPORT Status
138 WrapKey(blink::WebCryptoKeyFormat format, 136 WrapKey(blink::WebCryptoKeyFormat format,
139 const blink::WebCryptoKey& wrapping_key, 137 const blink::WebCryptoKey& wrapping_key,
140 const blink::WebCryptoKey& key_to_wrap, 138 const blink::WebCryptoKey& key_to_wrap,
141 const blink::WebCryptoAlgorithm& wrapping_algorithm, 139 const blink::WebCryptoAlgorithm& wrapping_algorithm,
142 blink::WebArrayBuffer* buffer); 140 blink::WebArrayBuffer* buffer);
143 141
144 CONTENT_EXPORT Status 142 CONTENT_EXPORT Status
145 UnwrapKey(blink::WebCryptoKeyFormat format, 143 UnwrapKey(blink::WebCryptoKeyFormat format,
146 const CryptoData& wrapped_key_data, 144 const CryptoData& wrapped_key_data,
147 const blink::WebCryptoKey& wrapping_key, 145 const blink::WebCryptoKey& wrapping_key,
148 const blink::WebCryptoAlgorithm& wrapping_algorithm, 146 const blink::WebCryptoAlgorithm& wrapping_algorithm,
149 const blink::WebCryptoAlgorithm& algorithm_or_null, 147 const blink::WebCryptoAlgorithm& algorithm,
150 bool extractable, 148 bool extractable,
151 blink::WebCryptoKeyUsageMask usage_mask, 149 blink::WebCryptoKeyUsageMask usage_mask,
152 blink::WebCryptoKey* key); 150 blink::WebCryptoKey* key);
153 151
154 CONTENT_EXPORT Status 152 CONTENT_EXPORT Status
155 SerializeKeyForClone(const blink::WebCryptoKey& key, 153 SerializeKeyForClone(const blink::WebCryptoKey& key,
156 blink::WebVector<unsigned char>* data); 154 blink::WebVector<unsigned char>* data);
157 155
158 CONTENT_EXPORT Status 156 CONTENT_EXPORT Status
159 DeserializeKeyForClone(const blink::WebCryptoKeyAlgorithm& algorithm, 157 DeserializeKeyForClone(const blink::WebCryptoKeyAlgorithm& algorithm,
160 blink::WebCryptoKeyType type, 158 blink::WebCryptoKeyType type,
161 bool extractable, 159 bool extractable,
162 blink::WebCryptoKeyUsageMask usage_mask, 160 blink::WebCryptoKeyUsageMask usage_mask,
163 const CryptoData& key_data, 161 const CryptoData& key_data,
164 blink::WebCryptoKey* key); 162 blink::WebCryptoKey* key);
165 163
166 } // namespace webcrypto 164 } // namespace webcrypto
167 165
168 } // namespace content 166 } // namespace content
169 167
170 #endif // CONTENT_CHILD_WEBCRYPTO_SHARED_CRYPTO_H_ 168 #endif // CONTENT_CHILD_WEBCRYPTO_SHARED_CRYPTO_H_
OLDNEW
« no previous file with comments | « content/child/webcrypto/platform_crypto_openssl.cc ('k') | content/child/webcrypto/shared_crypto.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698