1idna_to_ascii_4i(3) libidn idna_to_ascii_4i(3)
2
3
4
6 idna_to_ascii_4i - convert Unicode domain name label to text
7
9 #include <idna.h>
10
11 int idna_to_ascii_4i(const uint32_t * in, size_t inlen, char * out, int
12 flags);
13
15 const uint32_t * in
16 input array with unicode code points.
17
18 size_t inlen
19 length of input array with unicode code points.
20
21 char * out output zero terminated string that must have room for at
22 least 63 characters plus the terminating zero.
23
24 int flags an Idna_flags value, e.g., IDNA_ALLOW_UNASSIGNED or
25 IDNA_USE_STD3_ASCII_RULES.
26
28 The ToASCII operation takes a sequence of Unicode code points that make
29 up one label and transforms it into a sequence of code points in the
30 ASCII range (0..7F). If ToASCII succeeds, the original sequence and the
31 resulting sequence are equivalent labels.
32
33 It is important to note that the ToASCII operation can fail. ToASCII
34 fails if any step of it fails. If any step of the ToASCII operation
35 fails on any label in a domain name, that domain name MUST NOT be used
36 as an internationalized domain name. The method for deadling with this
37 failure is application-specific.
38
39 The inputs to ToASCII are a sequence of code points, the AllowUnas‐
40 signed flag, and the UseSTD3ASCIIRules flag. The output of ToASCII is
41 either a sequence of ASCII code points or a failure condition.
42
43 ToASCII never alters a sequence of code points that are all in the
44 ASCII range to begin with (although it could fail). Applying the
45 ToASCII operation multiple times has exactly the same effect as apply‐
46 ing it just once.
47
49 Returns 0 on success, or an Idna_rc error code.
50
52 Report bugs to <bug-libidn@gnu.org>.
53
55 Copyright © 2002, 2003, 2004, 2005, 2006 Simon Josefsson.
56 Permission is granted to make and distribute verbatim copies of this
57 manual provided the copyright notice and this permission notice are
58 preserved on all copies.
59
61 The full documentation for libidn is maintained as a Texinfo manual.
62 If the info and libidn programs are properly installed at your site,
63 the command
64
65 info libidn
66
67 should give you access to the complete manual.
68
69
70
71libidn 0.6.8 idna_to_ascii_4i(3)