login about faq

I'm using the android IMAP and SMTP libraries, and if I set RequireSslCertVerify = true on either of them, it will always fail:

09-07 18:37:47.318: D/ReportEmails(17379): checkServerCert:
09-07 18:37:47.318: D/ReportEmails(17379): Verifying server certificate...
09-07 18:37:47.318: D/ReportEmails(17379): validateServerCerts:
09-07 18:37:47.318: D/ReportEmails(17379): certListSize: 3
09-07 18:37:47.318: D/ReportEmails(17379): issuerDN_notFound: US, Equifax, Equifax Secure Certificate Authority
09-07 18:37:47.318: D/ReportEmails(17379): Unable to build certificate chain to root..
09-07 18:37:47.318: D/ReportEmails(17379): --validateServerCerts
09-07 18:37:47.318: D/ReportEmails(17379): SSL server certificate verification failed.
09-07 18:37:47.318: D/ReportEmails(17379): --checkServerCert

I've tried with several servers (example above is Gmail's SMTP cert) and none work. Do the Android libraries have problems loading the CA cert store on the device?

asked Sep 07 '14 at 14:00

lmayne's gravatar image

lmayne
111


At the time of this post (9-Sep-2014) Chilkat does not have the ability to read Java keystores. Some possible workarounds are:

  1. Convert the Java keystore to a PEM file containing the certs and then use the Chilkat TrustedRoots class to explicitly trust the certs in the PEM file.
  2. or.. write Java code that opens the keystore, fetches each cert, and provides it to the Chilkat TrustedRoots object by calling AddCert for each.
link

answered Sep 09 '14 at 09:55

chilkat's gravatar image

chilkat ♦♦
11.8k316358421

Do you have a code sample I can implement against the current version to fix this, or does it require a rebuild of the libraries?

(Sep 13 '14 at 15:24) lmayne

I too ran into this issue. You'll need to do a bit of work to get the Android root system certs and load them into a CkTrustedRoots object. Here is my solution for loading up the system root certs

Chilkat HTTP for Android: Load System Root Certificates

link

answered Feb 25 at 10:50

Sean_McKeon's gravatar image

Sean_McKeon
112

edited Feb 25 at 10:52

Thanks Sean! I'll post this on the blog (cknotes.com) right now..

link

answered Feb 25 at 10:53

chilkat's gravatar image

chilkat ♦♦
11.8k316358421

PS> I'm also going to link from the online refdocs for Java..

link

answered Feb 25 at 10:54

chilkat's gravatar image

chilkat ♦♦
11.8k316358421

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or __italic__
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×175
×80
×56
×45
×3

Asked: Sep 07 '14 at 14:00

Seen: 1,206 times

Last updated: Feb 25 at 10:54

powered by OSQA