Jump to content

Example of obtaining the source code of an encrypted script - GameGuardian


Enyby
 Share



 Share


Recommended Comments

49 minutes ago, TisNquyen said:

The compiler does not have a password ?

Is there a way to decode it?

Compiler is used to translate source code to it's binary (machine-readable) form, not for encrypting it with password.

Compiled scripts may be "decoded" with the help of decompiler. However, it may not work in some cases.
Try this (or any other) lua decompiler on your script to answer your question.
https://gameguardian.net/forum/files/file/119-unluac-decompile-binary-scripts/

Link to comment
26 minutes ago, CmP said:

Compiler is used to translate source code to it's binary (machine-readable) form, not for encrypting it with password.

Compiled scripts may be "decoded" with the help of decompiler. However, it may not work in some cases.
Try this (or any other) lua decompiler on your script to answer your question.
https://gameguardian.net/forum/files/file/119-unluac-decompile-binary-scripts/

Sorry I do not know how to use a PC, so you can easily guide the phone.

Link to comment
On 6/18/2018 at 8:52 AM, TisNquyen said:

The compiler does not have a password ?

Is there a way to decode it?

Screenshot_2018-06-18-08-47-05.png

What the heck, why you want open my code?

I dont like you kid, you always steal from us and you bullying me before, so i dont like you...

Link to comment
1 hour ago, TTyo said:

Cái quái gì, tại sao bạn muốn mở mã của tôi?

Tôi không thích bạn, bạn luôn luôn ăn cắp từ chúng tôi và bạn bắt nạt tôi trước đây, vì vậy tôi không thích bạn ...

I'm sorry!

Link to comment
15 minutes ago, TisNquyen said:

I'm sorry!

I know you have much channel on youtube so dont steal anymore please give us credits. And tell your friends too dont steal anymore... i know your admin on your gruop.

I dont like this kid. 

Link to comment
31 minutes ago, TisNquyen said:

I'm sorry!

I can give you that script if you want, but dont steal from us..

Link to comment
42 minutes ago, TTyo said:

I can give you that script if you want, but dont steal from us..

All Scriptof your channel will be decoded no matter what type of encryption I am decoding. Then too it will share it for the other youtuber. Share is Love ?

Link to comment
Hello,
 
I understand how to decompile files but I have an error:

Exception in thread "main" java.lang.IllegalStateException: The input file does not have the signature of a valid Lua file.
         at unluac.parse.BHeader. <init> (BHeader.java:41)
         at unluac.Main.file_to_function (Main.java:71)
         at unluac.Main.main (Main.java:42)

How to fix this error.
-I tried sticking the code in a file.
- By writing directly the code in file.
-- Opens a file in append mode
file = io.open ("dec.lua", "a")
- appends a word test to the last line of the file
file: write (data)
--closed the open file
file: close ()

It must have a trick but I did not find (google and stackoverflow)


The two files I'm trying to decompile

dec1

dec2

Edited by asc
Link to comment

@asc, looks like you don't understand what compilation and decompilation are and why they are used.
The files that you have provided are not compiled. They are some kind of "encrypted". It is not the same at all. You need to understand the difference between "compilation" and "encryption" before you can proceed to working with compiled and/or encrypted scripts.

Link to comment

The file has two levels of protection:
1 - Char to hex + offset (basic protection)
2 - Byte code ("compilation")

The char to hexa I manage to pass it. I get the byte code.


When I want to decompile the byte code. I have this error:

Exception in thread "main" java.lang.IllegalStateException: The input file does not have the signature of a valid Lua file.
         at unluac.parse.BHeader. <init> (BHeader.java:41)
         at unluac.Main.file_to_function (Main.java:71)
         at unluac.Main.main (Main.java:42)

I specify that the byte code recovers is functional under gg (loading and execution) but the decompilation program makes it an error.


I am a professional developer. I know very well what compilation is. And the lua script that I saw as well as those posted are not encrypting but just hide in byte code (obfuscation).

Link to comment
37 minutes ago, asc said:

I am a professional developer.

Then you would not ask such questions for sure.

If you do understand, what compilation is etc, then why would you write this:

4 hours ago, asc said:
The two files I'm trying to decompile

dec1

dec2

attaching non-compiled files?

Is not it obvious for you, that if you are asking about decompilation/having problems with it, then you should provide COMPILED files - exactly the ones, that you tried to decompile, not anything else?

37 minutes ago, asc said:

I specify that the byte code recovers is functional under gg (loading and execution) but the decompilation program makes it an error.

 
Did you expect the decompiler to work in all cases when GG is able to run the script?
You should at least know that there are tons of ways to "confuse" the decompiler without "ruining" script's logic.

Decompiler is intended for reassembling the source code, this cannot be compared to running the script (executing bytecode) at all. That's why decompiler may fail even if GG is able to run the script perfectly.

Edited by CmP
Link to comment
  • Administrators
LJ = gg.getFile()
file = io.open(LJ, "r")
assert(file)
function DZSH(data2)
  a = string.find(data2, "p" .. "r" .. "i" .. "n" .. "t")
  if a == nil then
    -- do load stuff
  else
    os.remove(LJ)
    os.remove(LJ .. ".bak")
    file = io.open(LJ, "w")
    file:write("")
    file:close()
    gg.alert("\230\131\179\232\167\163\229\175\134\229\144\151\229\130\187\233\128\188\228\184\156\232\165\191\239\188\159\232\167\163\231\154\132\229\188\128\230\152\175\228\189\160\229\142\137\229\174\179\239\188\140\232\167\163\228\184\141\229\188\128\230\152\175\228\189\160\228\184\141\233\133\141\230\139\165\230\156\137")
    os.exit()
  end
end
data2 = file:read("*a")
file:close()
DZSH(data2)  

ROFL

Link to comment

My question is how to repair / work around the error that unluac is making:

 

Exception in thread "main" java.lang.IllegalStateException: The input file does not have the signature of a valid Lua file.
         at unluac.parse.BHeader. <init> (BHeader.java:41)
         at unluac.Main.file_to_function (Main.java:71)
         at unluac.Main.main (Main.java:42)

 

On a byt code file like this which is extracted from the dec 1 file.

byte code

I am not an expert on lua. If there are better tools than eclipse lua it interests me. Is there a compatible gg dependency (Jar to add in eclipse ) ?

Link to comment
  • Administrators

GG can not able run this file as script. so does not matter which trash inside.

Link to comment

I know only two methods to extract the bytecode:
Print (*****)
Write (*****)
The original script works.

Link to comment

I prefer to create my own script:
-Accelerates the search by assigning the correct memory area for each function.
-Keep that functions that are useful to me.
-No have a long loading time due to the hexa to char.
-No password typed
-Create a list of items to restore the value edit quickly.

Link to comment

How to recover all the calls made by the script to gg.
Function and parameter
It's a bit long but it should
me allow to recreate the functions that interests me.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.