Lines Matching +full:multi +full:- +full:function

6 demos/guide/quic-multi-stream.c
12 ossl-guide-quic-multi-stream
13 - OpenSSL Guide: Writing a simple multi-stream QUIC client
18 QUIC multi-stream application. It assumes a basic understanding of QUIC and how
19 it is used in OpenSSL. See L<ossl-guide-quic-introduction(7)> and
20 L<ossl-guide-quic-client-block(7)>.
24 In a QUIC multi-stream application we separate out the concepts of a QUIC
48 (see L<ossl-guide-libraries-introduction(7)>). In particular most OpenSSL
64 (by default) the default stream will be a client-initiated bi-directional
67 stream (whether it is bi-directional or uni-directional).
72 It is recommended that new multi-stream applications should not use a default
82 bi-directional or a uni-directional stream.
84 The function returns a new QUIC stream B<SSL> object for sending and receiving
87 The peer may also initiate streams. An application can use the function
102 Any stream may be bi-directional or uni-directional. If it is uni-directional
103 then the initiator can write to it but not read from it, and vice-versa for the
142 the connection via a call to L<SSL_get0_connection(3)>. Multi-threaded
146 you must be careful to not to call any function that uses the connection object
149 L<SSL_get_accept_stream_queue_len(3)> which are thread-safe).
152 B<SSL> connection object. Therefore certain function calls that are relevant to
153 the connection as a whole will not work on a stream. For example the function
158 =head1 SIMPLE MULTI-STREAM QUIC CLIENT EXAMPLE
161 a simple multi-stream QUIC client application which connects to a server, send
163 over QUIC is non-standard and will not be supported by real world servers. This
167 covered on the L<ossl-guide-quic-client-block(7)> page and we assume that you
169 blocking QUIC client and the multi-stream QUIC client. Although the example code
171 See L<ossl-guide-quic-client-non-block(7)> for more information about writing a
174 The complete source code for this example multi-stream QUIC client is available
176 C<quic-multi-stream.c>. It is also available online at
177 L<https://github.com/openssl/openssl/blob/master/demos/guide/quic-multi-stream.c>.
182 to disable the default stream for our multi-stream client. To do this we call
183 the L<SSL_set_default_stream_mode(3)> function and pass in our connection B<SSL>
199 first of these will be a bi-directional stream and the second one will be a
200 uni-directional one:
204 * bi-directional, and the second will be uni-directional.
217 avoid repeating too much code we write a simple helper function to send an HTTP
237 appropriate HTTP requests. We can then call our helper function above to send
259 In this example B<stream1> is a bi-directional stream so, once we have sent the
261 we just repeatedly call L<SSL_read_ex(3)> until that function fails (indicating
275 * number of bytes that we read. The data could be non-printable or
291 function to find out more details. Since this is a blocking application this
297 The L<SSL_get_stream_read_state(3)> function can be used to distinguish between
316 * reset - or some failure occurred on the underlying connection.
343 Our B<stream2> object that we created above was a uni-directional stream so it
354 * containing the data requested in our uni-directional stream. This doesn't
389 L<ossl-guide-introduction(7)>, L<ossl-guide-libraries-introduction(7)>,
390 L<ossl-guide-libssl-introduction(7)> L<ossl-guide-quic-introduction(7)>,
391 L<ossl-guide-quic-client-block(7)>