Hi, all,
After a week's day and night debug, I find out the cause at last. It's
caused by a mis-decoding of parameters which is going to persistent into
database from utf-8.
I modified the OpenCA/DBI.pm of perl module.
from Line 3085:
# my @obind_values = @{$keys->{BIND_VALUES}} if ($keys->{BIND_VALUES});
my @bind_values;
foreach my $help ( @{$keys->{BIND_VALUES}}){
# if the bind value is still in utf-8 , I decode it here. :)
if(Encode::is_utf8($help)){
$help=Encode::decode_utf8($help);
Encode::_utf8_off($help);
}
$bind_values[ scalar( @bind_values)]=$help;
}
$self->debug ("doQuery: query: $query");
wking wrote:
>
> Hi, all,
>
> I'm using simplified Chinese as my mother language. There is two
> problems hen I use a Chinese words as Subject Name.
>
> 1. I submitted a CSR, the Chinese words become some strange words with
> no meanings when I check it in RA. I've changed the Mysql's client and
> server's default character to utf-8.
>
> 2.I can edit the CSR, and repair the Chinese words to correct ones. but
> when I issue the request in CA. A Error ocurred as bellow:
> Error while issuing Certificate to 刘百祥 (filename:
> /usr/local/var/openca/tmp/0D.req).
> OpenCA::OpenSSL returns errocode 7731075 (OpenCA::OpenSSL->issueCert:
> OpenSSL fails (7777067). Using configuration from
> /usr/local/etc/openca/openssl/openssl/User.conf
> Check that the SPKAC request matches the signature
> Signature ok
> ERROR: adding extensions in section default
> 3181:error:0D06407A:asn1 encoding routines:a2d_ASN1_OBJECT:first num too
> large:a_object.c:108:
> 3181:error:0D064083:asn1 encoding routines:a2d_ASN1_OBJECT:invalid
> separator:a_object.c:124:
> 3181:error:22075077:X509 V3 routines:v2i_GENERAL_NAME_ex:bad
> object:v3_alt.c:468:value=04577
> 3181:error:22098080:X509 V3 routines:X509V3_EXT_nconf:error in
> extension:v3_conf.c:93:name=subjectAltName, [EMAIL PROTECTED]
> error in ca
> ).
>
> Who will give me some suggestion except not using Chinese ?
>
> p.s. The CRR is like this:
> Variable Value
> Request Version 1
> Serial Number 3104
> Common Name 刘百祥
> E-Mail [EMAIL PROTECTED]
> Subject Alternative Name [EMAIL PROTECTED]
> otherName.1=1.3.6.1.4.1.311.25.1;UTF8:04828 RID.2=04577
> Role User
> Lifetime (days) n/a
> Not before (YYMMDDhhmmss) n/a
> Not after (YYMMDDhhmmss) n/a
> Lifetime check Lifetime would be ok.
> LOA High
> Distinguished Name serialNumber=206,CN=刘百祥, OU=Users, O=Fudan, C=CN
> Submitted on Thu Nov 27 10:55:14 2008 UTC
>
>
--
View this message in context:
http://www.nabble.com/Problems-about-multi-bytes-language-contents-tp20717745p20832193.html
Sent from the openca-users mailing list archive at Nabble.com.
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Openca-Users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openca-users