ChiliProject is not maintained anymore. Please be advised that there will be no more updates.

We do not recommend that you setup new ChiliProject instances and we urge all existing users to migrate their data to a maintained system, e.g. Redmine. We will provide a migration script later. In the meantime, you can use the instructions by Christian Daehn.

receive_imap says SSLv3 read server certificate B: certificate verify failed

Added by Bodo Tasche at 2012-08-14 04:24 pm

Currently I am trying to add email receiving to our chili project installation with this command:

rake  redmine:email:receive_imap RAILS_ENV="production" host=XXX.XXX.XXX.XXX port=993 ssl=SSL username=USERNAME password=PASSWORD

but I only get this:

rake aborted!
SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed

How do I fix this certificate error?


Replies (5)

RE: receive_imap says SSLv3 read server certificate B: certificate verify failed - Added by Felix Schäfer at 2012-08-21 06:02 pm

Are you using a self-signed certificate on the host you're trying to connect to?

RE: receive_imap says SSLv3 read server certificate B: certificate verify failed - Added by Felix Schäfer at 2012-08-21 06:22 pm

OK, to see if ChiliProject of net/imap barfs on that, try something like:

require 'net/imap'

Net::IMAP.new(HOST, 993, true).login(USERNAME, PASSWORD)

(net/imap docs: http://ruby-doc.org/stdlib-1.8.7/libdoc/net/imap/rdoc/Net/IMAP.html)

RE: receive_imap says SSLv3 read server certificate B: certificate verify failed - Added by Bodo Tasche at 2012-08-22 08:49 am

Yes, it barfs:

OpenSSL::SSL::SSLError: SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed
from /home/idotv/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/net/imap.rb:1397:in `connect'
from /home/idotv/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/net/imap.rb:1397:in `start_tls_session'
from /home/idotv/.rvm/rubies/ruby-1.9.2-p180/lib/ruby/1.9.1/net/imap.rb:999:in `initialize'
from (irb):4:in `new'
from (irb):4
from /home/idotv/.rvm/rubies/ruby-1.9.2-p180/bin/irb:16:in `<main>'

How do I install that missing certificate?

RE: receive_imap says SSLv3 read server certificate B: certificate verify failed - Added by Felix Schäfer at 2012-08-22 10:04 am

As the stack uses OpenSSL, you basically have to install your certificate to somewhere where OpenSSL finds it, maybe see http://gagravarr.org/writing/openssl-certs/others.shtml ?

I just copied your error into google and there was a slew of responses there too, so you might find help there.

(1-5/5)