Latest 1.35
Homepage https://github.com/chrisballinger/libidn-framework
License LGPL
Platforms ios 8.0, osx 10.9, tvos 9.0, watchos 2.0, requires ARC
Authors ,

libidn-framework

CI Status
Version
License
Platform

From GNU IDN Library – Libidn

GNU Libidn is a fully documented implementation of the Stringprep, Punycode and IDNA specifications. Libidn’s purpose is to encode and decode internationalized domain names. The native C, C# and Java libraries are available under the GNU Lesser General Public License version 2.1 or later.

The library contains a generic Stringprep implementation. Profiles for Nameprep, iSCSI, SASL, XMPP and Kerberos V5 are included. Punycode and ASCII Compatible Encoding (ACE) via IDNA are supported. A mechanism to define Top-Level Domain (TLD) specific validation tables, and to compare strings against those tables, is included. Default tables for some TLDs are also included.

This podspec uses a fork of libidn to fix a few minor issues related to CocoaPods integration.

Usage

To run the example project, clone the repo, and run pod install from the Example directory first.

Installation

libidn is available through CocoaPods. To install
it, simply add the following line to your Podfile:

pod "libidn"

Maintenance Notes

Upgrading libidn:

  • Download latest release 1.x from https://ftp.gnu.org/gnu/libidn. The 2.x series does not include stringprep, which is needed by this wrapper library.
  • Copy over updated files that are in /lib folder
  • Comment out #include <config.h>"
  • Replace # include <idn-int.h> and #include "unistr.h" with #include <stdint.h>

Authors

License

libidn is available under the LGPL license, but the podspec and example code in this repo is MIT. See LICENSE for more details.

Latest podspec

{
    "name": "libidn",
    "version": "1.35",
    "summary": "Encode/decode i18n domains using Stringprep, Punycode and IDNA.",
    "description": "GNU Libidn is a fully documented implementation of the Stringprep, Punycode and IDNA specifications. Libidn's purpose is to encode and decode internationalized domain names. The native C, C# and Java libraries are available under the GNU Lesser General Public License version 2.1 or later.nnThe library contains a generic Stringprep implementation. Profiles for Nameprep, iSCSI, SASL, XMPP and Kerberos V5 are included. Punycode and ASCII Compatible Encoding (ACE) via IDNA are supported. A mechanism to define Top-Level Domain (TLD) specific validation tables, and to compare strings against those tables, is included. Default tables for some TLDs are also included.nnThe Stringprep API consists of two main functions, one for converting data from the system's native representation into UTF-8, and one function to perform the Stringprep processing. Adding a new Stringprep profile for your application within the API is straightforward. The Punycode API consists of one encoding function and one decoding function. The IDNA API consists of the ToASCII and ToUnicode functions, as well as an high-level interface for converting entire domain names to and from the ACE encoded form. The TLD API consists of one set of functions to extract the TLD name from a domain string, one set of functions to locate the proper TLD table to use based on the TLD name, and core functions to validate a string against a TLD table, and some utility wrappers to perform all the steps in one call.nnThe library is used by, e.g., GNU SASL and Shishi to process user names and passwords. Libidn can be built into GNU Libc to enable a new system-wide getaddrinfo flag for IDN processing.nnLibidn is developed for the GNU/Linux system, but runs on over 20 Unix platforms (including Solaris, IRIX, AIX, and Tru64) and Windows. The library is written in C and (parts of) the API is also accessible from C++, Emacs Lisp, Python and Java. A native Java and C# port is included.nnAlso included is a command line tool, several self tests, code examples, and more, all licensed under the GNU General Public License version 3.0 or later.",
    "homepage": "https://github.com/chrisballinger/libidn-framework",
    "license": {
        "type": "LGPL",
        "file": "LICENSE"
    },
    "authors": {
        "Simon Josefsson": "[email protected]",
        "Chris Ballinger (podspec maintainer)": "[email protected]"
    },
    "social_media_url": "https://twitter.com/jas4711",
    "source": {
        "git": "https://github.com/chrisballinger/libidn-framework.git",
        "tag": "1.35"
    },
    "platforms": {
        "ios": "8.0",
        "osx": "10.9",
        "tvos": "9.0",
        "watchos": "2.0"
    },
    "requires_arc": true,
    "source_files": [
        "Framework/*.{m,h}",
        "lib/*.{h,c}"
    ],
    "public_header_files": "Framework/*.h",
    "libraries": "iconv"
}

Pin It on Pinterest

Share This