VNC console certificate does not match

"Error: Could not parse certificate: java.io.IOExceptionL Illegal header: -----BEGIN CERTIFICATE-----"
Seems you have a space char just before
-----BEGIN CERTIFICATE-----. Open the certificate with nano and verify this is not the case.
 
"Error: Could not parse certificate: java.io.IOExceptionL Illegal header: -----BEGIN CERTIFICATE-----"
Seems you have a space char just before
-----BEGIN CERTIFICATE-----. Open the certificate with nano and verify this is not the case.

Thank you very much! It works. Thank you for the quick reply.

I pasted the keys over ssh with putty which includes a space at the end of each line. The browser must ignore the spaces when it checks the certificates, but the vnc viewer must not have the same correction mechanism.

Thanks again :).