Remove this ad

Lead

Dec 10 13 9:33 PM

Tags : :

I was surprised when I have discovered that aMule is unable to read the eMule collections. The reason for that is the eMule in the new format add also the AICH hash (tag 0x27). So to be able to read these collection is just needed a chenge in the file: MuleCollection.cpp

Here the code with the patch.

[code]
uint32_t cFileCount = ReadInt(infile);

// be more friendly
if (cFileCount > 1024) cFileCount = 1024;

if(!infile.good() || cFileCount > 1024)
{
infile.close();
return false;
}

for (size_t cFi = 0; cFi < cFileCount; ++cFi) {
uint32_t fTagCount = ReadInt(infile);

if (!infile.good() || fTagCount > 6)
{
infile.close();
return false;
}

switch (fTag) {
// FT_AICH_FILEHASH
case 0x27: {
/* rootHash = */ ReadString(infile, 0x02);
break;
}

[/code]

I have already patched my aMule version.
I hope that this can help.
Quote    Reply   
Remove this ad
Remove this ad

#1 [url]

Dec 11 13 9:57 PM

Re: ed2k doesn't read eMule collection

Thank you!
Could you please attach or mail me an example eMule collection file to try it out?

What about the "be more friendly" - is it realistic to expect collections that large?

Quote    Reply   

#2 [url]

Dec 12 13 8:35 PM

Re: ed2k doesn't read eMule collection

You can find an example here:

https://danilo.homenet.org/shares/U/amule/test3.bin.emulecollection

A document that describe how is used the AICH in emule here:

https://danilo.homenet.org/shares/U/amule/eMule-AICH-hashset.pdf

The full code of MuleCollection.cpp here:

https://danilo.homenet.org/shares/U/amule/MuleCollection.cpp

I don't think that there are huge collections having more than 1024 links, but with the patch "be more friendly" at least 1024 links will be imported. With the current implementation if this situation happen all the links are ignored.

Quote    Reply   

#3 [url]

Dec 19 13 5:58 PM

Re: ed2k doesn't read eMule collection

If the collection contains the AICH root hash, we should not just throw it away, but pass it to aMule. I'll have a look on that.

concordia cum veritate

Quote    Reply   

#4 [url]

Dec 20 13 12:03 AM

Re: ed2k doesn't read eMule collection

I think we don't even import AICH root hashes from the "new" ED2K links introduced in the last eMule version. They never made it to any link sites anyway afaik.

Quote    Reply   

#5 [url]

Dec 20 13 8:50 PM

Re: ed2k doesn't read eMule collection

I have tested aMule server and is also able to accept links that contains the AICH root hash (if properly implemented in ed2k), but I'm not sure if this information is used internally by aMule or is throw away. The reason of the patch is to allow ed2k to import the emulcollections that contains also the AICH hash. About 70% of collections that have searched use this extra security information.

Quote    Reply   
Remove this ad

#6 [url]

Dec 21 13 10:36 PM

Re: ed2k doesn't read eMule collection

StuRedman wrote:
I think we don't even import AICH root hashes from the "new" ED2K links introduced in the last eMule version. They never made it to any link sites anyway afaik.


AICH root hashes from eD2k links are imported and handled by aMule. Even the official eMule download emulecollection file contains them.

concordia cum veritate

Quote    Reply   

#7 [url]

Dec 21 13 10:38 PM

Re: ed2k doesn't read eMule collection

We actually do import AICH root hashes from the "new" ED2K links introduced in the last eMule version. But we still use AICH only for corruption handling, not side-by-side like emule:

[quote]-----------------------
- Nov, 28. 2009 -
-----------------------
.: Switched the eMule fileidentifiers from ED2k-Hash + Size to ED2k-Hash + AICH-Hash + Size. This means eMule is now using two hashing algorithms combined (based on MD4 and SHA1) to verify if a received part (and eventually the comlete files) is not corrupt
This change is necessary due to weaknesses in the MD4 algorithm and enables eMule to make sure to never complete a corrupt files for the next decade
All changes are backwards compatible, so no clients or files will be exluded from the network
.: AICH part hashsets are build out of existing AICH recovery hashsets, no rehashing is done
.: AICH verification is enabled when using an ed2k link with included AICH hash, or when searching and downloading a file from Kad when certain requirements are met (this will only start to work once the majority of nodes update)
.: The AICH hash can be seen in the search results list for kad searches if available
.: ed2k links can no longer be created without the AICH Hash, except if it is not available. ed2k links without AICH hash are considered deprecated, but are still accepted by eMule for now

Quote    Reply   

#9 [url]

Jan 17 14 8:29 PM

Re: ed2k doesn't read eMule collection

Thanks!

Quote    Reply   
Remove this ad
Add Reply

Quick Reply

bbcode help