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 #include <openssl/ec.h> | |
6 #include <openssl/ecdh.h> | |
7 #include <openssl/evp.h> | |
8 #include <stddef.h> | 5 #include <stddef.h> |
9 #include <stdint.h> | 6 #include <stdint.h> |
10 | 7 |
11 #include "base/logging.h" | 8 #include "base/logging.h" |
12 #include "base/memory/ptr_util.h" | 9 #include "base/memory/ptr_util.h" |
13 #include "components/webcrypto/algorithm_implementation.h" | 10 #include "components/webcrypto/algorithm_implementation.h" |
14 #include "components/webcrypto/algorithms/ec.h" | 11 #include "components/webcrypto/algorithms/ec.h" |
15 #include "components/webcrypto/algorithms/util.h" | 12 #include "components/webcrypto/algorithms/util.h" |
16 #include "components/webcrypto/blink_key_handle.h" | 13 #include "components/webcrypto/blink_key_handle.h" |
17 #include "components/webcrypto/crypto_data.h" | 14 #include "components/webcrypto/crypto_data.h" |
18 #include "components/webcrypto/generate_key_result.h" | 15 #include "components/webcrypto/generate_key_result.h" |
19 #include "components/webcrypto/status.h" | 16 #include "components/webcrypto/status.h" |
20 #include "crypto/openssl_util.h" | 17 #include "crypto/openssl_util.h" |
21 #include "crypto/secure_util.h" | 18 #include "crypto/secure_util.h" |
22 #include "third_party/WebKit/public/platform/WebCryptoAlgorithmParams.h" | 19 #include "third_party/WebKit/public/platform/WebCryptoAlgorithmParams.h" |
23 #include "third_party/WebKit/public/platform/WebCryptoKey.h" | 20 #include "third_party/WebKit/public/platform/WebCryptoKey.h" |
24 #include "third_party/WebKit/public/platform/WebCryptoKeyAlgorithm.h" | 21 #include "third_party/WebKit/public/platform/WebCryptoKeyAlgorithm.h" |
| 22 #include "third_party/boringssl/src/include/openssl/ec.h" |
| 23 #include "third_party/boringssl/src/include/openssl/ecdh.h" |
| 24 #include "third_party/boringssl/src/include/openssl/evp.h" |
25 | 25 |
26 namespace webcrypto { | 26 namespace webcrypto { |
27 | 27 |
28 namespace { | 28 namespace { |
29 | 29 |
30 // TODO(eroman): Support the "raw" format for ECDH key import + export, as | 30 // TODO(eroman): Support the "raw" format for ECDH key import + export, as |
31 // specified by WebCrypto spec. | 31 // specified by WebCrypto spec. |
32 | 32 |
33 // TODO(eroman): Allow id-ecDH in SPKI and PKCS#8 import | 33 // TODO(eroman): Allow id-ecDH in SPKI and PKCS#8 import |
34 // (http://crbug.com/389400) | 34 // (http://crbug.com/389400) |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 } | 120 } |
121 }; | 121 }; |
122 | 122 |
123 } // namespace | 123 } // namespace |
124 | 124 |
125 std::unique_ptr<AlgorithmImplementation> CreateEcdhImplementation() { | 125 std::unique_ptr<AlgorithmImplementation> CreateEcdhImplementation() { |
126 return base::WrapUnique(new EcdhImplementation); | 126 return base::WrapUnique(new EcdhImplementation); |
127 } | 127 } |
128 | 128 |
129 } // namespace webcrypto | 129 } // namespace webcrypto |
OLD | NEW |