Lines Matching +refs:write +refs:if +refs:changed
18 L<ossl-guide-quic-client-block(7)> page which demonstrates how to write a simple
30 it waits (blocks) until data is available to read if you attempt to read from
31 it when there is no data yet. Similarly it waits when writing if the B<SSL>
32 object is currently unable to write at the moment. This can simplify the
37 object is unable to read/write, for example updating a GUI or performing
43 error if they are currently unable to read or write respectively.
52 we want to read or write to the B<SSL> object but we are currently unable to.
56 operation that it previously attempted periodically to see if it can now
57 complete. Ideally it would only do this in the event that something has changed
62 tried last time. You cannot start something new. For example if you were
63 attempting to write the text "Hello World" and the operation failed because the
64 B<SSL> object is currently unable to write, then you cannot then attempt to
65 write some other text when you retry the operation.
70 after which the state of the B<SSL> object might have changed. We will call our
87 * Find out if we would like to write to the socket, or read from it (or
90 if (SSL_net_write_desired(ssl))
92 if (SSL_net_read_desired(ssl))
98 * whether the state of the underlying socket has changed or not.
100 if (SSL_get_event_timeout(ssl, &tv, &isinfinite) && !isinfinite)
117 * check if it did so because of activity on the file descriptors or
126 If you are familiar with how to write nonblocking applications in OpenSSL for
129 application works. With a TLS application if we try to read or write something
132 read or write to the underlying socket and the socket signalled the "retry".
138 To determine whether OpenSSL currently wants to read or write to the underlying
181 B<SSL_ERROR_WANT_WRITE> depending on whether OpenSSL wanted to read to or write
187 indicates an EOF (End-Of-File) which can occur if you attempt to read data from
189 on the stream. In this case you may still want to write data to the stream but
204 In our demo application we will write a function to handle these errors from
212 /* Temporary failure. Wait until we can read/write and try again */
251 if (SSL_get_verify_result(ssl) != X509_V_OK)
266 (except EOF), 0 in the event of EOF, or -1 if a fatal error occurred.
284 if (!SSL_set_blocking_mode(ssl, 0)) {
304 if (ctx == NULL) {
320 if (handle_io_failure(ssl, ret) == 1)
338 buffer to write with the same length. You must not attempt to send different
344 details. As in the TLS tutorials (L<ossl-guide-tls-client-block(7)>) we write
347 First, we write the entire request to the stream. We also must make sure to
355 if (handle_io_failure(ssl, 0) == 1)
357 printf("Failed to write start of HTTP request\n");
361 if (handle_io_failure(ssl, 0) == 1)
363 printf("Failed to write hostname in HTTP request\n");
368 if (handle_io_failure(ssl, 0) == 1)
370 printf("Failed to write end of HTTP request\n");
374 On a write we do not expect to see an EOF response so we treat that case in the
399 * that it is NUL terminated so we use fwrite() to write the exact
404 if (!eof)
442 if (ret < 0 && handle_io_failure(ssl, ret) == 1)
454 See L<ossl-guide-quic-client-block(7)> to read a tutorial on how to write a
455 blocking QUIC client. See L<ossl-guide-quic-multi-stream(7)> to see how to write