1idn2_register_ul(3) libidn2 idn2_register_ul(3)
2
3
4
6 idn2_register_ul - API function
7
9 #include <idn2.h>
10
11 int idn2_register_ul(const char * ulabel, const char * alabel, char **
12 insertname, int flags);
13
15 const char * ulabel
16 input zero-terminated locale encoded string, or NULL.
17
18 const char * alabel
19 input zero-terminated ACE encoded string (xn--), or NULL.
20
21 char ** insertname
22 newly allocated output variable with name to register in
23 DNS.
24
25 int flags optional idn2_flags to modify behaviour.
26
28 Perform IDNA2008 register string conversion on domain label ulabel and
29 alabel, as described in section 4 of RFC 5891. Note that the input
30 ulabel is assumed to be encoded in the locale's default coding system,
31 and will be transcoded to UTF-8 and NFC normalized by this function.
32
33 It is recommended to supply both ulabel and alabel for better error
34 checking, but supplying just one of them will work. Passing in only
35 alabel is better than only ulabel. See RFC 5891 section 4 for more
36 information.
37
39 On successful conversion IDN2_OK is returned, when the given ulabel and
40 alabel does not match each other IDN2_UALABEL_MISMATCH is returned,
41 when either of the input labels are too long IDN2_TOO_BIG_LABEL is
42 returned, when alabel does does not appear to be a proper A-label
43 IDN2_INVALID_ALABEL is returned, or another error code is returned.
44
46 The full documentation for libidn2 is maintained as a Texinfo manual.
47 If the info and libidn2 programs are properly installed at your site,
48 the command
49
50 info libidn2
51
52 should give you access to the complete manual.
53
54
55
56libidn2 0.7 idn2_register_ul(3)