This commit is contained in:
Roman Kelesidis 2023-12-22 00:02:36 +07:00
parent d6d10ab489
commit 4179a2e383
3 changed files with 40 additions and 0 deletions

View File

@ -1,5 +1,23 @@
# 📖 Change Log
## [v2.1.5-2024.01 [Final v2]](https://github.com/torrentpier/torrentpier-lts/tree/v2.1.5-2024.01)
[Full Changelog](https://github.com/torrentpier/torrentpier-lts/compare/v2.1.5-2023.10-HotFix...v2.1.5-2024.01)
- Release v2.1.5-2024.01 🎉
- Some improvements in default template
- Fixed void function result used
- Feature to ban specific torrent clients
- Get SERVER_NAME variable for cron tasks
- Improved handling errors while uploading
- Hide vote button in poll if user already voted
- Fixed broken captcha check on login.php
- Fixed broken sorting in group.php
- Fixed extensions issue
- Some enhancements for dl.php
- Some other changes / improvements
- Some reported bugfixes
- Updated translations
## [v2.1.5-2023.10-HotFix [Final]](https://github.com/torrentpier/torrentpier-lts/tree/v2.1.5-2023.10-HotFix) (2023-11-20)
[Full Changelog](https://github.com/torrentpier/torrentpier-lts/compare/v2.1.5-2023.10...v2.1.5-2023.10-HotFix)

View File

@ -103,6 +103,18 @@ if (!verify_id($passkey, BT_AUTH_KEY_LENGTH))
msg_die('Invalid passkey: ' . $passkey);
}
// Check for client ban
if ($bb_cfg['client_ban']['enabled'])
{
foreach (array_keys($bb_cfg['client_ban']['clients']) as $client)
{
if (substr($peer_id, 0, strlen($client)) === $client)
{
msg_die($bb_cfg['client_ban']['clients'][$client]);
}
}
}
// IP
$ip = $_SERVER['REMOTE_ADDR'];

View File

@ -94,6 +94,16 @@ $bb_cfg['passkey_key'] = 'uk'; // Passkey key name in GET re
$bb_cfg['ignore_reported_ip'] = false; // Ignore IP reported by client
$bb_cfg['verify_reported_ip'] = true; // Verify IP reported by client against $_SERVER['HTTP_X_FORWARDED_FOR']
$bb_cfg['allow_internal_ip'] = false; // Allow internal IP (10.xx.. etc.)
$bb_cfg['client_ban'] = array(
'enabled' => false,
// Clients to be blocked, for example, peer id '-UT' will block all uTorrent clients, '-UT2' will block builds starting with 2 (default: false)
// The second argument is being shown in the torrent client as a failure message
// Handy client list: https://github.com/transmission/transmission/blob/f85c3b6f8db95d5363f6ec38eee603f146c6adb6/libtransmission/clients.cc#L504
'clients' => array(
'-UT' => "uTorrent — NOT ad-free and open-source",
'-MG' => 'Mostly leeching client'
)
);
// Ocelot
$bb_cfg['ocelot']['port'] = 34000;