prevent decompile

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
maskeli
Posts: 33
Joined: 09 May 2020, 05:06

prevent decompile

Post by maskeli » 28 Apr 2021, 16:38

I don't want my codes to be easily cracked. I am using mpress and the tools I saw on the internet could not break the exe I made with mpress. but still there is doubt in me. I saw a link. This link is very positive about the compiler, but the download link is broken. What are your views on this matter? How do I get the highest protection? (the broken link : https://autohotkey.com/board/topic/21189-compile-ahk-ii-for-those-who-compile/page-30#entry622493)
Image
Attachments
image.png
image.png (34.59 KiB) Viewed 2423 times

AHKStudent
Posts: 1472
Joined: 05 May 2018, 12:23

Re: prevent decpmpile

Post by AHKStudent » 28 Apr 2021, 18:24

This has been discussed a lot in the past and the findings are

Nothing is 100 percent

AHK H is the best option for protection

MPress compiled exe takes almost no effort to decompile

@Joe Glines has really great info on his youtube about this

https://www.youtube.com/watch?v=jC5yySGzlVo

User avatar
SirSocks
Posts: 360
Joined: 26 Oct 2018, 08:14

Re: prevent decpmpile

Post by SirSocks » 28 Apr 2021, 22:02

Check out ScriptGuard1 and ScriptGuard 2 made by @TAC109 . They provide an extra layer of protection. I've also had good results with ahk source code encrypter made by @feiyue.

ScriptGuard link:
https://www.autohotkey.com/boards/viewtopic.php?t=80229

Source code encrypter link:
https://www.autohotkey.com/boards/viewtopic.php?t=42494

AHKStudent
Posts: 1472
Joined: 05 May 2018, 12:23

Re: prevent decpmpile

Post by AHKStudent » 29 Apr 2021, 03:50

SirSocks wrote:
28 Apr 2021, 22:02
Check out ScriptGuard1 and ScriptGuard 2 made by @TAC109 . They provide an extra layer of protection. I've also had good results with ahk source code encrypter made by @feiyue.

ScriptGuard link:
https://www.autohotkey.com/boards/viewtopic.php?t=80229

Source code encrypter link:
https://www.autohotkey.com/boards/viewtopic.php?t=42494
did script guard 2 stop the payload method?

User avatar
SirSocks
Posts: 360
Joined: 26 Oct 2018, 08:14

Re: prevent decompile

Post by SirSocks » 29 Apr 2021, 06:48

@AHKStudent yes, ScriptGuard 2 stops the payload method. However ScriptGuard 1 does not stop the payload method. You can use both ScriptGuards together, overall it's an extra layer of security. You can use ScriptGuard in combination with the Source Code Encrypter. Adding in obfuscation is also helpful.

That's three extra layers of security. In the world of cyber security, no method will be perfect. But three extra layers of security can be benificial.

Obfuscation link....
https://www.autohotkey.com/boards/viewtopic.php?t=49887

AHKStudent
Posts: 1472
Joined: 05 May 2018, 12:23

Re: prevent decompile

Post by AHKStudent » 29 Apr 2021, 12:58

SirSocks wrote:
29 Apr 2021, 06:48
@AHKStudent yes, ScriptGuard 2 stops the payload method. However ScriptGuard 1 does not stop the payload method. You can use both ScriptGuards together, overall it's an extra layer of security. You can use ScriptGuard in combination with the Source Code Encrypter. Adding in obfuscation is also helpful.

That's three extra layers of security. In the world of cyber security, no method will be perfect. But three extra layers of security can be benificial.

Obfuscation link....
https://www.autohotkey.com/boards/viewtopic.php?t=49887
thank you

maskeli
Posts: 33
Joined: 09 May 2020, 05:06

Re: prevent decpmpile

Post by maskeli » 30 Apr 2021, 15:22

SirSocks wrote:
28 Apr 2021, 22:02
Check out ScriptGuard1 and ScriptGuard 2 made by @TAC109 . They provide an extra layer of protection. I've also had good results with ahk source code encrypter made by @feiyue.

ScriptGuard link:
https://www.autohotkey.com/boards/viewtopic.php?t=80229

Source code encrypter link:
https://www.autohotkey.com/boards/viewtopic.php?t=42494
I will look into these. When I compress my scripts using autohotkey h, they slow down in a way I don't understand. I use imagesearch a lot in the script that has slowed down

maskeli
Posts: 33
Joined: 09 May 2020, 05:06

Re: prevent decompile

Post by maskeli » 30 Apr 2021, 15:42

SirSocks wrote:
29 Apr 2021, 06:48
@AHKStudent yes, ScriptGuard 2 stops the payload method. However ScriptGuard 1 does not stop the payload method. You can use both ScriptGuards together, overall it's an extra layer of security. You can use ScriptGuard in combination with the Source Code Encrypter. Adding in obfuscation is also helpful.

That's three extra layers of security. In the world of cyber security, no method will be perfect. But three extra layers of security can be benificial.

Obfuscation link....
https://www.autohotkey.com/boards/viewtopic.php?t=49887
I did not understand how to use obfuscator. and I couldn't find any videos about this. The link for "obfuscator" says how to use it, but I don't really understand them. I expect someone to post a good video on this topic.

