Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dillo is changing URL and appending a 0. #204

Closed
rouilj opened this issue Jun 24, 2024 · 5 comments · Fixed by #205
Closed

Dillo is changing URL and appending a 0. #204

rouilj opened this issue Jun 24, 2024 · 5 comments · Fixed by #205
Labels
bug Something isn't working
Milestone

Comments

@rouilj
Copy link

rouilj commented Jun 24, 2024

When I try to go to https://rouilj.dynamic -dns.net/demo/. It looks like the server responds with a
200 code and 14k of data. However I never see the data. Instead dillo displays a 403 error by
accessing: https://rouilj.dynamic -dns.net/demo/0. (Just remove the space before the dash to get the
actual url. Just trying to cut down on traffic to the url.)

The site does return a cookie using SameSite that dillo complains about, but it seems to save the
cookie.

Dillo logging does show both urls in a Nav_open_url log line.

Other URL's on the site work. Other browsers (firefox, chrome, links, w3m) on the original URL operate
correctly as well.

Any ideas on how I can figure out why dillo is "rewriting" and "redirecting" to an invalid URL?

I looked at the docs, the dillo help text and the dillorc. There doesn't seem to be a more verbose
mode I can set. dillorc is the default with no changes. cookiesrc is default accept (but it failed the same way with default deny). ~/.dillo has no other config files.

Thanks.

@rodarima
Copy link
Member

Thanks for the report, it seems to be caused by the meta tag without the redirect URL. Here is a reproducer:

<!DOCTYPE html>
<html>
  <head>
    <title>Test empty URL refresh</title>
    <meta http-equiv="Refresh" content="0">
  </head>
  <body>
    <p>Refresh</p>
  </body>
</html>
% dillo /tmp/meta-redirect.html
dillo_dns_init: Here we go! (threaded)
TLS library: OpenSSL 3.3.0 9 Apr 2024
Enabling cookies as from cookiesrc...
Nav_open_url: new url='file:/tmp/meta-redirect.html'
...
Nav_open_url: new url='file:/tmp/0'

I'll see if I can fix the parser.

@rodarima rodarima added the bug Something isn't working label Jun 24, 2024
rodarima added a commit that referenced this issue Jun 24, 2024
The content="0" attribute was wrongly parsed as the URL "0". The change
makes the parser ignore a redirect with a content value that doesn't
have ";" or "url=" after the delay number.

Fixes: #204
@rouilj
Copy link
Author

rouilj commented Jun 24, 2024 via email

@rodarima
Copy link
Member

rodarima commented Jun 24, 2024 via email

@rouilj
Copy link
Author

rouilj commented Jun 24, 2024 via email

@rodarima
Copy link
Member

rodarima commented Jun 25, 2024 via email

@rodarima rodarima added this to the Release 3.2.0 milestone Sep 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants