Submitted by dejongj on Fri, 01/27/2017 - 03:08
When creating a new virtual server and enabling SSL it fails with;
openssl failed asn1 encoding routines:ASN1_mbstring_ncopy:string too long:a_mbstr.c:158:maxsize=64
looking a bit further in this it seems to be because the DN name is too long; my domain is 16 characters or 20 with suffix. This then causes a recursive problem as I cannot generate my own certificate because without enabling SSL in the virtual server options I don't get the module in website options.
This is blocking me getting a new website live which is not good.
Status:
Active
Comments
Submitted by dejongj on Fri, 01/27/2017 - 03:10 Comment #1
Additional information;
Creating SSL certificate and private key ..
.. openssl failed! OpenSSL error creating private key :
Generating a 2048 bit RSA private key
....................................+++
......................+++
writing new private key to '/tmp/.webmin/381636_29428_7_domain_setup.cgi'
-----
problems making Certificate Request
140461058692768:error:0D07A097:asn1 encoding routines:ASN1_mbstring_ncopy:string too long:a_mbstr.c:158:maxsize=64
Adding new SSL virtual website ..
.. certificate file is not valid : Data does not start with line -----BEGIN CERTIFICATE-----
Submitted by dejongj on Fri, 01/27/2017 - 06:01 Comment #2
Interestingly I managed to get this to work by not changing the name of the first admin user when creating this. Most peculiar.
Submitted by JamieCameron on Fri, 01/27/2017 - 10:35 Comment #3
That's one I haven't seen before.
How long was the description / owner's name for this domain? It may be that was the trigger, not the domain name.
Submitted by 1baud on Mon, 11/20/2017 - 23:12 Comment #4
I'm getting the same error Ubuntu 14.04 LTS (Trusty Tahr) my domain name is not long: XXXXX.com :
Creating SSL certificate and private key .. .. openssl failed! OpenSSL error creating private key :
Generating a 2048 bit RSA private key ......................+++ .....................................................+++
writing new private key to '/tmp/.webmin/469303_24471_5_save_domain.cgi'
problems making Certificate Request 139805558028096:error:0D07A097:asn1 encoding routines:ASN1_mbstring_ncopy:string too long:../crypto/asn1/a_mbstr.c:109:maxsize=64
Adding new SSL virtual website .. .. certificate file is not valid : Data does not start with line -----BEGIN CERTIFICATE-----
Submitted by JamieCameron on Tue, 11/21/2017 - 03:20 Comment #5
1baud - How long is your domain name, and how long is the description for this domain?
Submitted by 1baud on Sat, 11/25/2017 - 23:17 Comment #6
The Domain name is 5 characters but you now have me wondering maybe it the description. It is a bit long. Let me change that
Submitted by JamieCameron on Sun, 11/26/2017 - 12:21 Comment #7
Yes, it could be the description - turns out there is a 64-character limit. I'll truncate long names to this when generating SSL certs in the next release.