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

Side by Side Diff: net/cert/x509_util_openssl.cc

Issue 17265013: Remove platform-specific implementations of RSAPrivateKey and SignatureCreator (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix colliding serial numbers Created 7 years, 5 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 | « net/cert/x509_util_nss.cc ('k') | net/cert/x509_util_unittest.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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/cert/x509_util.h" 5 #include "net/cert/x509_util.h"
6 #include "net/cert/x509_util_openssl.h" 6 #include "net/cert/x509_util_openssl.h"
7 7
8 #include <algorithm> 8 #include <algorithm>
9 9
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 crypto::ECPrivateKey* key, 52 crypto::ECPrivateKey* key,
53 const std::string& domain, 53 const std::string& domain,
54 uint32 serial_number, 54 uint32 serial_number,
55 base::Time not_valid_before, 55 base::Time not_valid_before,
56 base::Time not_valid_after, 56 base::Time not_valid_after,
57 std::string* der_cert) { 57 std::string* der_cert) {
58 NOTIMPLEMENTED(); 58 NOTIMPLEMENTED();
59 return false; 59 return false;
60 } 60 }
61 61
62 bool CreateSelfSignedCert(crypto::RSAPrivateKey* key,
63 const std::string& common_name,
64 uint32 serial_number,
65 base::Time not_valid_before,
66 base::Time not_valid_after,
67 std::string* der_encoded) {
68 NOTIMPLEMENTED();
69 return false;
70 }
71
62 bool ParsePrincipalKeyAndValueByIndex(X509_NAME* name, 72 bool ParsePrincipalKeyAndValueByIndex(X509_NAME* name,
63 int index, 73 int index,
64 std::string* key, 74 std::string* key,
65 std::string* value) { 75 std::string* value) {
66 X509_NAME_ENTRY* entry = X509_NAME_get_entry(name, index); 76 X509_NAME_ENTRY* entry = X509_NAME_get_entry(name, index);
67 if (!entry) 77 if (!entry)
68 return false; 78 return false;
69 79
70 if (key) { 80 if (key) {
71 ASN1_OBJECT* object = X509_NAME_ENTRY_get_object(entry); 81 ASN1_OBJECT* object = X509_NAME_ENTRY_get_object(entry);
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 x509_time->length); 120 x509_time->length);
111 121
112 CertDateFormat format = x509_time->type == V_ASN1_UTCTIME ? 122 CertDateFormat format = x509_time->type == V_ASN1_UTCTIME ?
113 CERT_DATE_FORMAT_UTC_TIME : CERT_DATE_FORMAT_GENERALIZED_TIME; 123 CERT_DATE_FORMAT_UTC_TIME : CERT_DATE_FORMAT_GENERALIZED_TIME;
114 return ParseCertificateDate(str_date, format, time); 124 return ParseCertificateDate(str_date, format, time);
115 } 125 }
116 126
117 } // namespace x509_util 127 } // namespace x509_util
118 128
119 } // namespace net 129 } // namespace net
OLDNEW
« no previous file with comments | « net/cert/x509_util_nss.cc ('k') | net/cert/x509_util_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698