Re: [HACKERS] trivial DoS on char recoding

2006-06-20 Thread Martijn van Oosterhout
On Tue, Jun 20, 2006 at 06:10:38PM -0400, Tom Lane wrote: > > Should we get firmer in rejecting invalid configurations? > > The question is how sure are we whether a configuration is "invalid". > AFAIK there's not a really portable way to determine which encoding > matches a locale. initdb has a

Re: [HACKERS] trivial DoS on char recoding

2006-06-20 Thread Tom Lane
Alvaro Herrera <[EMAIL PROTECTED]> writes: > Note that the PO file for the spanish translation is written in Latin1, > not UTF8. So I can adventure that the server is trying to recode a > string which is originally in Latin1, but assuming it is UTF-8, to > Win1250. Yeah, this is a known problem -

Re: [HACKERS] trivial DoS on char recoding

2006-06-20 Thread Alvaro Herrera
Alvaro Herrera wrote: > To reproduce, you using a non-C locale is (es_ES works for me). *blush* Sorry, I rewrote this phrase and obviously didn't reread it very carefully :-) It means that you must use a non-C locale. -- Alvaro Herrerahttp://www.CommandPrompt.

[HACKERS] trivial DoS on char recoding

2006-06-20 Thread Alvaro Herrera
Oswaldo Hernandez just reported this in the pgsql-es-ayuda list. Basically, a conversion between UTF8 and windows_1250 can crash the server. I recall a bug around this general code but I don't recall it being able to provoke a PANIC. To reproduce, create a cluster with UTF-8 encoding and locale e