Staredit Network > Forums > SC1 UMS Theory and Ideas > Topic: freeze protection
freeze protection
Feb 28 2018, 6:02 pm
By: trgk  

Feb 28 2018, 6:02 pm trgk Post #1



freeze protection is a type of EUD-powered protectors.

How does this work?
- 1. Read an entire map content.
- 2. Compute a checksum.
- 3. Use that checksum to decrypt map triggers.


How to use?

- 1. Download the latest version of euddraft at here
- 2. Extract it somewhere. You'll have euddraft.exe
- 3. Drag & drop your homemade map over euddraft.exe




Feb 28 2018, 10:37 pm Lanthanide Post #2



So it modifies the triggers in the map to be encrypted and places a checksum in the map file, and upon executing the map if the checksum matches what is expected, the triggers are decrypted by the EUD engine?

Is there any practical way to unprotect a map protected in this way? What encryption key is used for each map? I presume it's somehow based on the checksum? Can someone unprotect the map by copying it out of SC's memory?



None.

Mar 1 2018, 7:32 am trgk Post #3



1. It uses a map checksum as encryption key. No checksum is stored.
2. Because map tampering will result in incorrect checksum, thus incorrect decryption, map just won't work after tampering.
3. One can unprotect the map by memory dumping and some hard work. I don't expect anyone could practically do that :)



EUD

Mar 1 2018, 8:29 am Lanthanide Post #4



Oh, so another question: after freeze protection is applied, the map can still be opened by editors (scmdraft etc)? Are the triggers readable, or are they garbage?

Ie, is this changing the map file contents directly?



None.

Mar 1 2018, 11:47 am trgk Post #5



Quote from Lanthanide
Oh, so another question: after freeze protection is applied, the map can still be opened by editors (scmdraft etc)? Are the triggers readable, or are they garbage?

Ie, is this changing the map file contents directly?

Triggers become garbage. Location become garbage (though locations can be recovered fairly easily).

IIRC, Frozen maps can be viewed (in encrypted state) via starforge. I've focused on preventing further edits, so I don't think this as a vulnerability. So if you'd like, see how freeze encrypts the map with SF.



EUD

Mar 1 2018, 12:07 pm Excalibur Post #6

The sword and the faith

Can this be used on a map thats been compressed w/Tinymap? I think a combination of preventing tampering plus compression would bring us back to the age of when protection was the last word.




SEN Global Moderator and Resident Zealot
-------------------------
The sword and the faith.

:ex:
Sector 12
My stream, live PC building and tech discussion.

Mar 1 2018, 6:48 pm Lanthanide Post #7



Right now, tinymap isn't EUD safe, because it makes a lot of assumptions about unit relationships, using the standard SC rules, so it can make maps with EUDs unplayable. Depends what you're doing with your EUDs though (discuss any concerns with Farty).



None.

Mar 9 2018, 9:20 pm Lanthanide Post #8



I just tried applying freeze protection to my map (which has a lot of EUD triggers in it), and upon hosting I get "unsupported EUD".

I'm assuming that freeze protection is supposed to be supported, since it sounds like Blizzard deliberately went out of their way to support it, but it doesn't work on my map? Combination of EUD actions + EUD freeze maybe?



None.

Apr 22 2018, 5:34 am Lanthanide Post #9



Now I'm using EUD Editor 2, when I attempt to freeze my injected map, I get these errors:

C:\Games\Starcraft\Scmdraft2\EUDDraft>euddraft.exe DesertStrikeNightRemastered3.20OI.scx
euddraft 0.8.2.4 : Simple eudplib plugin system
- This program follows MIT License. See license.txt
- Press SHIFT to force check update while opening euddraft.
- Freeze protector mode.
Loading map DesertStrikeNightRemastered3.20OI.scx
Traceback (most recent call last):
File "C:\Python34\lib\site-packages\cx_Freeze\initscripts\__startup__.py", line 14, in run
File "C:\Python34\lib\site-packages\cx_Freeze\initscripts\Console.py", line 26, in run
File "euddraft.py", line 215, in <module>
File "C:\Python34\lib\site-packages\eudplib-0.57.1-py3.4-win32.egg\eudplib\maprw\loadmap.py", line 42, in LoadMap
File "C:\Python34\lib\site-packages\eudplib-0.57.1-py3.4-win32.egg\eudplib\core\mapdata\mapdata.py", line 40, in InitMapData
File "C:\Python34\lib\site-packages\eudplib-0.57.1-py3.4-win32.egg\eudplib\core\mapdata\stringmap.py", line 69, in InitStringMap
File "C:\Python34\lib\site-packages\eudplib-0.57.1-py3.4-win32.egg\eudplib\core\mapdata\chktok.py", line 96, in getsection
KeyError: b'SWNM'




