1idn2_lookup_ul(3)                   libidn2                  idn2_lookup_ul(3)
2
3
4

NAME

6       idn2_lookup_ul - API function
7

SYNOPSIS

9       #include <idn2.h>
10
11       int idn2_lookup_ul(const char * src, char ** lookupname, int flags);
12

ARGUMENTS

14       const char * src
15                   input zero-terminated locale encoded string.
16
17       char ** lookupname
18                   newly allocated output variable with name to lookup in DNS.
19
20       int flags   optional idn2_flags to modify behaviour.
21

DESCRIPTION

23       Perform  IDNA2008 lookup string conversion on domain name  src , as de‐
24       scribed in section 5 of RFC 5891.  Note that the input is assumed to be
25       encoded  in  the locale's default coding system, and will be transcoded
26       to UTF-8 and NFC normalized by this function.
27
28       Pass IDN2_ALABEL_ROUNDTRIP in  flags to convert any input  A-labels  to
29       U-labels  and perform additional testing. This is default since version
30       2.2.  To switch this behavior off, pass IDN2_NO_ALABEL_ROUNDTRIP
31
32       Pass IDN2_TRANSITIONAL to enable Unicode TR46 transitional  processing,
33       and  IDN2_NONTRANSITIONAL  to enable Unicode TR46 non-transitional pro‐
34       cessing.
35
36       Multiple flags may be specified by binary or:ing them together, for ex‐
37       ample IDN2_ALABEL_ROUNDTRIP | IDN2_NONTRANSITIONAL.
38
39       The IDN2_NFC_INPUT in  flags is always enabled in this function.
40
41       After  version  0.11:   lookupname  may  be NULL to test lookup of  src
42       without allocating memory.
43

RETURNS

45       On successful conversion IDN2_OK is returned, if conversion from locale
46       to  UTF-8  fails then IDN2_ICONV_FAIL is returned, if the output domain
47       or  any  label  would  have  been  too  long   IDN2_TOO_BIG_DOMAIN   or
48       IDN2_TOO_BIG_LABEL is returned, or another error code is returned.
49

SINCE

51       0.1
52

SEE ALSO

54       The  full  documentation for libidn2 is maintained as a Texinfo manual.
55       If the info and libidn2 programs are properly installed at  your  site,
56       the command
57
58              info libidn2
59
60       should  give  you access to the complete manual.  As an alternative you
61       may obtain the manual from:
62
63              http://www.gnu.org/software/libidn/libidn2/manual/
64
65libidn2                              2.3.1                   idn2_lookup_ul(3)
Impressum