mirror of
https://github.com/Ernous/TorrServerJellyfin.git
synced 2025-12-19 13:36:09 +05:00
change useragent and peer id
This commit is contained in:
@@ -5,12 +5,11 @@ import (
|
|||||||
"sync"
|
"sync"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
|
"github.com/anacrolix/torrent"
|
||||||
|
"github.com/anacrolix/torrent/metainfo"
|
||||||
"server/settings"
|
"server/settings"
|
||||||
"server/torr/storage/torrstor"
|
"server/torr/storage/torrstor"
|
||||||
"server/torr/utils"
|
"server/torr/utils"
|
||||||
|
|
||||||
"github.com/anacrolix/torrent"
|
|
||||||
"github.com/anacrolix/torrent/metainfo"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type BTServer struct {
|
type BTServer struct {
|
||||||
@@ -67,9 +66,9 @@ func (bt *BTServer) configure() {
|
|||||||
bt.config.DataDir = settings.BTsets.ContentPath
|
bt.config.DataDir = settings.BTsets.ContentPath
|
||||||
}
|
}
|
||||||
|
|
||||||
userAgent := "uTorrent/3.5.5"
|
userAgent := "qBittorrent/4.3.2"
|
||||||
peerID := "-UT3550-"
|
peerID := "-qB4320-"
|
||||||
cliVers := "µTorrent 3.5.5"
|
cliVers := userAgent //"uTorrent/2210(25302)"
|
||||||
|
|
||||||
bt.config.Debug = settings.BTsets.EnableDebug
|
bt.config.Debug = settings.BTsets.EnableDebug
|
||||||
bt.config.DisableIPv6 = settings.BTsets.EnableIPv6 == false
|
bt.config.DisableIPv6 = settings.BTsets.EnableIPv6 == false
|
||||||
@@ -84,6 +83,7 @@ func (bt *BTServer) configure() {
|
|||||||
bt.config.HTTPUserAgent = userAgent
|
bt.config.HTTPUserAgent = userAgent
|
||||||
bt.config.ExtendedHandshakeClientVersion = cliVers
|
bt.config.ExtendedHandshakeClientVersion = cliVers
|
||||||
bt.config.EstablishedConnsPerTorrent = settings.BTsets.ConnectionsLimit
|
bt.config.EstablishedConnsPerTorrent = settings.BTsets.ConnectionsLimit
|
||||||
|
bt.config.UpnpID = "YouROK/TorrServer"
|
||||||
|
|
||||||
//bt.config.DropMutuallyCompletePeers = true
|
//bt.config.DropMutuallyCompletePeers = true
|
||||||
//bt.config.DropDuplicatePeerIds = true
|
//bt.config.DropDuplicatePeerIds = true
|
||||||
|
|||||||
Reference in New Issue
Block a user