aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Author Topic: easy sollution for "downl. part X is corrupt"  (Read 2674 times)

gentoo

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 7
easy sollution for "downl. part X is corrupt"
« on: February 17, 2004, 01:40:59 PM »

hi !

this sollution is not breaking compatibility.
and it's clean and beautiful.

1. you can distinguish emule from amule clients
2. implement "getpartialhash(file,offset,size)" in amule
3. note the uploader for each block of each part
4. on bad parts call enought reachable amule or compatible clients with getpartialhash on all blocks
5. compare with local hash.
6. bad blocks of part identified if more honest as milicious amule clients reported hashes.
7. bad uploader identified and blocked.
8. redownload only the bad block in part, and not whole part .
  and avoid the bad uploader who probably uploades only a few bytes to millions of users within minutes, thus let most subsequent downloads of this part fail again.
(good compressable '0' content chunks.. hou've heard from it)

this idea originated somewhere from the emule board or such source.

it's up to u!
this change is almost trivial, some pages of c++.
it would even convince people to use amule instead of emule and spread the word.
(is there a projectfile for msvc? a windows release will then be important)

-one std::vector for each part of each file for the uploader-ip's
-one new protocol function which is simple and cheap in traffic. (limit its use to prevent denial of service)
-alternative ich function which is half a c++ page.
(use old ich if not enought clients respond to getpartialhash) (2 or 3 should be sufficient. )

anybody interested?
Logged