+ Reply to Thread
Results 1 to 7 of 7

Thread: uTorrent

  1. #1
    Guest Coder anthony-joal's Avatar
    Join Date
    22.03.17
    Location
    France
    P2P Client
    qBittorrent
    Posts
    188
    Activity Longevity
    0/20 9/20
    Today Posts
    0/5 ssssss188

    uTorrent

    Please before reading this thread, read Client file format.

    Since BitTorrent clients are updated regularly, i'll post the default file template for Deluge. And will list any changes for a particular version against this default template.

    Default template
    Code:
    {
        "keyGenerator": {
            "length": 8,
            "type": "hash",
            "refreshOn": "TIMED_OR_AFTER_STARTED_ANNOUNCE",
            "refreshEvery": 10,
            "case": "upper"
        },
        "peerIdGenerator": {
            "pattern": "xxxxxxxxxxxxxxxx",
            "refreshOn": "NEVER",
            "shouldUrlEncode": true
        },
        "urlEncoder": {
            "encodingExclusionPattern": "[A-Za-z0-9-]",
            "encodedHexCase": "lower"
        },
        "query": "info_hash={infohash}&peer_id={peerid}&port={port}&uploaded={uploaded}&downloaded={downloaded}&left={left}&corrupt=0&key={key}&event={event}&numwant={numwant}&compact=1&no_peer_id=1",
        "numwant": 200,
        "numwantOnStop": 0,
        "requestHeaders": [
            { "name": "host", "value": "xxxxx"},
            { "name": "User-Agent", "value": "xxxxxxxxxxxxxxxx" },
            { "name": "Accept-Encoding", "value": "gzip" },
            { "name": "Connection", "value": "Close" }
        ]
    }
    3.5.3_44428
    peerIdGenerator.pattern: -UT353S-(\u008c)(\u00ad)[\u0001-\u00ff]{10}
    requestHeaders.User-Agent: uTorrent/353(111652236)(44428)"

    3.5.3_44358
    peerIdGenerator.pattern: -UT353S-F(\u00ad)[\u0001-\u00ff]{10}
    requestHeaders.User-Agent: uTorrent/353(111652166)(44358)

    3.5.1_44332
    peerIdGenerator.pattern: -UT3515-(\u002c\u00ad)[\u0001-\u00ff]{10}
    requestHeaders.User-Agent: uTorrent/351(111389996)(44332)

    3.5.0_44294
    peerIdGenerator.pattern: -UT3500-(\u0006\u00ad)[\u0001-\u00ff]{10}
    requestHeaders.User-Agent: uTorrent/350(111258886)(44294)

    3.5.0_44090
    peerIdGenerator.pattern: -UT3500-(\u003a\u00ac)[\u0001-\u00ff]{10}
    requestHeaders.User-Agent: uTorrent/350(111258682)(44090)


    3.5.0_43916
    peerIdGenerator.pattern: -UT3500-(\u008c\u00ab)[\u0001-\u00ff]{10}
    requestHeaders.User-Agent: uTorrent/350(111258508)(43916)


    3.2.2_28500
    peerIdGenerator.pattern: -UT3220-To[\u0001-\u00ff]{10}
    query: info_hash={infohash}&peer_id={peerid}&port={port}& uploaded={uploaded}&downloaded={downloaded}&left={ left}&corrupt=0&key={key}&event={event}&numwant={n umwant}&compact=1&no_peer_id=1
    numwantOnStop: 200
    requestHeaders.User-Agent: uTorrent/3220(28500)
    requestheaders new header: { "name": "Accept-Language", "value": "{locale}" } The header takes place between "Accept-Encoding" and "Connection".
    Last edited by anthony-joal; 23.05.18 at 23:36.
    This is my signature. There are many others like it, but this one is mine.
    Reply With QuoteReply With Quote
    Thanks

  2. Who Said Thanks:

    H265 (11.08.17) , Cr@zYiNsEiN (11.08.17) , anon (10.08.17)

  3. #2
    Moderator anon's Avatar
    Join Date
    01.02.08
    Posts
    39,804
    Activity Longevity
    11/20 19/20
    Today Posts
    1/5 ssss39804
    "Accept-Language": "en-US"
    The value for this is read from "LocaleName" on registry key HKCU\Control Panel\International, so it can vary between computers.

    Also, how do you handle URL encoding exceptions? uTorrent only encodes a-z, A-Z and - . _ ~ in the info_hash and peer_id as per the protocol specification, but other clients are different.

    I'll have a look at the client file terminology and then your other threads when I have more time, good work so far.
    "I just remembered something that happened a long time ago."
    Reply With QuoteReply With Quote
    Thanks

  4. Who Said Thanks:

    anthony-joal (11.08.17) , H265 (11.08.17)

  5. #3
    Guest Coder anthony-joal's Avatar
    Join Date
    22.03.17
    Location
    France
    P2P Client
    qBittorrent
    Posts
    188
    Activity Longevity
    0/20 9/20
    Today Posts
    0/5 ssssss188
    Quote Originally Posted by anon View Post
    The value for this is read from "LocaleName" on registry key HKCU\Control Panel\International, so it can vary between computers.
    You'r right i updated the definition. For those interested in java you can use "Locale.getDefault().toLanguageTag()".

    Quote Originally Posted by anon View Post
    Also, how do you handle URL encoding exceptions? uTorrent only encodes a-z, A-Z and - . _ ~ in the info_hash and peer_id as per the protocol specification, but other clients are different.
    What do you mean by encoding exception? Since it's an HTTP call, all characters except a-z, A-Z and - . _ ~ have to encoded (with url encoding algorithm) this is part of HTTP protocol specification. Some clients does not seems to URLEncode characters, but these clients are using a standard charset (like qBitTorrent or transmission). Am i right or did i missed something?

    If you meant "what chars should compose the peerId", this is covered by client file terminology, for utorrent i'm 99.9% sure it uses random (from 0x00 up to 0x7E), i'll take another look tonight.

    Here is two peerId that i just got from uTorrent 3.5.0_43916 (in bold chars not being encoded):
    -UT3500-%8c%ab%a9%87%ce%2b%a8o%22%01sj
    -UT3500-%8c%ab%a1%d4%2c%93%24v3%91%60%ee

    As you can see, all characters from 0x00 up to 0xFF are encoded, except those you mentionned, but this is part of the HTTP protocol specification, i haven't seen yet a client that does not URLEncode another way. If there is one i'd like to know so i could investigate :)
    Last edited by anthony-joal; 12.08.17 at 13:18.
    This is my signature. There are many others like it, but this one is mine.
    Reply With QuoteReply With Quote
    Thanks

  6. Who Said Thanks:

    H265 (12.08.17)

  7. #4
    Guest Coder anthony-joal's Avatar
    Join Date
    22.03.17
    Location
    France
    P2P Client
    qBittorrent
    Posts
    188
    Activity Longevity
    0/20 9/20
    Today Posts
    0/5 ssssss188
    Ok.... i understand what you mean, some stupid clients does not follows the Http specification.... i'll change the client definition soon
    This is my signature. There are many others like it, but this one is mine.
    Reply With QuoteReply With Quote
    Thanks

  8. #5
    Guest Coder anthony-joal's Avatar
    Join Date
    22.03.17
    Location
    France
    P2P Client
    qBittorrent
    Posts
    188
    Activity Longevity
    0/20 9/20
    Today Posts
    0/5 ssssss188
    Updated file format to a more readable one and fixed missing encoding exclusion.
    Last edited by anthony-joal; 14.08.17 at 00:39.
    This is my signature. There are many others like it, but this one is mine.
    Reply With QuoteReply With Quote
    Thanks

  9. #6
    Guest Coder anthony-joal's Avatar
    Join Date
    22.03.17
    Location
    France
    P2P Client
    qBittorrent
    Posts
    188
    Activity Longevity
    0/20 9/20
    Today Posts
    0/5 ssssss188
    Added v3.5.3 build 44358
    This is my signature. There are many others like it, but this one is mine.
    Reply With QuoteReply With Quote
    Thanks

  10. #7
    Guest Coder anthony-joal's Avatar
    Join Date
    22.03.17
    Location
    France
    P2P Client
    qBittorrent
    Posts
    188
    Activity Longevity
    0/20 9/20
    Today Posts
    0/5 ssssss188
    Added 3.5.3 build 44428
    This is my signature. There are many others like it, but this one is mine.
    Reply With QuoteReply With Quote
    Thanks

+ Reply to Thread

Tags for this Thread

Posting Permissions

  • You may post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts
  •