summaryrefslogtreecommitdiffstats
path: root/net/base/x509_certificate.h
Commit message (Collapse)AuthorAgeFilesLines
* More FRIEND_TEST_ALL_PREFIXES.phajdan.jr@chromium.org2010-07-301-3/+3
| | | | | | | | | TEST=none BUG=44549 Review URL: http://codereview.chromium.org/3053024 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@54388 0039d316-1c4b-4281-b951-d872f2087c98
* `#pragma once` for app, base, chrome, gfx, ipc, net, skia, viewsthakis@chromium.org2010-07-261-0/+1
| | | | | | | | | BUG=50273 TEST=everything still builds, build is 10% faster on windows, same speed on mac/linux TBR: erg git-svn-id: svn://svn.chromium.org/chrome/trunk/src@53716 0039d316-1c4b-4281-b951-d872f2087c98
* Add support for parsing certificate formats other than raw, DER-encoded ↵rsleevi@chromium.org2010-07-221-1/+38
| | | | | | | | | | | | | | certificates - specifically formats that represent collections of certificates. The certificate format can now be specified as an explicit format, or as a bit-mask of formats that are acceptable/expected, with the first parsable format winning. This is one half of a commit to address BUG #37142, with the second half involving connecting this through the X509UserCertHandler and the actual UI. R=wtc BUG=37142 TEST=X509CertificateParseTest* and PEMTokenizerTest.* Review URL: http://codereview.chromium.org/2819018 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@53298 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 52799 - Add support for parsing certificate formats other than raw, ↵rsleevi@chromium.org2010-07-171-37/+1
| | | | | | | | | | | | | | | | | DER-encoded certificates - specifically formats that represent collections of certificates. The certificate format can now be specified as an explicit format, or as a bit-mask of formats that are acceptable/expected, with the first parsable format winning. This is one half of a commit to address BUG #37142, with the second half involving connecting this through the X509UserCertHandler and the actual UI. R=wtc BUG=37142 TEST=X509CertificateParseTest* and PEMTokenizerTest.* Review URL: http://codereview.chromium.org/2819018 TBR=rsleevi@chromium.org Review URL: http://codereview.chromium.org/2812064 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@52801 0039d316-1c4b-4281-b951-d872f2087c98
* Add support for parsing certificate formats other than raw, DER-encoded ↵rsleevi@chromium.org2010-07-171-1/+37
| | | | | | | | | | | | | | certificates - specifically formats that represent collections of certificates. The certificate format can now be specified as an explicit format, or as a bit-mask of formats that are acceptable/expected, with the first parsable format winning. This is one half of a commit to address BUG #37142, with the second half involving connecting this through the X509UserCertHandler and the actual UI. R=wtc BUG=37142 TEST=X509CertificateParseTest* and PEMTokenizerTest.* Review URL: http://codereview.chromium.org/2819018 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@52799 0039d316-1c4b-4281-b951-d872f2087c98
* Minor clean-up tasks that were TODO(snej)rsleevi@chromium.org2010-07-171-42/+8
| | | | | | | | | | | | | | Rename Principal->CertPrincipal, Policy->CertPolicy, both of which are merely syntatic fluff. Rename Fingerprint->SHA1Fingerprint, which is more important since those using the fingerprint, such as the unit tests, were truly hardcoded against SHA-1 fingerprints, and if the fingerprint ever changed, wouldn't cause errors until run time. R=wtc BUG=None TEST=Compilers stay green Review URL: http://codereview.chromium.org/2815048 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@52789 0039d316-1c4b-4281-b951-d872f2087c98
* Make X509Certificate::CreateFromHandle() copy the OSCertHandle, rather than ↵rsleevi@chromium.org2010-06-261-7/+5
| | | | | | | | | | | | assume ownership R=wtc BUG=47463 TEST=none Review URL: http://codereview.chromium.org/2867026 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@50938 0039d316-1c4b-4281-b951-d872f2087c98
* Use SSLClientSocketNSS on Mac OS X. By default, chrome still useswtc@chromium.org2010-06-011-11/+10
| | | | | | | | | | | | | | | | | | SSLClientSocketMac. Specify the --use-nss-for-ssl command-line option to use SSLClientSocketNSS. The nss.gyp in src/net/third_party/nss is renamed ssl.gyp to avoid a naming conflict with the nss.gyp in src/third_party/nss. The GYP generator for Xcode project files disallows same-named .gyp files. SSL client authentication doesn't work yet. R=mark BUG=30689 TEST=No build and test failures on Mac and Windows. Review URL: http://codereview.chromium.org/2322008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@48650 0039d316-1c4b-4281-b951-d872f2087c98
* [Mac] Add locking as speculative fix for X509Certificate crashes.snej@chromium.org2010-04-271-0/+6
| | | | | | | | | BUG=30001 TEST=none Review URL: http://codereview.chromium.org/1769010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@45728 0039d316-1c4b-4281-b951-d872f2087c98
* Mac: Make client-cert picker only show certs the server will accept.snej@chromium.org2010-03-261-77/+19
| | | | | | | | | | | BUG=38691 TEST=manual testing with various sites Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=42822 Review URL: http://codereview.chromium.org/1128008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42859 0039d316-1c4b-4281-b951-d872f2087c98
* Revert due to compile failuresamit@chromium.org2010-03-261-19/+77
| | | | | | | | | | | | | Revert 42822 - Mac: Make clientcert picker only show certs the server will accept. BUG=38691 TEST=manual testing with various sites Review URL: http://codereview.chromium.org/1128008 TBR=snej@chromium.org Review URL: http://codereview.chromium.org/1417003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42830 0039d316-1c4b-4281-b951-d872f2087c98
* Mac: Make client-cert picker only show certs the server will accept.snej@chromium.org2010-03-261-77/+19
| | | | | | | | | BUG=38691 TEST=manual testing with various sites Review URL: http://codereview.chromium.org/1128008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42822 0039d316-1c4b-4281-b951-d872f2087c98
* Thread-safety for X509Certificate's intermediate-certs list.snej@chromium.org2010-03-051-13/+25
| | | | | | | | | BUG=32553,30001 TEST=none Review URL: http://codereview.chromium.org/661223 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@40797 0039d316-1c4b-4281-b951-d872f2087c98
* Revert my last commit 'cause it breaks net unit tests on OS X 10.6 :(snej@chromium.org2010-03-051-25/+13
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@40743 0039d316-1c4b-4281-b951-d872f2087c98
* Thread-safety for X509Certificate's intermediate-certs list.snej@chromium.org2010-03-051-13/+25
| | | | | | | | | BUG=32553,30001 TEST=none Review URL: http://codereview.chromium.org/661223 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@40742 0039d316-1c4b-4281-b951-d872f2087c98
* Mac client-side SSL cert improvements.snej@chromium.org2010-02-241-1/+8
| | | | | | | | | | | Allow Netscape-style client certs. Remember which identity the user chooses for a domain, and put it at the top of the list next time. BUG=36316,36446 TEST=none Review URL: http://codereview.chromium.org/651090 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@39904 0039d316-1c4b-4281-b951-d872f2087c98
* Client-side SSL cert support for Mac.snej@chromium.org2010-02-181-0/+12
| | | | | | | | | | This includes sending an existing identity cert, and asking the user which cert to use. Doesn't yet handle SSL renegotiation, or key-gen. BUG=16831 TEST=none Review URL: http://codereview.chromium.org/604067 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@39389 0039d316-1c4b-4281-b951-d872f2087c98
* BSD port: USE_NSS and other macros instead of OS_LINUX where applicablepvalchev@google.com2010-01-291-2/+2
| | | | | | Review URL: http://codereview.chromium.org/556068 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@37492 0039d316-1c4b-4281-b951-d872f2087c98
* Define X509Certificate::intermediate_ca_certs_ as a std::vector ofwtc@chromium.org2009-12-091-13/+17
| | | | | | | | | | | | | | | | OSCertHandle so that we can also use it on Windows. Remove the unused SSLClientSocketMac::intermediate_certs_ member. R=hawk BUG=28744 TEST=Can visit good HTTPS sites with no certificate errors. Clicking the "Certificate information" button in the page security information window should show a complete certificate chain (as opposed to just the server certificate). Review URL: http://codereview.chromium.org/452042 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34175 0039d316-1c4b-4281-b951-d872f2087c98
* View Certificate dialog sometimes shows incorrect status because it didn't ↵hawk@chromium.org2009-10-131-0/+5
| | | | | | | | | | have the full certificate chain. BUG=23122 TEST=https://www.paypal.com should have "This certificate is valid" in View Page Info->View Certificate Information Review URL: http://codereview.chromium.org/256064 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@28882 0039d316-1c4b-4281-b951-d872f2087c98
* Enable SSLClientSocketTest unit tests on Mac OS X by implementing our own ↵hawk@chromium.org2009-08-271-0/+12
| | | | | | | | | | certificate validation code. This gives us proper hostname matching, multiple error codes (e.g., before a certificate could be marked as expired or untrusted, but not both), revocation checking, and EV certificate checking. BUG=19286,10910,14733 TEST=https://www.paypal.com should work without warning. https://paypal.com should get a warning about a hostname mismatch. https://test-ssev.verisign.com:1443/test-SSEV-expired-verisign.html should give a warning about an expired certificate. Review URL: http://codereview.chromium.org/174102 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24625 0039d316-1c4b-4281-b951-d872f2087c98
* Fix few trivial Coverity issues, mainly PASS_BY_VALUE.phajdan.jr@chromium.org2009-07-061-1/+1
| | | | | | Review URL: http://codereview.chromium.org/155022 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19974 0039d316-1c4b-4281-b951-d872f2087c98
* Following the style guide, replace the overloaded operator==wtc@chromium.org2009-06-231-1/+1
| | | | | | | | | | | with the Equals method. R=eroman BUG=http://crbug.com/318 TEST=none Review URL: http://codereview.chromium.org/146040 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19056 0039d316-1c4b-4281-b951-d872f2087c98
* Define the == operator for X509Certificate::Fingerprint.wtc@chromium.org2009-06-231-0/+6
| | | | | | | | | R=eroman BUG=http://crbug.com/318 TEST=none Review URL: http://codereview.chromium.org/140034 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19029 0039d316-1c4b-4281-b951-d872f2087c98
* Use LOAD_VERIFY_EV_CERT to verify EV-ness in Verify().ukai@chromium.org2009-06-231-7/+12
| | | | | | | | | | | | | | | | | If LOAD_VERIFY_EV_CERT is requested on load_flags and revokation checking is performed, Verify() peforms EV certificate verification as well, and sets CERT_STATUS_IS_EV in verify_result. Eliminate X509Certificate::IsEV() BUG=3592 TEST=net_unittests with ALLOW_EXTERNAL_ACCESS=1, \ visit https://www.thawte.com/ and shows EV info. Review URL: http://codereview.chromium.org/125120 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19011 0039d316-1c4b-4281-b951-d872f2087c98
* SSL Fix: Step 2.Add HasAllowedCert and HasDeniedCert to ↵abarth@chromium.org2009-03-171-0/+6
| | | | | | | | X509Certificate::Policy.R=wtcBUG=8706 Review URL: http://codereview.chromium.org/42255 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@11839 0039d316-1c4b-4281-b951-d872f2087c98
* NO CODE CHANGEdeanm@chromium.org2009-03-111-1/+0
| | | | | | | | | Normalize end of file newlines in net/. All files end in a single newline. Review URL: http://codereview.chromium.org/43079 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@11442 0039d316-1c4b-4281-b951-d872f2087c98
* Add X509Certificate::Verify stubs for Mac and Linux.wtc@chromium.org2009-02-051-0/+6
| | | | | | | | | | | | | | | | | They do nothing but return ERR_NOT_IMPLEMENTED. In SSLClientSocketWin, call X509Certificate::CreateFromHandle only once and store the result in the server_cert_ member. Add the CertVerifyResult::Reset method to clear all members. R=eroman BUG=3592 Review URL: http://codereview.chromium.org/21071 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9272 0039d316-1c4b-4281-b951-d872f2087c98
* Move certificate verification off the IO thread.wtc@chromium.org2009-02-031-6/+26
| | | | | | | | | | | | | | | | Move the MapNetErrorToCertStatus and MapCertStatusToNetError functions to cert_status_flags.h so they can be shared with Mac and Linux code. Move the certificate verification function to the X509Certificate class. Right now X509Certificate::Verify is only implemented on Windows. R=eroman BUG=3592 Review URL: http://codereview.chromium.org/14915 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@9084 0039d316-1c4b-4281-b951-d872f2087c98
* Reverting 8868.ericroman@google.com2009-01-291-4/+37
| | | | | | | This relands wtc's original CL for working around not caching the intermediate CA certificates. We believe the original commit failed on buildbot because of a bad incremental build, and will be resolved by doing a clobber Review URL: http://codereview.chromium.org/19463 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@8870 0039d316-1c4b-4281-b951-d872f2087c98
* Reverting 8864.wtc@chromium.org2009-01-291-37/+4
| | | | | | | Revert r8864. It broke the build url_request_intercept_job.cc. Review URL: http://codereview.chromium.org/19462 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@8868 0039d316-1c4b-4281-b951-d872f2087c98
* Work around our not caching the intermediate CAwtc@chromium.org2009-01-291-4/+37
| | | | | | | | | | | | | | | | | | | | | | certificates by passing the source of each OSCertHandle to CreateFromHandle and the X509Certificate constructor. If the OSCertHandle comes from the network layer, we know it has a complete certificate chain and therefore prefer it to an OSCertHandle that comes from the HTTP cache, which doesn't have the intermediate CA certificates. A certificate from the network layer can kick out a certificate from the HTTP cache in our certificate cache. This workaround seems good enough to fix all the known symptoms of not caching the intermediate CA certificates. Move the common code in x509_certificate_<os>.cc to x509_certificate.cc. R=eroman BUG=3154,7065 Review URL: http://codereview.chromium.org/18836 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@8864 0039d316-1c4b-4281-b951-d872f2087c98
* Implement part of x509_certificate on linux, enable its unit test.dkegel@google.com2008-12-221-0/+5
| | | | | | Review URL: http://codereview.chromium.org/16205 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@7350 0039d316-1c4b-4281-b951-d872f2087c98
* Move Time, TimeDelta and TimeTicks into namespace base.dsh@google.com2008-10-271-5/+5
| | | | | | Review URL: http://codereview.chromium.org/7995 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@4022 0039d316-1c4b-4281-b951-d872f2087c98
* Refactoring out common code in the X.509 cert handlingavi@google.com2008-09-231-8/+26
| | | | | | Review URL: http://codereview.chromium.org/4040 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2525 0039d316-1c4b-4281-b951-d872f2087c98
* Unit test now runs on the Mac.avi@google.com2008-09-221-11/+0
| | | | | | Review URL: http://codereview.chromium.org/3000 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2440 0039d316-1c4b-4281-b951-d872f2087c98
* Accidental commit; oopsavi@google.com2008-09-191-0/+11
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2423 0039d316-1c4b-4281-b951-d872f2087c98
* Unit test now runs on the Mac.avi@google.com2008-09-191-11/+0
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2421 0039d316-1c4b-4281-b951-d872f2087c98
* Add a byte factory method for unit testing.avi@google.com2008-09-191-0/+4
| | | | | | Review URL: http://codereview.chromium.org/2975 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2403 0039d316-1c4b-4281-b951-d872f2087c98
* Bring X.509 cert handling (at least preliminarily) to the Mac.avi@google.com2008-09-181-2/+21
| | | | | | Review URL: http://codereview.chromium.org/2963 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2369 0039d316-1c4b-4281-b951-d872f2087c98
* Use a more compact license header in source files.license.bot2008-08-241-28/+4
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1287 0039d316-1c4b-4281-b951-d872f2087c98
* add http_cache to mac build.ericroman@google.com2008-08-191-5/+12
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1068 0039d316-1c4b-4281-b951-d872f2087c98
* Move more net classes into the net namespace. Also remove the net_util ↵darin@google.com2008-07-311-3/+7
| | | | | | | | namespace in favor of the net namespace. This is a purely mechanical change. There should be no logic changes. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@192 0039d316-1c4b-4281-b951-d872f2087c98
* Add net to the repository.initial.commit2008-07-261-0/+213
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@14 0039d316-1c4b-4281-b951-d872f2087c98