SOTE
Posts: 1426
Joined: 15 Jun 2015, 06:21

Re: prevent decompile

Post by SOTE » 30 Apr 2021, 17:16

maskeli wrote:
28 Apr 2021, 16:38
I don't want my codes to be easily cracked. I am using mpress and the tools I saw on the internet could not break the exe I made with mpress. but still there is doubt in me.
It doesn't matter what programming language that a person uses or what type of protection, you are not going to stop high level programmers who have dedicated themselves to spending time on cracking your program. There is also too many tools and knowledge out there to help them. People who are less experienced about such matters have to remove the idea from their minds of making their program impossible to hack or that their code is so valuable that nobody can't figure out how to make something similar. It should be kept in mind that average Joe user (like 97% of users) isn't a software expert or hacker, so they will not be the problem. If you are dealing with an expert(s), then you are not going to stop them.

If you are concerned about casuals easily inspecting your source code, AutoHotkey does provide various options. Mpress and UPX, Encryptor By FeiYue, AutoHotkey_H, etc... should be good enough for most situations. If the person is that paranoid, then they might get comfort from buying a 3rd party solution which is dedicated for the purpose. However, those tend to be very expensive (and still can be circumvented by the highly skilled). A person needs to ask themselves if going to extremes on protection is really worth it in comparison to what they are offering or doing. One should also be familiar with what their legal options are, not just software protection. A lot of times the real battle will be legal, not technical.

maskeli
Posts: 33
Joined: 09 May 2020, 05:06

Re: prevent decompile

Post by maskeli » 01 May 2021, 03:25

**********
Last edited by maskeli on 03 Feb 2023, 06:44, edited 1 time in total.

SOTE
Posts: 1426
Joined: 15 Jun 2015, 06:21

Re: prevent decompile

Post by SOTE » 03 Feb 2023, 06:49

maskeli wrote:
01 May 2021, 03:25
AHK_H cannot be broken, but in this solution, too, my script becomes useless because it slows down. When I encrypt it with the encryptor, I run the script, but the script shuts itself down with nothing. Maybe I better paste my original code here. Here is the code:
Let's start with some basics and obvious things, before getting into your script, which is a bit long and involved. Let's clarify how you are using AHK_H and Encryptor.

First, just in case, you should be using AHK_H and Encryptor separately and not together, unless you really know what you are doing. Let's clarify that one solution truly does or doesn't work, before jumping off to the other.

Second, keep in mind that specifics about each solution might best be solved by posting a help request to their respective creators, FeiYue (Encryptor topic) or HotKeyIt (AHK_H sub-forum).

Third, in regards to AHK_H, what version are you referring to? Where did you download it from?

With AHK_H, it can give you source code protection without even having to recompile it and use encryption, by just using its compression. This is a specific flavor of compression used by AHK_H, that you can kind of think of it like MPRESS or UPX, except it doesn't have a widely known unpacker. About that, this is why MPRESS or UPX can be lesser protections, because unpackers for them are commonly available and widely known. Though average Joe, is less likely to know what such is about.

So, download a legit copy of AHK_H (https://hotkeyit.github.io/v2/ or https://github.com/HotKeyIt/ahkdll-v1-release). You would choose the v1 download link or Code option for the zip, and go from there.

You can directly replace AHK_L executables and various equivalent files with AHK_H ones. To be on the safe or smart side, make sure to put the AHK_L files you are replacing in a Backup folder, don't just delete them. AHK_H is primarily AHK_L, but with various kinds of additional functionality. Do keep in mind that to limit problems, you want the version of AHK_L to match that of AHK_H, especially if inexperienced. If you are using an old version of one, and then a new version of the other, differences can cause issues. So if you downloaded a matching version and use that for the swap, it will eliminate some issues.

For some further information, check out Joe Glines website and/or video on this-

https://www.the-automator.com/how-to-stop-someone-from-taking-your-script/
(How to stop someone from taking your script)

https://youtu.be/jC5yySGzlVo
(YouTube video)

If for some reason you are philosophically opposed to using AHK_H or don't want to go down the path of recompiling in the future or playing with Visual Studio then sticking with AHK_L is perfectly fine too. You can definitely use Encryptor by FeiYue (https://www.autohotkey.com/boards/viewtopic.php?f=28&t=42494), which is also a good solution. As mentioned, ScriptGuard 1 and ScriptGuard 2, might be an even easier choice to implement with AHK_L, so definitely give that consideration too. I'm just saying to choose a solution first and stick with it for a bit, as oppose to causing confusion by jumping back and forth, then be very clear on how well it doesn't or does work for you.

TAC109
Posts: 1100
Joined: 02 Oct 2013, 19:41
Location: New Zealand

Re: prevent decompile

Post by TAC109 » 03 Feb 2023, 17:18

@maskeli Just a note from the author that ScriptGuard has been updated recently to provide source code encryption.

Cheers
My scripts:-
XRef - Produces Cross Reference lists for scripts
ReClip - A Text Reformatting and Clip Management utility
ScriptGuard - Protects Compiled Scripts from Decompilation
I also maintain Ahk2Exe

Post Reply

Return to “Ask for Help (v1)”