Member of The Internet Defense League Últimos cambios
Últimos Cambios
Blog personal: El hilo del laberinto Geocaching

[BitTorrent] Autentication and "open ports" for the standard BT tracker

Última Actualización: 03 de Noviembre de 2004 - Miércoles

This patch implements these features:

  • Clients ONLY receive peer info if its ports are open and functional. That is, you must accept connections in order to be able to use the tracker.

    This feature is optional and you can disable it simply changing "if True :" by "if False :". As a side effect, you can have a delay (60 seconds?) getting peers, while the tracker is checking your ports. No delay or interference in the peer to peer traffic, nevertheless.

    If you open ports, you MUST restart your BT client in order to force the tracker to recheck you.

  • Autenticated access. You can restrict the tracker usage by IP and/or User/Passphrase.

    This feature is optional and you can disable it simply changing "if True and .. :" by "if False and .. :".

    The files used are:

    • "z-usuarios-claves.txt": An user per line. Format: Username BLANK Passpharse.

    • "z-usuarios-ip-fija.txt": An user per line. Format: ip BLANK Username.

    If you update any file, you must restart the tracker.

    The tracker will only accept an user per IP and a single IP per user.

  • If you are autenticating accesses, you get the user identity in the tracker logs.

This patch is distributed AS IS (if it erases your harddisk is your fault, not mine ;-) ) using the original BitTorrent MIT License. I haven't removed the original code, so you can patch your client and enable/disable the new code at will.

Users without static IP must authenticate by User/Passphrase. The algorithm is simple and portable, and you can port it to any platform and language you like. The sample code works, at least, under MS Windows, Unix, Linux and MacOS X, under Python 2.3.*.

Here you have a sample code in Python.

REMEMBER: Your computer clock MUST be correctly set in order to authenticate.


Historia

  • 03/Nov/04: Primera versión de esta página.



Python Zope ©2004 jcea@jcea.es

Más información sobre los OpenBadges

Donación BitCoin: 19niBN42ac2pqDQFx6GJZxry2JQSFvwAfS