how can i protect 3D textures and models ?

Everything related to 3D programming
User avatar
skinkairewalker
Enthusiast
Enthusiast
Posts: 627
Joined: Fri Dec 04, 2015 9:26 pm

how can i protect 3D textures and models ?

Post by skinkairewalker »

hello everyone !
I'm trying to protect my 3d game from others who might want to enjoy my 3D textures and models, is there any way?
User avatar
Keya
Addict
Addict
Posts: 1891
Joined: Thu Jun 04, 2015 7:10 am

Re: how can i protect 3D textures and models ?

Post by Keya »

There's not much you can do beyond encrypting them, but a cracker can simply dump them after they've been decrypted.

You could use asymmetric encryption like RSA where the public and private keys are different ... that would at least prevent the user from applying their own models (unless they patch in their own public and private keys), but still wouldn't prevent them dumping after they've been decrypted.

To help hide them in memory, perhaps you can patch their magic header bytes after theyve been loaded (eg. like patching the first two "MZ" bytes of a DLL after you've loaded it), as those bytes are generally only checked once during loading.

There may also be other bytes/fields in the file header that are required when loading the file but never used again afterwards - they can also then be patched to render a dumped version as corrupt. (Of course, this too can also be thwarted by dumping the file from memory before you make these patches)

At the end of the day, if your app needs to use a texture/model it needs access to that in it's original (not encrypted) form, and it will always be vulnerable at that stage, but encryption will at least prevent casual crackers.
User avatar
skinkairewalker
Enthusiast
Enthusiast
Posts: 627
Joined: Fri Dec 04, 2015 9:26 pm

Re: how can i protect 3D textures and models ?

Post by skinkairewalker »

i made an encrypted packer with images (for 2d games) using lzma packer and AES...

but with ogre3D, you can't import models from memory or textures... or am I wrong?
User avatar
Keya
Addict
Addict
Posts: 1891
Joined: Thu Jun 04, 2015 7:10 am

Re: how can i protect 3D textures and models ?

Post by Keya »

I'm not familiar with ogre3D's API sorry, but my comments apply in general to all 3D systems.
If you can find API's that load from memory instead of load from file, that would be to your advantage
User avatar
skinkairewalker
Enthusiast
Enthusiast
Posts: 627
Joined: Fri Dec 04, 2015 9:26 pm

Re: how can i protect 3D textures and models ?

Post by skinkairewalker »

there is not even the possibility of encrypting the textures and images that will be used in the ogre?
User avatar
Keya
Addict
Addict
Posts: 1891
Joined: Thu Jun 04, 2015 7:10 am

Re: how can i protect 3D textures and models ?

Post by Keya »

Yes you can encrypt them, you just need to decrypt them before loading them with Ogre
User avatar
skinkairewalker
Enthusiast
Enthusiast
Posts: 627
Joined: Fri Dec 04, 2015 9:26 pm

Re: how can i protect 3D textures and models ?

Post by skinkairewalker »

can i encrypt texture, load into pb application, decrypt in memory and load into ogre ???
User avatar
Keya
Addict
Addict
Posts: 1891
Joined: Thu Jun 04, 2015 7:10 am

Re: how can i protect 3D textures and models ?

Post by Keya »

as long as Ogre allows you to load a data buffer from memory, yes. (and that would be ideal)
If Ogre only allows you to load a data buffer from file then you'll need to decrypt to a file first, then load the file with Ogre, then delete the decrypted file.
Bitblazer
Enthusiast
Enthusiast
Posts: 733
Joined: Mon Apr 10, 2017 6:17 pm
Location: Germany
Contact:

Re: how can i protect 3D textures and models ?

Post by Bitblazer »

It is a regular topic on the Ogre forum.
webpage - discord chat links -> purebasic GPT4All
User avatar
Saki
Addict
Addict
Posts: 830
Joined: Sun Apr 05, 2020 11:28 am
Location: Pandora

Re: how can i protect 3D textures and models ?

Post by Saki »

Hello,
I have made you a little crypter for it.

viewtopic.php?f=12&t=77513
地球上の平和
User avatar
skinkairewalker
Enthusiast
Enthusiast
Posts: 627
Joined: Fri Dec 04, 2015 9:26 pm

Re: how can i protect 3D textures and models ?

Post by skinkairewalker »

Saki wrote: Sat Jun 26, 2021 7:27 pm Hello,
I have made you a little crypter for it.

viewtopic.php?f=12&t=77513
awesome !! this is very usefull ..
but the question would be, how to make the filesystem ogre import a texture or image from memory?
User avatar
Saki
Addict
Addict
Posts: 830
Joined: Sun Apr 05, 2020 11:28 am
Location: Pandora

Re: how can i protect 3D textures and models ?

Post by Saki »

Hi, unfortunately I do not know, but surely others here in the forum know.

I have a other code added, a Diffusor, that shows how to make worthless the images.
You can still see the images but they are worthless for others.
地球上の平和
Bitblazer
Enthusiast
Enthusiast
Posts: 733
Joined: Mon Apr 10, 2017 6:17 pm
Location: Germany
Contact:

Re: how can i protect 3D textures and models ?

Post by Bitblazer »

Technical methods like encryption of data only works against complete amateurs. The ogre thread that i linked you to, explains that in more detail. Better learn from examples of BIG companies doing products like crytek or Mario Galaxy or enjoy wasting your (limited) lifetime :?

ps: i only know one method that effectively protects you against reuse of your work commercially and that is by using the law, but dont expect that to be easy or cheap or fun.
webpage - discord chat links -> purebasic GPT4All
User avatar
Mijikai
Addict
Addict
Posts: 1360
Joined: Sun Sep 11, 2016 2:17 pm

Re: how can i protect 3D textures and models ?

Post by Mijikai »

Bitblazer wrote: Sun Jun 27, 2021 5:49 pm Technical methods like encryption of data only works against complete amateurs....
This, every basic gamehack usually hooks the render pipeline whatever happens before is not relevant.
All this encryption stuff alone is pointless and nothing but a big wast of time.

But im sure some malware kiddies are probably happy about all that encryption stuff...
User avatar
Saki
Addict
Addict
Posts: 830
Joined: Sun Apr 05, 2020 11:28 am
Location: Pandora

Re: how can i protect 3D textures and models ?

Post by Saki »

@Mijikai
Thanks for your experience with encryption.
Anyone who programs malware will also be able to encrypt a file.
My crypting tools are not made for these people and I don't appreciate it when
someone suggests, based of pure bashing, you can or should do this out with me tools.

That is lowest drawer !

Expand their knowledge in this area and contribute something meaningful !
Mijikai wrote: Sun Jun 27, 2021 6:15 pm But im sure some malware kiddies are probably happy about all that encryption stuff...
Suppose you have a software with a personalization key.
Your images and databases are AES encrypted and key dependent.
How do you make them visible without knowing the key ? :shock:
Nobody can. :o

I added another Diffuser with AES support.

Have fun
地球上の平和
Post Reply