• 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: base32
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: base32


  • Subject: Re: base32
  • From: Greg Guerin <email@hidden>
  • Date: Wed, 23 Sep 2009 13:47:00 -0700

Sandro Noel wrote:

so i'm trying to find a simple cocoa base32 encode/decode function that would be as simple as this php one,.
or a good specification that i can build from.. Any pointer would be ok,

It shouldn't be that hard to write one yourself. It's pretty elementary. The basic principle is the same as converting binary to hex, except you use 5-bit slices instead of 4-bit, and you have an unconventional order of base32 digits:


"ABCDEFGHIJKLMNOPQRSTUVWXYZ234567";

'A' represents 0. 'B' represents 1, and so on. It's just a char-per- digit code.

I've occasionally used base32 in the past, but I've never seen that order of digits before. Maybe you can change the php code to use a more conventional:

"0123456789ABCDEFGHIJKLMNOPQRSTUV";

  -- GG

_______________________________________________

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


  • Prev by Date: Re: base32
  • Next by Date: Re: base32
  • Previous by thread: Re: base32
  • Next by thread: CFBundleShortVersionString mystery solved
  • Index(es):
    • Date
    • Thread