1
0
mirror of https://github.com/d47081/qBittorrent.git synced 2025-02-03 18:34:28 +00:00
Kristof Mattei 140e73be4e
Use the URI's setData to set query data (#15187)
This allows the system to properly encode the '|', instead of passing
the '|' on in the URL, which is not allowed and breaks proxies such as
Authelia.

Then, for the purpose of generalization, I pushed this pattern through
to all places where we join items with a '|'.

This comes with the caveat that when we have individual components which
contain a '|' or any other character that is not allowed per the
HTTP standard, we still like to encode the individual components,
for example in the case of 3 strings, separated by a '|'.
If we don't do this we run into the risk that upon decoding URI finds
'|' in our original strings, which is something we don't want.

For example:
Sender:
````javascript
const arr = ["foo|1", "bar|2"];
const uri = new URI("test.html").setData(arr.join("|"));
````
Then on the receiving window, when it receives the uri and splits it, it
looks like this:
````javascript
const arr = new URI().getData('hashes').split('|');
// arr is now ["foo", "1", "bar", "2"]
````

This is why when we want to send a literal "|" we need to do
`encodeURIComponent` and `decodeURIComponent` manually on each item,
and THEN we join.

For example:
Sender:
````javascript
const arr = ["foo|1", "bar|2"];
const uri = new URI("test.html").setData(arr.map(encodeURIComponent).join("|"));
````

Receiver:
````javascript
const arr = new URI().getData('hashes').split('|').map(decodeURIComponent);
// arr is now ["foo|1", "bar|2"]
````

We don't need to with hashes as they are HEX, so no risk of any weird
characters in there.
2021-07-16 12:53:47 +08:00
2019-10-20 01:28:10 +08:00
2020-03-12 13:12:33 +08:00
2021-06-03 08:56:41 +03:00
2016-12-27 16:56:35 +02:00
2021-03-29 00:08:14 +03:00
2016-05-08 21:47:28 +08:00
2020-10-20 18:56:30 +08:00
2021-03-29 00:08:14 +03:00
2021-06-28 10:41:16 +01:00
2018-09-30 15:46:33 +07:00
2021-06-25 12:18:56 +08:00

qBittorrent - A BitTorrent client in Qt

AppVeyor Status GitHub Actions CI Status Coverity Status


Description:

qBittorrent is a bittorrent client programmed in C++ / Qt that uses libtorrent (sometimes called libtorrent-rasterbar) by Arvid Norberg.

It aims to be a good alternative to all other bittorrent clients out there. qBittorrent is fast, stable and provides unicode support as well as many features.

The free IP to Country Lite database by DB-IP is used for resolving the countries of peers. The database is licensed under the Creative Commons Attribution 4.0 International License.

Installation:

For installation, follow the instructions from INSTALL file, but simple:

./configure
make && make install
qbittorrent

will install and execute qBittorrent hopefully without any problem.

Public key:

Starting from v3.3.4 all source tarballs and binaries are signed.
The key currently used is 4096R/5B7CC9A2 with fingerprint D8F3DA77AAC6741053599C136E4A2D025B7CC9A2.
You can also download it from here.
PREVIOUSLY the following key was used to sign the v3.3.4 source tarballs and v3.3.4 Windows installer only: 4096R/520EC6F6 with fingerprint F4A5FD201B117B1C2AB590E2A1ACCAE4520EC6F6.

Misc:

For more information please visit: https://www.qbittorrent.org

or our wiki here: http://wiki.qbittorrent.org

Use the forum for troubleshooting before reporting bugs: http://forum.qbittorrent.org

Please report any bug (or feature request) to: http://bugs.qbittorrent.org

You can also meet me (sledgehammer_999) on IRC: #qbittorrent on irc.freenode.net


sledgehammer999 sledgehammer999@qbittorrent.org

Description
Some work about adaptive color scheme for Web UI (PR #19901) http://[316:c51a:62a3:8b9::4]/d4708/qBittorrent/src/branch/adaptive-webui
Readme 149 MiB
Languages
C++ 71.5%
JavaScript 13.5%
HTML 12.1%
Python 1%
CSS 0.7%
Other 1.1%