Skip to content

/examine does not seem to handle url-encoded file parameter properly #34

Description

@jenswegar

It looks like the servlet does not like paths in the /examine?file parameter that contain scandinavian characters (åäö).

If I do the following GET request to the /examine endpoint (which should be the url encoded version of /processing/ääkkostest/fmi_485.1_foto_002_001.jpg):

curl -v http://localhost:8989/fits/examine?file=/processing/%C3%A4%C3%A4kkostest/fmi_485.1_foto_002_001.jpg

I get the error

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<error>
    <statusCode>400</statusCode>
    <message> File not sent with request: fmi_485.1_foto_002_001.jpg</message>
    <request> http://localhost:8989/fits/examine</request>
</error>

however the same request without the ää characters in the file parameter works as expected. Only change I did was changing the ää to aa and correspondingly renaming the folder in which the file resides.

I used the 1.5.0-centos7 image tag of the docker image at https://hub.docker.com/r/harvardlts/fitsservlet_container/tags for testning, but the same issue was also present with the 1.4.1 version.

I checked the running container and in both cases the /processing path in the container did contain the expected file, so I'd say that indicates that the error happens somewhere in how the servlet interprets the GET parameter. Is there something I should be doing different in my curl request to get the path with scandinavian characters to work?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions