Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / DBPacker V1.0 - Simple packer to hide your files

Author
Message
faizeq
15
Years of Service
User Offline
Joined: 13th Oct 2008
Location: Under the table
Posted: 21st Jul 2012 02:15 Edited at: 5th Sep 2012 01:20
Hello guys, just popping in to share a little tools that I had been messing about with. It's just a simple file packer/unpacker for the usage on Darkbasic specifically.
This tools would come in handy to keep your files from prying eyes for distribution and such.
As usual I've included the demo , dll and tool in one distribution file.It's pretty straight forward on the usage. Have a gender at the remarks and readme file if you are stuck.
Happy coding

Update 05/09/2012 - Just a quick update to make the dll much more stable. Main file reuploaded. Thanks for pointing it out Kezzla.

Life begin where ->BeginScene() and it ends at ->EndScene()..so please Present(NULL, NULL, NULL, NULL);

Attachments

Login to view attachments
Marvey
21
Years of Service
User Offline
Joined: 15th Oct 2002
Location:
Posted: 21st Jul 2012 17:22
very nice, one question he loads the files directly from the pack or when running the aplication he extract it somewhere and load the files? regards
faizeq
15
Years of Service
User Offline
Joined: 13th Oct 2008
Location: Under the table
Posted: 21st Jul 2012 18:11
Heya Marvey.To answer that question in short, the application extract it somewhere , loads the file and remove itself automatically.

The slightly longer explanation:
1)The file is extracted somewhere by calling "DBPackerGetFile()", just the exact files that you had selected.
2)The file pointer is parse to the Darkbasic loader command of yours for example load image ,load effect and any other load routine of yours that requires file path.
3)The file is then loaded from that extracted location as it was just like some other location in your computer.
4)On finish loading from your loader call, the file is removed from the extracted location immediately.

Hope that clears it up

Life begin where ->BeginScene() and it ends at ->EndScene()..so please Present(NULL, NULL, NULL, NULL);
MrValentine
AGK Backer
13
Years of Service
User Offline
Joined: 5th Dec 2010
Playing: FFVII
Posted: 22nd Jul 2012 01:21
so the extracted files are openly accessible is that what you are saying or are you using virtual memory space?

Just to let you know where I got that from

faizeq
15
Years of Service
User Offline
Joined: 13th Oct 2008
Location: Under the table
Posted: 22nd Jul 2012 02:29
Yep.. that's correct MrValentine. It's just openly accessible as you had thought and not through a virtual memory space.
For a few millisecond the targeted file is decrypted out of the main packed file and openly accessible to all.On completion of the file I/O read process, the extracted file will destroy itself.
The path in exposing the file for a friction of a time there is just inevitable as building on top of existing application(DB) requires conformance to it's very own limitation and capabilities.

Life begin where ->BeginScene() and it ends at ->EndScene()..so please Present(NULL, NULL, NULL, NULL);
MrValentine
AGK Backer
13
Years of Service
User Offline
Joined: 5th Dec 2010
Playing: FFVII
Posted: 22nd Jul 2012 02:47
ok, I will stick with SPP then >.<

Jeff032
16
Years of Service
User Offline
Joined: 13th Aug 2007
Location:
Posted: 22nd Jul 2012 17:37
Just so you know - even with SPP it's pretty easy for someone to retrieve the media files if they want to.
MrValentine
AGK Backer
13
Years of Service
User Offline
Joined: 5th Dec 2010
Playing: FFVII
Posted: 22nd Jul 2012 20:05
not exactly

Quote: " pretty easy "


but possible, never said it was not... but its a slight bit harder than this tool... at least hard for the novice user, please remember we are all Devs here but the intended user is not as savvy 'all the time', and in defence... only a few end users know how to... compared to the majority...

Lets not hijack now thanks guys, would much rather keep this topic about his tool

Marvey
21
Years of Service
User Offline
Joined: 15th Oct 2002
Location:
Posted: 23rd Jul 2012 00:22
what is SPP?
MrValentine
AGK Backer
13
Years of Service
User Offline
Joined: 5th Dec 2010
Playing: FFVII
Posted: 23rd Jul 2012 01:07
Click on the link in my first post

BlackFox
FPSC Master
15
Years of Service
User Offline
Joined: 5th May 2008
Location: Knight to Queens Bishop 3
Posted: 24th Jul 2012 07:21
@ faizeq,

Had a chance to give this a good run through on a couple of our developments. It works great, and we have had no issues whatsoever. Added this to our list of "plugins" to recommend to others when we can.

We just wanted to say thank you for this.


Twitter: @NFoxMedia
Kezzla
15
Years of Service
User Offline
Joined: 21st Aug 2008
Location: Where beer does flow and men chunder
Posted: 24th Jul 2012 10:23
@faizeq - great work mate, This is a very handy addition! I've been trying to work out a good way to protect my media.

thanks again.



Sometimes I like to use words out of contents
faizeq
15
Years of Service
User Offline
Joined: 13th Oct 2008
Location: Under the table
Posted: 25th Jul 2012 00:43
Thanks for the kind feedback BlackFox and Kezzla
Cheers mate.

Life begin where ->BeginScene() and it ends at ->EndScene()..so please Present(NULL, NULL, NULL, NULL);
Kezzla
15
Years of Service
User Offline
Joined: 21st Aug 2008
Location: Where beer does flow and men chunder
Posted: 4th Sep 2012 20:03
Hi Faizeq,

I have just tried to use your plugin for a project of mine and I found that It behaved strangely. It could not open one of my wave files despite it successfully compiling the directory. It also mixed up some of my images causing the wrong sprites to be used.

have you had similar issues with using it?

My data file was about 80 meg, is there an upper limit to how big the files should be?

thankyou.

kezzla

Sometimes I like to use words out of contents
faizeq
15
Years of Service
User Offline
Joined: 13th Oct 2008
Location: Under the table
Posted: 5th Sep 2012 01:28
Hi Kezzla. I've tweaked the Dll a bit. You can try to download a tweaked up version of the utility from the main download link. Hopefully this would rectify the issue. I've got a rough idea in mind of what could be the issue... and had patch it on up quickly (something in the line of legacy win file data type handling).
As for the limit of file size.. that would be 2GB
Give it a shot and do let me know if it works ..cheers Kezzla.


Life begin where ->BeginScene() and it ends at ->EndScene()..so please Present(NULL, NULL, NULL, NULL);
Kezzla
15
Years of Service
User Offline
Joined: 21st Aug 2008
Location: Where beer does flow and men chunder
Posted: 5th Sep 2012 09:48
ok, I will give the new one a go. Thankyou

[url = http://forum.thegamecreators.com/?m=forum_view&t=199949&b=8] [/url]

Login to post a reply

Server time is: 2024-04-18 12:45:40
Your offset time is: 2024-04-18 12:45:40