Swiftpack.co - ekscrypto/Base32 as Swift Package

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
See all packages published by ekscrypto.
ekscrypto/Base32 1.2.0
Objective-C Base32 Additions for NSString and NSData
⭐️ 54
🕓 13 weeks ago
iOS macOS watchOS tvOS
.package(url: "https://github.com/ekscrypto/Base32.git", from: "1.2.0")

Base32 Additions for Objective-C on Mac OS X and iOS

Usage

Open the Xcode project file, and drag MF_Base32Additions.m/.h into your project.

In files where you want to use Base32 encoding/decoding, simply include the header file and use one of the provided NSData or NSString additions.

Example use:

#import "MF_Base32Additions.h"

NSString *helloWorld = @"Hello World";
NSString *helloInBase32 = [helloWorld base32String];
NSString *helloDecoded = [NSString stringFromBase32String:helloInBase32];

Performance

  • Encoding: Approximately 4 to 5 times faster than using the equivalent SecTransform.
  • Decoding: Slightly faster but almost identical decoding time as equivalent SecTransform.

Requirements

  • Compile with Automatic Reference Counting
  • Compatible with Mac OSX 10.6+ and iOS 4.0+

Implementation

Licensing

  • Public Domain

GitHub

link
Stars: 54
Last commit: 1 week ago
jonrohan Something's broken? Yell at me @ptrpavlik. Praise and feedback (and money) is also welcome.

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics