• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Share and store RSA - public key in java server and vice versa
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Share and store RSA - public key in java server and vice versa


  • Subject: Re: Share and store RSA - public key in java server and vice versa
  • From: Jens Alfke <email@hidden>
  • Date: Tue, 13 May 2014 09:37:47 -0700

On May 13, 2014, at 22:20, Devarshi Kulshreshtha <email@hidden> wrote:

> In CyrptoExercise sample provided by apple, we have a wrapper class: SecKeyWrapper.

First, I think CryptoExercise is out of date. It’s not included in Xcode 5.1’s doc set. I found it on Apple’s website, but it looks like it was last updated for iOS 3, and it has a bunch of obsolete workarounds for running in the simulator (a long time ago the Keychain APIs were different in the device and simulator environments.)

> Shall I use below code to create and send an encoded string to server:

> 1. SecKeyWrapper *keyWrapper = [SecKeyWrapper sharedWrapper];
> 2. NSData *publicKeyData = [keyWrapper getPublicKeyBits];

It’s sample code, not a black box, so you can look at what it does yourself. The two lines you gave aren’t going to do anything by themselves — getPublicKeyBits just reads an already-existing public key out of the Keychain and encodes it. You have to generate the key first.

—Jens

PS: This discussion really belongs on the apple_cdsa list, which is for crypto/security discussions. Unfortunately Apple’s engineers never help out on that list (unlike on xcode-users or macnetworkprog), but there are some other fairly knowledgeable people there.
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


  • Follow-Ups:
    • Re: Share and store RSA - public key in java server and vice versa
      • From: Devarshi Kulshreshtha <email@hidden>
References: 
 >Share and store RSA - public key in java server and vice versa (From: Devarshi Kulshreshtha <email@hidden>)
 >Re: Share and store RSA - public key in java server and vice versa (From: ChanMaxthon <email@hidden>)
 >Re: Share and store RSA - public key in java server and vice versa (From: Devarshi Kulshreshtha <email@hidden>)
 >Re: Share and store RSA - public key in java server and vice versa (From: Maxthon Chan <email@hidden>)

  • Prev by Date: Re: Share and store RSA - public key in java server and vice versa
  • Next by Date: Re: Share and store RSA - public key in java server and vice versa
  • Previous by thread: Re: Share and store RSA - public key in java server and vice versa
  • Next by thread: Re: Share and store RSA - public key in java server and vice versa
  • Index(es):
    • Date
    • Thread