How to Protect a Resulting .Exe?

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
User avatar
Puzzlem00n
Party member
Posts: 171
Joined: Fri Apr 06, 2012 8:49 pm
Contact:

Re: How to Protect a Resulting .Exe?

Post by Puzzlem00n »

Hmm. It seems the answers here have deviated slightly from what I expected. I wasn't really trying to protect the code from hacks and stuff, because that's a bit overboard, I know, I just wanted to protect it from archiving software. I assumed it would be easy enough to accomplish, seeing that pretty much every commercial game on my computer does it somehow. I suppose maybe, like Robin said,
Robin wrote:...if WinZip can't take a look at how your game works, neither can LÖVE.
Is there no way around this? Remember, I don't want to make the code completely unreadable, because even commercial games can be hacked. I just want the .exe blocked from WinZip and 7Zip in the interest of professionalism.
I LÖVE, therefore I am.
User avatar
Boolsheet
Inner party member
Posts: 780
Joined: Wed Dec 29, 2010 4:57 am
Location: Switzerland

Re: How to Protect a Resulting .Exe?

Post by Boolsheet »

Puzzlem00n wrote:I assumed it would be easy enough to accomplish, seeing that pretty much every commercial game on my computer does it somehow.
They created their own archive format. LÖVE aims for ease of use and uses a popular standardized format.
Puzzlem00n wrote:Is there no way around this?
No. LÖVE relies on the fact that zip archives can be read from fused/merged executables like this.

LÖVE uses PhysicsFS for loading archives which accpets a whole bunch of different archive formats. Those are all unsupported by the LÖVE developers and probably won't work in a fused/merged executable scenario because, unlike zip, they have their headers at the beginning of the data stream.
Shallow indentations.
User avatar
Robin
The Omniscient
Posts: 6506
Joined: Fri Feb 20, 2009 4:29 pm
Location: The Netherlands
Contact:

Re: How to Protect a Resulting .Exe?

Post by Robin »

Puzzlem00n wrote:Is there no way around this? Remember, I don't want to make the code completely unreadable, because even commercial games can be hacked. I just want the .exe blocked from WinZip and 7Zip in the interest of professionalism.
Even in AAA titles, you can often find out a whole lot about the implementation of the game and the content used therein. So I don't know what the problem would be in terms of professionalism. The Sims and Rise of Nations come to mind.
Help us help you: attach a .love.
User avatar
Puzzlem00n
Party member
Posts: 171
Joined: Fri Apr 06, 2012 8:49 pm
Contact:

Re: How to Protect a Resulting .Exe?

Post by Puzzlem00n »

Okay, if it's not possible, than I suppose that's alright. Like you all say, it's not really going to make much of a difference. Thanks for helping regardless. :)
I LÖVE, therefore I am.
jfroco
Prole
Posts: 24
Joined: Fri Jan 06, 2012 5:14 pm

Re: How to Protect a Resulting .Exe?

Post by jfroco »

Never tested it, but I read about it in thegamecreators.com, hope this helps

Smart Packer Pro
  • Packs the executable or dll and all its supplementary files into a single file
    Creates encrypted archives using strong encryption algorithms
    Compression methods provides good compression rate and high speed
    Run from user level, no admin privileges necessary
    On demand feature (will extract file on demand)
    Saves automatically projects
    Commandline parameters supported
    Embed your own dll as plugin
    Icon and version info support
    Download automatically for updating packed files
    Splashscreen image for loading screen
    Autosave Mode, choose to save changes or start fresh (ideal for demo/trial)
    Include filelist for saving created files
    Configurable storage location
    Password protection
    No temporary files
User avatar
Robin
The Omniscient
Posts: 6506
Joined: Fri Feb 20, 2009 4:29 pm
Location: The Netherlands
Contact:

Re: How to Protect a Resulting .Exe?

Post by Robin »

jfroco wrote:Password protection
Doesn't that mean that you have to type in a password to play the game?
Help us help you: attach a .love.
User avatar
Positive07
Party member
Posts: 1014
Joined: Sun Aug 12, 2012 4:34 pm
Location: Argentina

Re: How to Protect a Resulting .Exe?

Post by Positive07 »

Robin wrote:
jfroco wrote:Password protection
Doesn't that mean that you have to type in a password to play the game?
Nop it means that if someone tries to see what is inside the file he will need a password, of course if you really want to see it you are going to hack it :megagrin:
for i, person in ipairs(everybody) do
[tab]if not person.obey then person:setObey(true) end
end
love.system.openURL(github.com/pablomayobre)
Wojak
Party member
Posts: 134
Joined: Tue Jan 24, 2012 7:15 pm

Re: How to Protect a Resulting .Exe?

Post by Wojak »

Positive07 wrote:
Robin wrote:
jfroco wrote:Password protection
Doesn't that mean that you have to type in a password to play the game?
Nop it means that if someone tries to see what is inside the file he will need a password, of course if you really want to see it you are going to hack it :megagrin:
So how will LOVE see the code without the password? Magic?

@Puzzlem00n

Its not exactly protecting the exe, but You can always make you code ugly and repulsive, keep it in a single main.lua file and don't use any comments...
My game is a example ;)
User avatar
Robin
The Omniscient
Posts: 6506
Joined: Fri Feb 20, 2009 4:29 pm
Location: The Netherlands
Contact:

Re: How to Protect a Resulting .Exe?

Post by Robin »

Wojak wrote:Its not exactly protecting the exe, but You can always make you code ugly and repulsive, keep it in a single main.lua file and don't use any comments...
That's the only true "protection": either make the code so ugly no-one will want to read it, or make the game so awful no-one wants to play it. And the first can be circumvented.
Help us help you: attach a .love.
User avatar
OmarShehata
Party member
Posts: 259
Joined: Tue May 29, 2012 6:46 pm
Location: Egypt
Contact:

Re: How to Protect a Resulting .Exe?

Post by OmarShehata »

I'd be more worried about art assets and whatnot getting stolen. I was pretty chill about the whole encryption thing until a friend of mine found his flash game ripped and ported to iOS and being sold on the appstore. It was taken down after he contacted apple though.

One way to encrypt art assets off the top of my head would be to add some jumbled binary data in the middle of all your assets, that you would remove before using the images, and save it as your own extension, such that anyone trying to open the files won't know how to open them. It would be pretty easily by passable if they simply look at how you decode the images before you use them, but it would at least stop the layman from poking around.

This is the same thing with pirating. There's no way to absolutely make a game impossible to crack, but as long it's easier to just buy the game than go through the trouble of cracking it, I think that would have a tremendous effect on sales. I'm just assuming though, I have no data to back this up. I know people say if someone wanted to pirate game, he won't buy it if he can't pirate it, but I think at least a small percentage would, and that would matter a lot.
Post Reply

Who is online

Users browsing this forum: No registered users and 68 guests