Skip to Content.
Sympa Menu

cacert-devel - Re: CAcert database character sets

Subject: CAcert Code Development list.

List archive

Re: CAcert database character sets


Chronological Thread 
  • From: Benny Baumann <benbe AT cacert.org>
  • To: Wytze van der Raay <wytze AT cacert.org>, Michael Tänzer <michael.taenzer AT cacert.org>
  • Cc: Developers CAcert <cacert-devel AT lists.cacert.org>, "critical-admin AT cacert.org" <critical-admin AT cacert.org>
  • Subject: Re: CAcert database character sets
  • Date: Wed, 23 Jul 2014 19:07:55 +0200

Hi Wytze,

Am 23.07.2014 11:32, schrieb Wytze van der Raay:
> Hi Benny, Michael,
>
> I seem to remember that there were some questions about possible corruption
> of
> data in the database when using non-ascii characters. You'll probably
> remember
> better than me.
>
> Anyway, while upgrading our database, I hit upon a "db.opt" file in the
> /var/lib/mysql/cacert directory, with the following contents:
>
> default-character-set=latin1
> default-collation=latin1_swedish_ci
>
> As I understand it, this file has been created once (Dec 17 2006) on
> creation of said database. I am a bit surprised to see latin1 here
> rather than utf8. Is this correct? Should it be different?
This file contains the defaults of MySQL. As MySQL originated in Sweden
the developer of it had the glorious idea to use swedish for it.
Unfortunately even though changing it to utf-8 would be the preferred
way to handle things you'd require a full export/reimport cycle to
properly convert character sets without breaking data on the byte-level.
Also this change requires changes to the WebDB software to completely
use only UTF-8 internally. There is kinda a work-around in the current
implementation in the WebDB by encoding everything outside ASCII to
HTML-entities (whoever had /THIS/ glorious idea) to avoid having to care
about charsets at other places. This is the root origi of those spurious
encoding issues noticeable on the testserver sometimes.
>
> By the way: the two test servers have an identical db.opt file.
>
> Regards,
> -- wytze
>
Regards,
BenBE.

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature




Archive powered by MHonArc 2.6.18.

Top of Page