summaryrefslogtreecommitdiffstats
path: root/content/posts/deluge-change-useragent.rst
blob: a963dea4c8a731e1a84dd90539837f07578af865 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
Change Deluge User-Agent
########################
:date: 2015-04-28
:tags: deluge,user-agent,switch

For some torrents bittorrent peers seem to refuse sharing with my deluge
daemon because it had the wrong 'user-agent' (read: Discrimination).

Fortunately, on the internet nobody knows you are a dog. As long as we show
the correct name-tag and provide some basic features we will be good to go::

  vim $(find / -path '*deluge/core/core.py' )

Now, change the following lines:

.. code-block:: diff

    90c90                                                                          
    <         self.session = lt.session(lt.fingerprint("DE", *version), flags=1)
    ---
    >         self.session = lt.session(lt.fingerprint("UT", 3, 3, 1, 0), flags=1)
    97c97
    <         self.settings.user_agent = "Deluge %s" % deluge.common.get_version()
    ---
    >         self.settings.user_agent = "uTorrent/3310(30017)"