1gnutls_priority_init(3) gnutls gnutls_priority_init(3)
2
3
4
6 gnutls_priority_init - API function
7
9 #include <gnutls/gnutls.h>
10
11 int gnutls_priority_init(gnutls_priority_t * priority_cache, const char
12 * priorities, const char ** err_pos);
13
15 gnutls_priority_t * priority_cache
16 is a gnutls_prioritity_t structure.
17
18 const char * priorities
19 is a string describing priorities
20
21 const char ** err_pos
22 In case of an error this will have the position in the
23 string the error occured
24
26 Sets priorities for the ciphers, key exchange methods, macs and com‐
27 pression methods.
28
29 The priorities option allows you to specify a colon separated list of
30 the cipher priorities to enable.
31
33 Some keywords are defined to provide quick access to common prefer‐
34 ences.
35
36 "PERFORMANCE" means all the "secure" ciphersuites are enabled, limited
37 to 128 bit ciphers and sorted by terms of speed performance.
38
39 "NORMAL" means all "secure" ciphersuites. The 256-bit ciphers are
40 included as a fallback only. The ciphers are sorted by security mar‐
41 gin.
42
43 "SECURE128" means all "secure" ciphersuites with ciphers up to 128
44 bits, sorted by security margin.
45
46 "SECURE256" means all "secure" ciphersuites including the 256 bit
47 ciphers, sorted by security margin.
48
49 "EXPORT" means all ciphersuites are enabled, including the low-security
50 40 bit ciphers.
51
52 "NONE" means nothing is enabled. This disables even protocols and com‐
53 pression methods.
54
56 "!" or "-" appended with an algorithm will remove this algorithm.
57
58 "+" appended with an algorithm will add this algorithm.
59
60 Check the GnuTLS manual section "Priority strings" for detailed infor‐
61 mation.
62
64 "NONE:+VERS-TLS-ALL:+MAC-ALL:+RSA:+AES-128-CBC:+SIGN-ALL:+COMP-NULL"
65
66 "NORMAL:-ARCFOUR-128" means normal ciphers except for ARCFOUR-128.
67
68 "SECURE:-VERS-SSL3.0:+COMP-DEFLATE" means that only secure ciphers are
69 enabled, SSL3.0 is disabled, and libz compression enabled.
70
71 "NONE:+VERS-TLS-ALL:+AES-128-CBC:+RSA:+SHA1:+COMP-NULL:+SIGN-RSA-SHA1",
72
73 "NORMAL:COMPAT" is the most compatible mode.
74
76 On syntax error GNUTLS_E_INVALID_REQUEST is returned, GNUTLS_E_SUCCESS
77 on success, or an error code.
78
80 Report bugs to <bug-gnutls@gnu.org>. GnuTLS home page:
81 http://www.gnu.org/software/gnutls/ General help using GNU software:
82 http://www.gnu.org/gethelp/
83
85 Copyright © 2008 Free Software Foundation.
86 Copying and distribution of this file, with or without modification,
87 are permitted in any medium without royalty provided the copyright
88 notice and this notice are preserved.
89
91 The full documentation for gnutls is maintained as a Texinfo manual.
92 If the info and gnutls programs are properly installed at your site,
93 the command
94
95 info gnutls
96
97 should give you access to the complete manual.
98
99
100
101gnutls 2.12.6.1 gnutls_priority_init(3)