None.

Apr 22 2018, 10:23 am trgk Post #10



You cannot freeze a map generated by EUD Editor 2. You should request freeze protection inside EUD Editor.



EUD

Apr 23 2018, 9:49 pm trgk Post #11



According to the EUDEditor2 dev, you should add this line to '추가 eds텍스트' section in the following window.
Code
[freeze]




Don't know how they're presented in the English version of EUDEditor2

Attachments:
Greenshot 2018-04-24 06.47.39.png
Hits: 58 Size: 160.84kb



EUD

Apr 23 2018, 10:53 pm Lanthanide Post #12



Could you make a screenshot showing where to put [freeze]? SEN doesn't seem to support your korean unicode so I have no idea where to put it on that screen.

Edit: NVM, I see it's the "eds" section. Was using linux at work and the text you posted appears as unintelligible garbage, but on windows I can see "eds" in the middle there. Will try it later today!

Post has been edited 2 time(s), last time on Apr 24 2018, 1:00 am by Lanthanide.



None.

Apr 24 2018, 9:31 pm Lanthanide Post #13



I tried out the freeze protection as part of EUD Editor, but it fails on my map:

Loading plugin TriggerEditor.eps...
[epScript] Compiling "TriggerEditor.eps"...
Loading plugin dataDumper...
- Loading file "C:\Games\Starcraft\Scmdraft2\EUDEditor\Data\temp\RequireData"...
- Loading file "C:\Games\Starcraft\Scmdraft2\EUDEditor\Data\temp\stat_txt.tbl"...
* *
* *
[[ freeze activated ]]
* *
* *
Freeze plugin loaded
--------- Injecting plugins... ---------
Saving to C:\Games\Starcraft\Maps\BroodWar\DesertStrikeNightRemastered3.20OI.scx...
[Stage 1/3] CollectObjects
- Collected 8682 / 8682 objects
[Stage 2/3] AllocObjects
- Preprocessed 8682 / 8682 objects
- Allocating objects..
[Stage 3/3] ConstructPayload
- Written 8682 / 8682 objects
Output scenario.chk : 16.801MB
[Stage 4/3] Applying freeze mpq modification...
==========================================
[Error] Error on mpq protection (4294967294) Traceback (most recent call last):
File "C:\gitclones\euddraft\applyeuddraft.py", line 149, in applyEUDDraft
RuntimeError: Error on mpq protection (4294967294)


I thought maybe it's because my map has got raw EUD triggers in it, but I tried an earlier version (2.63) which has no EUD triggers at all (from 1.16.1), and it also fails the same way. It looks like it may actually have injected stuff in to the map, as it's now over 900k in size (normally its ~500k), and looking in chkdraft it does appear that there are some extra triggers in there, probably for the freeze, but when I try to play the map I get "unsupported EUD error", so it's clearly not working properly.

I tried it on one of the blizzard melee maps and it worked without error (and I confirmed the freeze triggers are present in chkdraft), so it doesn't seem to be a problem with EUD editor.

Post has been edited 1 time(s), last time on Apr 24 2018, 9:36 pm by Lanthanide.



None.

Apr 24 2018, 10:07 pm trgk Post #14



I'll look into that on the next week. (Studying for test now)



EUD

May 11 2018, 12:46 pm trgk Post #15



Could you send your map and EUD editor configuration file to phu54321@naver.com?



EUD

Options
  Back to forum
Please log in to reply to this topic or to report it.
Members in this topic: None.
[02:08 pm]
SiKiN -- oh yea and a mech version
[02:05 pm]
SiKiN -- We are working on a Marine version next with a Zergling version aswell. not sure about protoss because of the sprite limits
[02:04 pm]
SiKiN -- I think its done, finaly
[10:00 am]
KrayZee -- :0
[09:36 am]
Suicidal Insanity -- They just have a discord for posting even more memes than they post here ;(
[08:20 am]
SiKiN -- You guys have a testing group for maps? Or a discord?
[06:34 am]
MasterJohnny -- Zoan
Zoan shouted: guys im going to China in 2 days
Bring dust mask things and a mosquitoes net. If anyone asks nothing happened on June 4 1984.
[06:34 am]
O)FaRTy1billion[MM] -- NudeRaider
NudeRaider shouted: FaRTy1billion I'm wondering: Does extended anything (like place extended units for supply) count as euds (i'd guess no)? Do these overflows still work?
I'm pretty sure all extended units and extended players were fixed
[06:14 am]
Pr0nogo -- I mean I get people not wanting to put in the work, it's not easy, but then they'll say as much without people whining in the shoutbox about my posts
Please log in to shout.


Members Online: Roy, jjf28, SiKiN, Wing Zero