Carolin Latze writes:

 BIO_s_mem() return the memory BIO method function.

A memory BIO is a source/sink BIO which uses memory for its I/O. Data written to a memory BIO is stored in a BUF_MEM structure which is extended as appropriate to accommodate the stored data.

Is there anything like that in GnuTLS? Or should I rewrite it to use normal fds? (Or did I just misunderstand something? ;-))

gnutls_transport_set_pull_function() and gnutls_transport_set_push_function() install a "pull" and a "push" function for a gnutls_session_t. Basically you'd instantiate a gnutls_session_t, and attach a pull and a push function that reads and writes from a memory buffer.

It's a little bit more work, but it's a far more generic abstraction that can be used to encapsulate any kind of a source/sink encryption channel.


Attachment: pgpX3jBy3ulOg.pgp
Description: PGP signature

_______________________________________________
Help-gnutls mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-gnutls

Reply via email to