ShadowFlare's Realm
http://sfsrealm.hopto.org/cgi-bin/yabb2/YaBB.pl
ShadowFlare's Realm Forums >> Program Development >> block checksum algorithm
http://sfsrealm.hopto.org/cgi-bin/yabb2/YaBB.pl?num=1190955534

Message started by dsjoerg on Sep 28th, 2007, 4:58am

Title: block checksum algorithm
Post by dsjoerg on Sep 28th, 2007, 4:58am

Hello, I'm wondering if one of you could share with me the block checksum algorithm.

My goal is to make a training tool that lets you watch your ladder replays, with an annotate info-board showing live stats from the game. For example current resources, total HP of all units.  Eventually it can include graphs, analysis etc so that you can more easily identify points in the game where you need to do better.

This training tool must run within a custom map.  Hence I need to rewrite the replay file to have a different map reference, which I why I need to compute a new checksum.

Best regards,
--David J.

Title: Re: block checksum algorithm
Post by esby on Sep 29th, 2007, 3:07pm

The block checksum algorithm won't help you for your project,
unless you want to:
* modify replays and inject the missing data?
* check the integrity of replay.

Supposed you want to get the missing data,
you'll need to link directly with the war3 engine during the game,
which would break the war3 eula . (That's what most maphack do...)

esby

Title: Re: block checksum algorithm
Post by dsjoerg on Sep 29th, 2007, 4:17pm

Here's my plan, and how the block checksum algo is necessary.

1. I play a ladder game, let's say it's on Echo Isles.  I save the replay.
2. I have a custom map, my own version of Echo Isles that includes custom JASS code for displaying an infoboard with useful stats, graphs, etc about the game.
3. I modify the replay file so that it thinks the game was played on my custom map.
4. I watch the replay, and I get to see all the cool stats.

So as you can see, in step 3 I am modifying a replay file.  Without the block checksum algo, the Warcraft engine will refuse to play the replay because the checksum will be wrong.

Title: Re: block checksum algorithm
Post by esby on Sep 29th, 2007, 8:24pm

How about modying one warcraft III version (the mpq) so the scripts will be loaded when you play the replay no matter the map choosen?

esby

Title: Re: block checksum algorithm
Post by dsjoerg on Sep 29th, 2007, 9:22pm

Ooh, I have no idea how to do that -- can you link me to any relevant info/tutorials?   I know there are mpq editors out there, but I guess I need a guide to the built-in mpqs.

Title: Re: block checksum algorithm
Post by esby on Sep 30th, 2007, 1:47am

I ain't sure it will work but who know: (I don't know the checksum algorithm anyway...)

1- get an mpq editor.

2- Localize the .js file in the war3 mpq.

3- Make a copy of your war3 folder.

4- Try appending your jass stuff to one of .js that will be loaded by the game?

5- Play on bnet with your original war3, watch replay with the modified one?

Title: Re: block checksum algorithm
Post by d07.RiV on Jun 18th, 2008, 2:52am

Boom I finally got the algorithm by debugging WC3 (it took several hours, and it was the first time I ever tried disassembling anything).
But I suppose there are people who don't think its a good idea for such information to be open to public.

Title: Re: block checksum algorithm
Post by Ojan on Jun 24th, 2008, 12:08pm

Most of blizzards works have been pretty dissected and disassembled so I doubt it's any problem at all to post it.

I for one would very much like to see it. Perhaps you could mail it in any case? ojan.pojan *-AT-* gmail *-dot-* com

Title: Re: block checksum algorithm
Post by Blue on Jun 24th, 2008, 9:08pm

Well, its one thing to disassemble stuff (violating the EULA), its another to post it to a public website. This can especially become a problem for the owner of the website. The BNETD server development was stopped by blizzard by filing a law suite against the website owner - but thats an old story.

I would still vote against making the checksum algorithm public for the same old reason: right now replays are quite unmodifiable and such a good proof for any kind of player dissensions. Making them modifyable makes you loose this proof...

Title: Re: block checksum algorithm
Post by esby on Jun 26th, 2008, 1:59am

I agree on what Blue said.

Now we might have other ways to check if a replay has been altered.
(especially if we have the other versions of the replays...)

esby

Title: Re: block checksum algorithm
Post by MrJag on Jul 9th, 2008, 6:10pm

I'd be interested in seeing the algorithm so that I could automate the map hashing functionality in wc3 game hosting applications.

Title: Re: block checksum algorithm
Post by CryptWizard on Jul 28th, 2008, 8:05am

Please do explain more about the algorithm.

ShadowFlare's Realm » Powered by YaBB 2.2.1!
YaBB © 2000-2008. All Rights Reserved.