Ticket #4445 (new defect)

Opened 4 months ago

Last modified 4 months ago

Trouble with filtering with non-ASCII characters over http with GET

Reported by: jratike80 Owned by: warmerdam
Priority: normal Milestone:
Component: default Version: unspecified
Severity: normal Keywords:
Cc:

Description

The trouble occurs for example when sending the following ogrinfo command from a Windows computer with Finnish locale settings. The WFS server is using UTF-8 character encoding. The following request should find one feature but it does not.

ogrinfo -ro -so WFS:http://hip.latuviitta.org/cgi-bin/tinyows pks_tilastoalue_piste -where name='Hämeenkylä'

If "Hämeenkylä" is written in another way the WFS request is successful

ogrinfo -ro -so WFS:http://hip.latuviitta.org/cgi-bin/mapserver_wfs pks_tilastoalue_piste -where name='Hämeenkylä'

The WFS GetFeature? request that is sent by the failing request is this

/cgi-bin/tinyows?SERVICE=WFS&VERSION=1.1.0&REQUEST=GetFeature?&TYPENAME=lv:pks_tilastoalue_piste&FILTER=%3CFilter%20xmlns=%22http://www.opengis.net/ogc%22%20xmlns:lv=%22http://latuviitta.fi/%22%20xmlns:gml=%22http://www.opengis.net/gml%22%3E%3CPropertyIsEqualTo%3E%3CPropertyName%3Ename%3C/PropertyName%3E%3CLiteral%3EHämeenkylä%3C/Literal%3E%3C/PropertyIsEqualTo%3E%3C/Filter%3E

I attach the failing request also as a file.

The problem is probably not special for GDAL because I have seen similar errors also with other use cases. For example when trying to do filtering of MapServer? WMS layers by sending a filter which is included in the SLD_BODY parameter.

Attachments

ogrinfo_encode_error.txt Download (481 bytes) - added by jratike80 4 months ago.
A failing GetFeature? request that was sent by ogrinfo

Change History

Changed 4 months ago by jratike80

A failing GetFeature? request that was sent by ogrinfo

Changed 4 months ago by jratike80

There is a copy-paste error in the second example request. It should point also to TinyOWS server WFS:http://hip.latuviitta.org/cgi-bin/tinyows instead Mapserver 6.0 WFS on the same server.

Mapserver is giving an internal server error (500) with 'Hämeenkylä' and also when I send the url-encoded example in my first comment with a browser. Mapserver accepts only 'Hämeenkylä'.

Note: See TracTickets for help on using tickets.