libidn2  2.3.4
About: GNU Libidn2 is an implementation of the IDNA2008, Punycode and TR46 specifications used for (Unicode) internationalized domain names.
  Fossies Dox: libidn2-2.3.4.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

Loading...
Searching...
No Matches
libidn2 Documentation

Some Fossies usage hints in advance:

  1. To see the Doxygen generated documentation please click on one of the items in the steelblue colored "quick index" bar above or use the side panel at the left which displays a hierarchical tree-like index structure and is adjustable in width.
  2. If you want to search for something by keyword rather than browse for it you can use the client side search facility (using Javascript and DHTML) that provides live searching, i.e. the search results are presented and adapted as you type in the Search input field at the top right.
  3. Doxygen doesn't incorporate all member files but just a definable subset (basically the main project source code files that are written in a supported language). So to search and browse all member files you may visit the Fossies libidn2-2.3.4.tar.gz contents page and use the Fossies standard member browsing features (also with source code highlighting and additionally with optional code folding).
README.md

Libidn2 README -- Introduction information

Libidn2 is a free software implementation of IDNA2008, Punycode and Unicode TR46. Its purpose is to encode and decode internationalized domain names.

For technical reference, see:

The library contains functionality to convert internationalized domain names to and from ASCII Compatible Encoding (ACE).

The API consists of two main functions, idn2_to_ascii_8z for converting data from UTF-8 to ASCII Compatible Encoding (ACE), and idn2_to_unicode_8z8z to convert ACE names into UTF-8 format. There are several variations of these main functions, which accept UTF-32, or input in the local system encoding. All functions assume zero-terminated strings.

This library is backwards (API) compatible with the libidn library. Replacing the idna.h header with idn2.h into a program is sufficient to switch the application from IDNA2003 to IDNA2008 as supported by this library.

Libidn2 is believed to be a complete IDNA2008 and TR46 implementation, it contains an extensive test-suite, and is included in the continuous fuzzing project OSS-Fuzz.

You can check the current test code coverage here and the current fuzzing code coverage here.

License

The installed C library libidn2 is dual-licensed under LGPLv3+|GPLv2+, while the rest of the package is GPLv3+. See the file COPYING for detailed information.

Online docs

API reference

Manual

Obtaining the source

Software releases of libidn2 can be downloaded from https://ftp.gnu.org/gnu/libidn/ and ftp://ftp.gnu.org/gnu/libidn/

Development of libidn2 is organized through GitLab website, and there is an issue tracker for reporting bugs.

Building & Dependencies

To build Libidn2 you will need a POSIX shell, the Unix "make" tool, and a C compiler.

When building from a released .tar. archive, after unpacking you build the package like this:

./configure
make
make check

The Libidn2 library may use GNU libunistring for Unicode processing and GNU libiconv for character set conversion. It is recommended to install them before building and installing libidn2. See the following links for more information on these packages:

The iconv dependency is optional -- it is required for the functions involving locale to UTF8 conversions -- but is recommended.

When the recommended libunistring is not available, libidn2 uses internal replacement functionality which increases the size of the library. To use the internal libunistring-replacement rather than the system libunistring (even when deemed to be sufficient) you may use:

./configure --with-included-libunistring

Contributing

See the contributing document.

Estimating code coverage

Dependencies:

  • lcov (for code coverage)

To test the code coverage of the test suite use the following:

./configure --enable-code-coverage
make && make check && make code-coverage-capture

The current coverage report can be found here.

Fuzzing

Libidn2 is being continuously fuzzed by OSS-Fuzz.

Of course you can do local fuzzing on your own, see fuzz/README.md for instructions.

The code coverage of our fuzzers can be found here.