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

Side by Side Diff: net/android/keystore_openssl.cc

Issue 506813002: Fix overzealous CHECK in custom EC_KEYs. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 3 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
« no previous file with comments | « no previous file | net/ssl/openssl_platform_key_mac.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 #include "net/android/keystore_openssl.h" 5 #include "net/android/keystore_openssl.h"
6 6
7 #include <jni.h> 7 #include <jni.h>
8 #include <openssl/bn.h> 8 #include <openssl/bn.h>
9 #include <openssl/dsa.h> 9 #include <openssl/dsa.h>
10 #include <openssl/ec.h> 10 #include <openssl/ec.h>
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
85 }; 85 };
86 86
87 // ExDataDup is called when one of the RSA, DSA or EC_KEY objects is 87 // ExDataDup is called when one of the RSA, DSA or EC_KEY objects is
88 // duplicated. We don't support this and it should never happen. 88 // duplicated. We don't support this and it should never happen.
89 int ExDataDup(CRYPTO_EX_DATA* to, 89 int ExDataDup(CRYPTO_EX_DATA* to,
90 const CRYPTO_EX_DATA* from, 90 const CRYPTO_EX_DATA* from,
91 void** from_d, 91 void** from_d,
92 int index, 92 int index,
93 long argl, 93 long argl,
94 void* argp) { 94 void* argp) {
95 CHECK(false); 95 CHECK_EQ((void*)NULL, *from_d);
96 return 0; 96 return 0;
97 } 97 }
98 98
99 // ExDataFree is called when one of the RSA, DSA or EC_KEY object is freed. 99 // ExDataFree is called when one of the RSA, DSA or EC_KEY object is freed.
100 void ExDataFree(void* parent, 100 void ExDataFree(void* parent,
101 void* ptr, 101 void* ptr,
102 CRYPTO_EX_DATA* ad, 102 CRYPTO_EX_DATA* ad,
103 int index, 103 int index,
104 long argl, 104 long argl,
105 void* argp) { 105 void* argp) {
(...skipping 479 matching lines...) Expand 10 before | Expand all | Expand 10 after
585 default: 585 default:
586 LOG(WARNING) 586 LOG(WARNING)
587 << "GetOpenSSLPrivateKeyWrapper() called with invalid key type"; 587 << "GetOpenSSLPrivateKeyWrapper() called with invalid key type";
588 return NULL; 588 return NULL;
589 } 589 }
590 return pkey.release(); 590 return pkey.release();
591 } 591 }
592 592
593 } // namespace android 593 } // namespace android
594 } // namespace net 594 } // namespace net
OLDNEW
« no previous file with comments | « no previous file | net/ssl/openssl_platform_key_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698