Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Java > Java and JDK > Pro Java
|
Pro Java Expert level Java questions not about a specific book. Please indicate your version.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Pro Java section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old July 18th, 2006, 08:28 AM
Registered User
 
Join Date: Jul 2006
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default encrypting the xml file using asymmetric cipher

 i have to encrypt the xml file using asymmetric cyper....

 in one class , i am generating private key and public key using "RSA" algorithm..using 1024 byte initialization...
it is generating properly...

and after that in second class i am encrypting the xml file using "DESede" algorithm and i am using public key of above class..
but i am getting exceptione :

java.security.InvalidKeyException: Invalid key length: 162 bytes
        at com.sun.crypto.provider.DESedeCipher.engineGetKeyS ize(DashoA6275)
        at javax.crypto.Cipher.init(DashoA6275)
        at XmlEncryption.getEncryptedData(XmlEncryption.java: 147)
        at XmlEncryption.encryptCompleteXmlFile(XmlEncryption .java:123)
        at demoXmlEncApp.simulateBookSellersEnd(demoXmlEncApp .java:72)
        at demoXmlEncApp.main(demoXmlEncApp.java:29)

so, what is that ?

i want to use RSA algo for key generatiion and DESede for cipher initialization .

is there any site for where source code of xml file encryption using asymmetric cipher is available?

pls, help me.....







Similar Threads
Thread Thread Starter Forum Replies Last Post
Encrypting config vikingsunil ASP.NET 2.0 Professional 1 August 28th, 2008 10:53 PM
Asymmetric Encryption zaheerabbas.sk C# 2 September 5th, 2007 08:43 AM
specification string for RSA cipher chadmichael BOOK: Beginning Cryptography with Java 3 January 23rd, 2007 07:31 PM
Encrypting and Decrypting chipset VB How-To 0 July 27th, 2004 07:36 AM
querystring encrypting invitro Classic ASP Professional 1 April 5th, 2004 10:45 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.