I’m having the same problem.
I noticed that you claimed this to be a bug and your post dates of 2005.
It is now 2008 and after much searching I still can’t see a solution to this problem.
I’m running the latest Virtualmin 3.53 GPL.
Here is the full error message:
Error
Failed to generate CSR : OpenSSL error creating private key :
Generating a 1024 bit RSA private key
…++++++
…++++++
writing new private key to ‘/tmp/.webmin/63464_2_csr.cgi’
You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter ‘.’, the field will be left blank.
Country Name (2 letter code) [GB]:State or Province Name (full name) [Berkshire]:Locality Name (eg, city) [Newbury]:Organization Name (eg, company) [My Company Ltd]:problems making Certificate Request
32084:error:0D07A097:asn1 encoding routines:ASN1_mbstring_ncopy:string too long:a_mbstr.c:154:maxsize=64
When I looked up the error number (0D07A097) on Google, I found a response from CAcert.org explaining that this is a simple problem, the COUNTRY code was either lesser or more than 2 digits. Such information has been provided correctly in the Virtualmin "create a virtual server" or "manage SSL cert". Meaning, all the information was provided to the script, and checked for misspelings or errors before pressing the "create" button.
If I do it outside of Virtualmin, inside a shell, using the openssl commands, I get it done, no problems.
It is therefore clear to me there is some problem or if you with, bug, with the Virtualmin GPL while handling SSL.
I’d be glad to cooperate and provide files, config files, outputs, in case you decide to provide a solution to the GPL community. I read that your commercial license product works fine. How about the GPL version ?
Thanks in advance for your time and any help provided in this matter.