dillo-plus icon indicating copy to clipboard operation
dillo-plus copied to clipboard

Cookies freeze the whole browser

Open kuchikuu opened this issue 1 year ago • 3 comments

Hello, Yesterday I had my Debian's dillo installed, and I was just running dillo-plus from the src/ directory.

Today, I apt remove dillo, and I installed dillo-plus with "make install".

After that, Dillo+ is using its own libraries, and apparently websites that use cookies freeze the browser.

I have even reverted my changes (that I pulled) and with commit 82f6faa2f1954e071038361767c0d60ab47315a1 as head, I get the following output:

user@debian:~/git/kuchikuu/dillo-plus/src$ ./dillo http://localhost:7777/setcookie_test.php
Domain: Default deny.
dillo_dns_init: Here we go! (threaded)
Loaded TLS certificates.
Enabling cookies as from cookiesrc...
Nav_open_url: new url='http://localhost:7777/setcookie_test.php'
Dns_server [0]: localhost is 127.0.0.1
Connecting to 127.0.0.1:7777
cookies.c: a_Dpi_send_blocking_cmd cmd = {<cmd='get_cookie' scheme='http' host='localhost' path='/setcookie_test.php' '>}
Dpi_check_dpid: check_st=1
Dpi_check_dpid: OK
Dpi_get_server_port: server_name = [cookies]
[<cmd='check_server' msg='cookies' '>]
Dpi_get_server_port: rply=<cmd='send_data' msg='5031' '>
Dpi_get_server_port: port_str=5031
Dpi_connect_socket: server=cookies port=5031

I did

sed -i 's/_MSG/MSG/g' cookies.c menu.cc IO/dpi.c

in the src/ directory before compiling to see the messages

The php page that freezes the browser is this: (This is just an example to reproduce the issue. Any website that uses the cookies (with coockiesrc ALLOW) will freeze the browser. It's just that everything is disabled by default so we didn't see an issue. )

<?php
	setcookie("aaa","bbb", time()+2*24*60*60);
?>
<html>
<body>
<?php
	echo "Cookie: " . $_COOKIE["aaa"];
	echo "<br><br>";
	echo "All cookies: " . json_encode($_COOKIE);

?>
</body>
</html>```

kuchikuu avatar Jan 08 '24 15:01 kuchikuu

The cookies are the a problem with 82f6faa2f1954e071038361767c0d60ab47315a1 (latest commit)

By using my changes ( 97a645291a612d1910227327a5164a28bc7bad1b ) I was able to disable cookies

  1. ./src/dillo
  2. Tools -> Disable cookies
  3. open my php script
  4. works
  5. Tools -> Enable cookies
  6. refresh
  7. freezes

Since it happens even on old commit, I don't suspect my changes to be the problem.

kuchikuu avatar Jan 08 '24 15:01 kuchikuu

And just a word: When I was doing the cookie toggle yesterday, the cookies did not freeze the browser. It started happening after I removed dillo from my computer and started using pure Dillo+. (after sudo make install)

kuchikuu avatar Jan 08 '24 15:01 kuchikuu

The issue is strange indeed. Can you test if with the new "Use cookies" option disabled (just merged in branch main) the issue is still present?

crossbowerbt avatar Feb 04 '24 08:02 crossbowerbt

closing for now

crossbowerbt avatar Sep 19 '24 02:09 crossbowerbt