mirleft / libnqsb-tls

OCaml-TLS exposed to C
MIT License
23 stars 2 forks source link

There are some questions for help. #8

Open jnchzy opened 6 years ago

jnchzy commented 6 years ago

Thank you for your help! I removed tls 0.9.0 and reinstalled tls 0.8.0. The program can be compiled successfully.But I don't know how to call the libnqsb-tls library in the test directory. In the paper of “OCaml inside: a drop-in replacement for libtls”, libnqsb-tls replaced libtls, and I also don't know how to do it specificly. Could you give me an example? Thank you very much! And I also want to know where the difference between the Ocaml-tls and the libnqsb-tls projects is. In the libnqsb-tls project,tls 0.8.0 is refer to the version of ocaml-tls? Thank you very much!

jnchzy commented 6 years ago

In the test directory, why server.ocaml-tls and server.libressl, client.ocaml-tls and client.libressl are generated at the same time after making? The following figures show the test program run sucessfully? 1 2 But, I still don't understand how the test program calls the libnqsb library. What is the function of the library when the program ran successfully? Could you give me some explanation?Thank you very much!

abbysmal commented 6 years ago

Hi, Sorry for the late reply, I will give you a proper answer during the evening (Singapore time). Thank you for your patience, will come back to you in a bit.

abbysmal commented 6 years ago

Hi jnchzy, In the test directory, we build various executable linking them to the different libraries we want to compare and see if they can communicate in the most basic setting: that is establishing a connection with a successful handshake. So we build a server and a client meant to connect to eachother, linking one version to libnqsb-tls, the other to libressl's libtls. (see Makefile) This test is by no mean exhaustive but it provides a simple base on which to eventually try more things. The programs are very simple and you can consider them to be working if after connection a client to a server they both exit with a status code of 0. This is the simplest kind of example I can give of this library, another potentially interesting test would be to build libnqsb-tls on OpenBSD and trying the library in the wild, it worked two years ago against OpenBSD httpd and some other small programs using libtls.

jnchzy commented 6 years ago

There are two questions when I read the paper of “OCaml inside: a drop-in replacement for libtls”: Firstly ,how did link httpd against libnqsb-tls in place of libtls. Could you give me some explanation for doing it specificly? The following command can let libnqsb-tls replace libtls? LDPRELOAD/usr/lib/libnqsb-tls.so httpd -f /etc/httpd.conf -d startup How can I get the result? 1 Secondly,a large file (over 1GB) is transferred over HTTPS using httpd, how libtls or libnqsb-tls is used to encrypt the payload? Thank you very much!

jnchzy commented 6 years ago

And I also want to know where the difference between the Ocaml-tls and the libnqsb-tls projects is.Thank you very much!