Entering cookies lines in qbittorrent.conf file

Other platforms, generic questions.
Post Reply
smoothsix
Newbie
Newbie
Posts: 2
Joined: Sat Dec 12, 2020 11:03 pm

Entering cookies lines in qbittorrent.conf file

Post by smoothsix »

Hello,

I am attempting to make cookies work in a linux install in a docker container with web UI, which does not have a section to add cookies.

I am using the conf file to add them, but they are not being honored.

The cookies themselves work fine in the qbittorrent client (validated in OS X client, entered in the UI which helpfully provides a location for them)

The web client doesn't have a cookies section, so you have to edit the conf file to add them.

The site I'm downloading from needs 3 cookies. I'm able to pass my first two entries to the site to pull an RSS Feed, and I'm able to test the qbittorrent client with cookies in OS X to download from the site. That is to say, my RSS Feed works fine, and the client itself is capable of passing cookies to the site I'm downloading from. Everything works!

Except, that is, cookies in the docker container.

The stock config ships with just this first cookies line, which was helpful in determining what they should maybe look like.

I've added the next 3, which don't appear to work (but nothing in the logs complaining):

[Network]
Cookies="__cfduid=cfduidgoeshere; HttpOnly; expires=Sat, 16-Jan-2021 10:04:14 GMT; domain=.db-ip.com; path=/"
Cookies="uid=myuidgoeshere; HttpOnly; expires=Sat, 16-Jan-2021 10:04:14 GMT; domain=.targetdomain.com; path=/"
Cookies="idh=myidhgoeshere; HttpOnly; expires=Sat, 16-Jan-2021 10:04:14 GMT; domain=.targetdomain.com; path=/"
Cookies="PHPSESSID=myphpsessidgoeshere; HttpOnly; expires=Sat, 16-Jan-2021 10:04:14 GMT; domain=.targetdomain.com; path=/"

I've also tried entering all 4 cookies on one line, comma separated, like so:

[Network]
Cookies="__cfduid=cfduidgoeshere; HttpOnly; expires=Sat, 16-Jan-2021 10:04:14 GMT; domain=.db-ip.com; path=/", Cookies="uid=myuidgoeshere; HttpOnly; expires=Sat, 16-Jan-2021 10:04:14 GMT; domain=.targetdomain.com; path=/", Cookies="idh=myidhgoeshere; HttpOnly; expires=Sat, 16-Jan-2021 10:04:14 GMT; domain=.targetdomain.com; path=/", Cookies="PHPSESSID=myphpsessidgoeshere; HttpOnly; expires=Sat, 16-Jan-2021 10:04:14 GMT; domain=.targetdomain.com; path=/"

In the latter case, it gets truncated to just a single entry, and, oddly, it's the second one that gets used.

Does someone have a functioning conf file with multiple cookies entries i can crib from?

Or a local client that generates a conf file? I'm testing using OS X but it doesn't seem to generate a conf file so i can't get the exact format.

The web client in general is very odd. I can also add a magnet link manually, and it has a line that says "Cookie:" but provides no useful info on how to enter a cookie there, what the format is, how to enter multiple cookies, etc for testing.

any thanks would be appreciated!
Post Reply