Re: [PHP-I18N] mb_check_encoding
[email protected] (Moriyoshi Koizumi) Sun, 22 Mar 2009 17:52:44 +0900
| Newsgroups | php.i18n |
|---|---|
| Message-ID | <[email protected]> |
Hi, mb_check_encoding() without the first parameter is never supposed to work properly. I'm thinking of removing this feature. Regards, Moriyoshi On Sat, Mar 21, 2009 at 7:10 AM, Giacomo Mazzocato <[email protected]> wrote: > if (mb_check_encoding()) { > echo "request encoding ok" ; > } else { > echo "request encoding not ok" ; > } > echo "</p>" ; > ?> > > </body> > </html> > > If you post the value from your browser, all is ok because the > encoding of the page is recognized by the browser as utf-8 (I think). > But if I call that page with curl simulating an Invalid encoding > attack, > I get the same result(request encoding ok) while I should get request encoding > not ok. > Here's the command I used : > curl --data-urlencode $'foo=prov\xef' > http://localhost/mine/test/encoding.php > Thank you in advance > Bye, > Giacomo > > -- > PHP Unicode & I18N Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > >