source: appstream-generator/build/girepo/gio/TlsClientConnectionIF.d @ 4841

Last change on this file since 4841 was 4841, checked in by Juanma, 2 years ago

Initial release

File size: 4.4 KB
Line 
1/*
2 * Licensed under the GNU Lesser General Public License Version 3
3 *
4 * This library is free software: you can redistribute it and/or modify
5 * it under the terms of the GNU Lesser General Public License as published by
6 * the Free Software Foundation, either version 3 of the license, or
7 * (at your option) any later version.
8 *
9 * This software is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12 * GNU Lesser General Public License for more details.
13 *
14 * You should have received a copy of the GNU Lesser General Public License
15 * along with this library.  If not, see <http://www.gnu.org/licenses/>.
16 */
17
18// generated automatically - do not change
19
20
21module gio.TlsClientConnectionIF;
22
23private import gi.gio;
24public  import gi.giotypes;
25private import gio.IOStream;
26private import gio.SocketConnectable;
27private import gio.SocketConnectableIF;
28private import glib.ConstructionException;
29private import glib.ErrorG;
30private import glib.GException;
31private import glib.ListG;
32private import gobject.ObjectG;
33
34
35/**
36 * #GTlsClientConnection is the client-side subclass of
37 * #GTlsConnection, representing a client-side TLS connection.
38 *
39 * Since: 2.28
40 */
41public interface TlsClientConnectionIF{
42        /** Get the main Gtk struct */
43        public GTlsClientConnection* getTlsClientConnectionStruct();
44
45        /** the main Gtk struct as a void* */
46        protected void* getStruct();
47
48
49        /**
50         * Copies session state from one connection to another. This is
51         * not normally needed, but may be used when the same session
52         * needs to be used between different endpoints as is required
53         * by some protocols such as FTP over TLS. @source should have
54         * already completed a handshake, and @conn should not have
55         * completed a handshake.
56         *
57         * Params:
58         *     source = a #GTlsClientConnection
59         *
60         * Since: 2.46
61         */
62        public void copySessionState(TlsClientConnectionIF source);
63
64        /**
65         * Gets the list of distinguished names of the Certificate Authorities
66         * that the server will accept certificates from. This will be set
67         * during the TLS handshake if the server requests a certificate.
68         * Otherwise, it will be %NULL.
69         *
70         * Each item in the list is a #GByteArray which contains the complete
71         * subject DN of the certificate authority.
72         *
73         * Returns: the list of
74         *     CA DNs. You should unref each element with g_byte_array_unref() and then
75         *     the free the list with g_list_free().
76         *
77         * Since: 2.28
78         */
79        public ListG getAcceptedCas();
80
81        /**
82         * Gets @conn's expected server identity
83         *
84         * Returns: a #GSocketConnectable describing the
85         *     expected server identity, or %NULL if the expected identity is not
86         *     known.
87         *
88         * Since: 2.28
89         */
90        public SocketConnectableIF getServerIdentity();
91
92        /**
93         * Gets whether @conn will use SSL 3.0 rather than the
94         * highest-supported version of TLS; see
95         * g_tls_client_connection_set_use_ssl3().
96         *
97         * Returns: whether @conn will use SSL 3.0
98         *
99         * Since: 2.28
100         */
101        public bool getUseSsl3();
102
103        /**
104         * Gets @conn's validation flags
105         *
106         * Returns: the validation flags
107         *
108         * Since: 2.28
109         */
110        public GTlsCertificateFlags getValidationFlags();
111
112        /**
113         * Sets @conn's expected server identity, which is used both to tell
114         * servers on virtual hosts which certificate to present, and also
115         * to let @conn know what name to look for in the certificate when
116         * performing %G_TLS_CERTIFICATE_BAD_IDENTITY validation, if enabled.
117         *
118         * Params:
119         *     identity = a #GSocketConnectable describing the expected server identity
120         *
121         * Since: 2.28
122         */
123        public void setServerIdentity(SocketConnectableIF identity);
124
125        /**
126         * If @use_ssl3 is %TRUE, this forces @conn to use SSL 3.0 rather than
127         * trying to properly negotiate the right version of TLS or SSL to use.
128         * This can be used when talking to servers that do not implement the
129         * fallbacks correctly and which will therefore fail to handshake with
130         * a "modern" TLS handshake attempt.
131         *
132         * Params:
133         *     useSsl3 = whether to use SSL 3.0
134         *
135         * Since: 2.28
136         */
137        public void setUseSsl3(bool useSsl3);
138
139        /**
140         * Sets @conn's validation flags, to override the default set of
141         * checks performed when validating a server certificate. By default,
142         * %G_TLS_CERTIFICATE_VALIDATE_ALL is used.
143         *
144         * Params:
145         *     flags = the #GTlsCertificateFlags to use
146         *
147         * Since: 2.28
148         */
149        public void setValidationFlags(GTlsCertificateFlags flags);
150}
Note: See TracBrowser for help on using the repository browser.