Football Fans: Download the 2012 Schedule App from Google Play!


Go Back   Android Forums > Android Development > Application Development > Developer 101

Developer 101 101 Tutorials



Reply
 
LinkBack Thread Tools
Old June 1st, 2010, 01:32 AM   #1 (permalink)
New Member
 
Join Date: Jun 2010
Posts: 1
 
Device(s):
Thanks: 0
Thanked 0 Times in 0 Posts
Default encryption help

Hi there,

We have an application that runs under java and under android which encrypts and decrypts data using AES. We found that we can decrypt data under android if the data was originally encrypted using android, and same applies with the java version. However, if we tried decrypting under android data that was originally encrypted under java, it doesnt work, and vice versa.

We believe we have narrowed it down to SecureRandom. For some reason, secret keys derived from SecureRandom are different for java and android.

Has anyone else experienced this and are there any solutions to this problem?

Thanks in advance.

triocorp is offline  
Reply With Quote
Sponsors
Old June 2nd, 2010, 12:49 AM   #2 (permalink)
Member
 
TheAndroidWorks's Avatar
 
Join Date: Dec 2009
Location: Nashville
Posts: 269
 
Device(s):
Thanks: 3
Thanked 26 Times in 23 Posts
Default

Yes, we encountered a small stump when we wrote our 256 AES Android to PHP interop a while back. I can't remember exactly what the solution was, but I will ask the other developer... for some reason I think I remember it having to do with bytecode formats.

PHP and Android/Java had two very different ways of handling the encrypted strings that caused problems within the encrypt and decrypt functions that we had to program around.

I know it may be stating the obvious, but have you tested for snags in passing the key and IV, etc?
__________________
Charades and Catchphrase on your phone...
Party with friends or family using these social games for 4 - 20+ people!
(Now in the T-Mobile Channel on the Android Market!!!)
TheAndroidWorks is offline  
Reply With Quote
Old January 18th, 2011, 12:28 AM   #3 (permalink)
gtx
New Member
 
Join Date: Jan 2011
Posts: 1
 
Device(s):
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi,
Did you end up solving this problem? Can you post a link to the solution?
gtx is offline  
Reply With Quote
Reply

Bookmarks

Tags
encryption aes android java


Go Back   Android Forums > Android Development > Application Development > Developer 101 User CP
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
File encryption GGROWER Android Applications 2 March 15th, 2011 12:39 PM
Support WPA/WPA2 Encryption Bug? RMOP T-Mobile MyTouch 4G 0 November 25th, 2010 06:39 PM
The best (most credible) encryption app ? pacman10 HTC Desire 0 September 17th, 2010 11:59 AM
Encryption app? zhill29 Android Applications 0 May 10th, 2010 09:40 PM
128-bit encryption PhantomTrace T-Mobile G1 1 October 9th, 2008 06:47 PM



All times are GMT -5. The time now is 08:27 PM.
Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.
Custom vBulletin Skins by: Relivo