Makefile for code obfuscation and creating .love file

Showcase your libraries, tools and other projects that help your fellow love users.
Post Reply
User avatar
sinthesis
Prole
Posts: 4
Joined: Sun Mar 04, 2018 5:06 am
Contact:

Makefile for code obfuscation and creating .love file

Post by sinthesis » Sun Mar 11, 2018 7:03 pm

I created a NodeJS script to make life a little easier. It supports two arguments one for backing up (-b) your files before processing and another to obfuscate (-o) your code before converting your game into a SuperGame.love file.

Currently, it's written for Mac, but it could easily be adapted to Windows and Linux. I would be more than happy to include them in the github page I have for it if someone is so inclined to create them.

Github: https://github.com/realjas/MakeLove

If you have any questions let me know, but it should be pretty straightforward and keep you from having to mess with the terminal too much. :)
Attachments
MakeLove.zip
(30.24 KiB) Downloaded 18 times

User avatar
zorg
Party member
Posts: 2378
Joined: Thu Dec 13, 2012 2:55 pm
Location: Absurdistan, Hungary
Contact:

Re: Makefile for code obfuscation and creating .love file

Post by zorg » Sun Mar 11, 2018 7:41 pm

Three things,
0. Hi and welcome to the forums!
1. Be aware that the obfuscation is more or less reversible to some extent, not really giving any amount of protection should someone really wanted to have a look-see, and
2. from luaJIT:
The generated bytecode is portable and can be loaded on any architecture that LuaJIT supports, independent of word size or endianess. However the bytecode compatibility versions must match. Bytecode stays compatible for dot releases (x.y.0 → x.y.1), but may change with major or minor releases (2.0 → 2.1) or between any beta release. Foreign bytecode (e.g. from Lua 5.1) is incompatible and cannot be loaded.
Me and my stuff :3True Neutral Aspirant. Why, yes, i do indeed enjoy sarcastically correcting others when they make the most blatant of spelling mistakes. No bullying or trolling the innocent tho.

User avatar
sinthesis
Prole
Posts: 4
Joined: Sun Mar 04, 2018 5:06 am
Contact:

Re: Makefile for code obfuscation and creating .love file

Post by sinthesis » Sun Mar 11, 2018 7:45 pm

Thanks for the notes! I hadn't done a whole lot of research on it, but either way I figured someone might find the script useful.

Is there any other obfuscation methods that aren't reversible? I figure there are people that'd like to keep their code private without compiling an app... If that even does that. I just started messing around with the engine, after all.

User avatar
raidho36
Party member
Posts: 1685
Joined: Mon Jun 17, 2013 12:00 pm

Re: Makefile for code obfuscation and creating .love file

Post by raidho36 » Sun Mar 11, 2018 7:48 pm

Why'd you write in NodeJS though? You know you could use LÖVE itself for that purpose, right?

There's no such obfuscation methods that aren't reversible. If you'd obfuscate your program that it cannot be turned back to machine code, you wouldn't be able to run it.

Obfuscating your code is a silly sentiment. What do you have in there that warrants doing it? Military secret algorithm? Please.

User avatar
zorg
Party member
Posts: 2378
Joined: Thu Dec 13, 2012 2:55 pm
Location: Absurdistan, Hungary
Contact:

Re: Makefile for code obfuscation and creating .love file

Post by zorg » Sun Mar 11, 2018 7:55 pm

Licences protect code, not obfuscation.

Besides, imo it's arrogance to think that whatever code one might write has any chance of being used in another program without actually understanding it (not to mention 1:1 carbon copying wouldn't even work, and taking notes of code should be a crime), and that takes way longer than what people would sacrifice to do that... unless we talking about chinese ripoffs, but i'm guessing that's not your intended market either.

Thing is, people would more likely rip your assets off, than your code, and that too, should be protected by licenses and copyright and the like.
Me and my stuff :3True Neutral Aspirant. Why, yes, i do indeed enjoy sarcastically correcting others when they make the most blatant of spelling mistakes. No bullying or trolling the innocent tho.

User avatar
sinthesis
Prole
Posts: 4
Joined: Sun Mar 04, 2018 5:06 am
Contact:

Re: Makefile for code obfuscation and creating .love file

Post by sinthesis » Sun Mar 11, 2018 8:12 pm

raidho36 wrote:
Sun Mar 11, 2018 7:48 pm
Obfuscating your code is a silly sentiment. What do you have in there that warrants doing it? Military secret algorithm? Please.
Don't you mock my military secrets! ;)

I wrote it in Node because I'm used to using it and had nothing better to do with my 4th day of dealing with insomnia. I thought it might be helpful, but if not... eh. It was something to do.

Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests