Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,737,304 Members 41,130 Now Online
XDA Developers Android and Mobile Development Forum

[Q] How to protect my asset folder?

Tip us?
 
basterd2
Old
#1  
Junior Member - OP
Thanks Meter 0
Posts: 12
Join Date: Feb 2014
Default [Q] How to protect my asset folder?

Hey I'm building an app with an asset folder full of sound files. I'd like to protect it from decompilation. I understand it's considered impossible but I'd like to use the example of console games like Playstation's. I remeber they pack their files in custom .DAT files that are indexed. The whole files are packed and it can be painful to extract the files without lnowing the way they are packed. I think that is the best way to do.
Is there a tool that can do that for me?
 
deanwray
Old
#2  
deanwray's Avatar
Senior Member
Thanks Meter 409
Posts: 1,092
Join Date: Apr 2006

 
DONATE TO ME
Quote:
Originally Posted by basterd2 View Post
Hey I'm building an app with an asset folder full of sound files. I'd like to protect it from decompilation. I understand it's considered impossible but I'd like to use the example of console games like Playstation's. I remeber they pack their files in custom .DAT files that are indexed. The whole files are packed and it can be painful to extract the files without lnowing the way they are packed. I think that is the best way to do.
Is there a tool that can do that for me?
this is Dalvik and JIT, so you can't really do what you say... PS is about as far from mobile/java as you can get.... maybe don't use java and use NDK for such things
 
gh0stslayer
Old
#3  
gh0stslayer's Avatar
Senior Member
Thanks Meter 133
Posts: 193
Join Date: Nov 2010
Location: Bangalore
Quote:
Originally Posted by basterd2 View Post
Hey I'm building an app with an asset folder full of sound files. I'd like to protect it from decompilation. I understand it's considered impossible but I'd like to use the example of console games like Playstation's. I remeber they pack their files in custom .DAT files that are indexed. The whole files are packed and it can be painful to extract the files without lnowing the way they are packed. I think that is the best way to do.
Is there a tool that can do that for me?
If you download games like asphalt or need for speed (or any big game for that matter), you will notice that they download additional data (expansion files) to the sdcard which has media and other stuff and they are stored in some different extensions (not mp3 or wav). But I have no idea how it is done. You probably will have to write binaries to encode and decode them.
 
basterd2
Old
#4  
Junior Member - OP
Thanks Meter 0
Posts: 12
Join Date: Feb 2014
Quote:
Originally Posted by gh0stslayer View Post
If you download games like asphalt or need for speed (or any big game for that matter), you will notice that they download additional data (expansion files) to the sdcard which has media and other stuff and they are stored in some different extensions (not mp3 or wav). But I have no idea how it is done. You probably will have to write binaries to encode and decode them.
THis is very interesting, I'm checking the android page, they have a tool that does exactly that, it creates an opaque binary blob. The thing is I'm wondering how to use it directly witrhout using their expansion pack system.

http://developer.android.com/tools/help/jobb.html
 
EmptinessFiller
Old
#5  
Member
Thanks Meter 21
Posts: 88
Join Date: Sep 2013
You can protect your assets while you encrypt them before you put them in the apk. In your app you have to decode them of course.

You don't need a complex encoding system. Maybe you just add 5 to each byte... This may not be 100% sure, but protect from just playing the mp3/wav/ogg file.
 
basterd2
Old
#6  
Junior Member - OP
Thanks Meter 0
Posts: 12
Join Date: Feb 2014
Quote:
Originally Posted by EmptinessFiller View Post
You can protect your assets while you encrypt them before you put them in the apk. In your app you have to decode them of course.

You don't need a complex encoding system. Maybe you just add 5 to each byte... This may not be 100% sure, but protect from just playing the mp3/wav/ogg file.
Can you give me an code example that does that? I've battling the APKexpansion files for hours with no success.
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


XDA PORTAL POSTS

Change Your Toast Notification Style with XToast

Android uses multipletypes of notifications. One of these isknown as a toast notification. … more

Port Sony Xperia Themes to CyanogenMod 11 with Ease

In addition the obvious proficiency with graphics, creating agood Android theme … more

Cell Phone SIM Unlock Bill Just Steps Away from President’s Desk

For all those who believe that Cinderella stories don’t actually … more