roger's picture

GNU TLS reports "Base64 Decoding Error"

I recently had a problem getting STARTTLS working on exim4 on Debian 4.0 (Etch). It kept reporting:

TLS error on connection from host (ehlo) [ip]
(cert/key setup: cert=/etc/ssl/certs/whatever.crt key=/etc/ssl/private/whatever.key:
Base64 decoding error.

This was confirmed by running gnutls-serv --debug 5 --x509certfile foo.crt --x509keyfile foo.key, which reported the same error.

Turns out that what it actually means is not "Base64 decoding error". What it actually means is "You didn't remove the pass phrase from the key".

To do that:

$ cp foo.key foo.key.orig
$ openssl rsa -in foo.key.orig --out foo.key

Reply

The content of this field is kept private and will not be shown publicly.
  • Allowed HTML tags: <a> <b> <br> <code> <dd> <dl> <dt> <hr> <h1> <h2> <h3> <i> <img> <li> <ol> <p> <pre> <table> <td> <th> <tr> <tt> <u> <ul>
  • Images can be added to this post.

More information about formatting options