Skip to content

Percent-encoded bytes in URL are not decoded #3

@abbrev

Description

@abbrev

gopher://example.com/1a%78b and gopher://example.com/1axb should be equivalent, but they are not. The first one sends a%78b to the server, and the second one sends axb to the server.

As another example, a URL of gopher://example.com/7search%09string should separate search and string with a tab byte in the request, but those are instead separated by a literal %09.

This issue actually occurs with a Gopher menu item that has a selector that contains a space—somewhere in Dillo the space is encoded in the URL as %20 (which is correct), but the percent-encoded space in the URL is not decoded back to a space by the plugin.

I haven't tested it, but from looking at the source code it seems like a # in a selector is probably not handled well either. Any # in a selector must be encoded as %23 so that it's not interpreted as a fragment separator, and then %23 must be decoded back to # before it's sent to the server.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    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