1. May 08, 2022
  2. Dec 02, 2021
  3. Nov 25, 2021
  4. Nov 20, 2021
  5. Sep 08, 2021
  6. Aug 27, 2021
    • Thomas Calderon's avatar
      Add TIRPC, OCaml >4.10 support, end-to-end integration tests (#48) · 4a19452e
      Thomas Calderon authored
      
      
      This PR addresses includes the changes provided in #46 and #47 but add the necessary logic to have the Caml Crush code compatible with TIRPC has some implementation details had changed.
      In addition, this introduces a way to perform end-to-end testing using docker-compose and should allow for better future-proofing and better backward compatibility testing.
      
      * Port the code to use safe strings only
      * build: Remove the unsafe-strings flag
      * Use tirpc as RPC implementation if available
      * Fix generated IDL patch with recent versions of camlidl as some functions
      renaming prevent spatch (coccinelle) from performing its semantic patch on
      the pkcs11_stub.c
      * Put back compatibility with OCaml < 4.02 where the Bytes module is not present.
      This is achieved through preprocessing.
      * Refresh IDL and RPC generated headers and files with more recent versions of
      camlidl and rpcgen. This can be useful for people who do not want to activate
      --with-idlgen and/or --with-rpcgen.
      * Initial integration tests using Docker
      * Implement tirpc fixes for OpenSSL
      * Propagate the binding patches to the standalone mode.
      * Add UNIX socket integration tests and more tirpc fixes
      
      Co-authored-by: default avatarSimon Chopin <simon.chopin@canonical.com>
      Co-authored-by: default avatarRyad Benadjila <ryadbenadjila@gmail.com>
      4a19452e
  7. Sep 23, 2020
  8. Sep 22, 2020
  9. Jun 17, 2020
  10. May 25, 2020
  11. May 22, 2020
  12. Nov 12, 2018
  13. Oct 19, 2017
    • Ryad Benadjila's avatar
      220edd64
    • Ryad Benadjila's avatar
      d38919f1
    • Ryad Benadjila's avatar
      Migrate the server_ssl.ml file to handle the Ocamlnet >= 4 limitation with mutual · 0f08e2a4
      Ryad Benadjila authored
      authentication ('peer_auth=required'). We use the 'verify' hook of the Netplex_config
      read_tls_config function in order to bypass the peer name verification.
      
      We also use this hook to finaly add the certificate white list verification feature
      that had not been migrated when moving from Ocamlnet < 4 to new versions (OpenSSL to
      new TLS bindings).
      
      Some code refactoring between the SSL and the LEGACY_SSL has also been performed.
      0f08e2a4
    • Ryad Benadjila's avatar
    • Ryad Benadjila's avatar
      Introduce a placeholder to handle the absence of the Bytes module introduced in · 06dc890d
      Ryad Benadjila authored
      OCaml 4.0.2, that is mainly an alias of the String module.
      Replacing String by Bytes as it was done in commit 922580275caeec15173517cef4f1914c491593d7
      introduces a regression for older versions of OCaml with compilation errors.
      
      TODO: handle the camlp4 definition in the configure.ac file to handle the conditional
      aliasing of the Bytes module depending on the OCaml version.
      For now, the project should compile in all versions by emitting warning when OCaml >= 4.0.2.
      06dc890d
    • Ryad Benadjila's avatar
      Remove OCaml warnings (mainly due to deprecated String.create and String.set to · 6498c69d
      Ryad Benadjila authored
      be replaced by Bytes.create and Bytes.set).
      6498c69d
    • Ryad Benadjila's avatar
      Add comments in switch fallthrough cases so that gcc >= 7 doesn't emmit warnings · 14f7a7e0
      Ryad Benadjila authored
      (default behaviour of recent gcc is to treat default fallthrough as a warning).
      14f7a7e0
    • Ryad Benadjila's avatar
      First attempt to provide a Mingw cross-compilation Makefile for the · 4ebbad8c
      Ryad Benadjila authored
      client library.
      
      This Makefile supposes:
      
      1) That i686-w64-mingw32 and x86_64-w64-mingw32 cross-compilation toolchain are
      both installed on the system.
      
      2) That the oncrpc-win32 includes and 32-bit/64-bit libraries have been compiled
      or downloaded in the relative paths: oncrpc-win32/win32/include for the includes,
      ../oncrpc-win32/win32/bin32/oncrpc.lib for the 32-bit oncrpc static library, and
      ../oncrpc-win32/win32/bin64/oncrpc.lib for the 64-but oncrpc static library.
      
      3) The the OpenSSL includes and 32-bit/64-bit libraries have been compiled
      or downloaded in the relative paths: ../openssl-1.1.0f/include for the includes,
      ../openssl-1.1.0f/win32/libssl.a for the 32-bit libssl static library,
      ../openssl-1.1.0f/win32/libcrypto.a for the 32-bit librcypto static library,
      ../openssl-1.1.0f/win64/libssl.a for the 64-bit libssl static library, and
      ../openssl-1.1.0f/win64/libcrypto.a for the 64-bit libcrypto static library.
      
      The Makefile 'Makefile.Win32.mingw' can be adapted to only compile and use 32-bit
      or 64-bit binaries. i686-w64-mingw32 and x86_64-w64-mingw32 and other elements
      (such as the CamlCrush client libname and socket) are hardcoded: improving and
      cleaning the Makefile to be more flexible and adapt to other systems are future
      work.
      
      Launching the standalone compilation of the client library is as easy as
      (from the CamlCrush project root folder):
      $ cd src/client-lib
      $ make -f Makefile.Win32.mingw
      
      This should produce:
      libp11client_32.dll => the 32-bit client library WITHOUT the SSL support.
      libp11client_32_ssl.dll => the 32-bit client library WITH the SSL support.
      libp11client_64.dll => the 64-bit client library WITHOUT the SSL support.
      libp11client_64_ssl.dll => the 64-bit client library WITH the SSL support.
      
      This version have been tested against:
      - The oncrpc library compiled with Mingw, see:
        https://github.com/calderonth/oncrpc-win32
      - OpenSSL in version 1.1.0f compiled with Mingw (see the NOTES.WIN file
      section "GNU C (MinGW/MSYS)" at the root folder of the project).
      
      Even though it has not been tested, the current Makefile.Win32.mingw should
      also work with static libraries for oncrpc and OpenSSL compiled with other
      Win32/Win64 compatible compilers (such as Visual C++).
      4ebbad8c
  14. Dec 15, 2016
  15. Aug 18, 2016
  16. Jul 06, 2016
  17. Jul 05, 2016