mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2024-10-22 10:46:04 +03:00
- Better checking of based32 encoded Magnet Links to increase robustness
This commit is contained in:
parent
b1126556c0
commit
e2c3e6dbaa
1 changed files with 1 additions and 1 deletions
|
@ -283,7 +283,7 @@ public:
|
|||
pos = regBase32.indexIn(magnet_uri);
|
||||
if(pos > -1) {
|
||||
QString found = regBase32.cap(1);
|
||||
if(found.length() > 20) {
|
||||
if(found.length() > 20 && (found.length()*5)%40 == 0) {
|
||||
sha1_hash sha1;
|
||||
sha1.assign(base32decode(regBase32.cap(1).toStdString()));
|
||||
hash = misc::toQString(sha1);
|
||||
|
|
Loading…
Reference in a new issue