Skip to content

Implementation of "Identifying Personal DNA Methylation Profiles by Genotype Inference" by Michael Backes, Pascal Berrang, Matthias Bieg, Roland Eils, Carl Herrmann, Mathias Humbert, Irina Lehmann

Notifications You must be signed in to change notification settings

paberr/ciphermed-forests

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 

Repository files navigation

ciphermed-forests

Implementation of "Identifying Personal DNA Methylation Profiles by Genotype Inference" by Michael Backes, Pascal Berrang, Matthias Bieg, Roland Eils, Carl Herrmann, Mathias Humbert, Irina Lehmann

This code provides the means to privately evaluate a random forest classifier over the network. Our implementation builds on "Machine Learning Classification over Encrypted Data" by Raphael Bost, Raluca Ada Popa, Stephen Tu and Shafi Goldwasser (source code).

It is available under the General Public License (GPL) version 3.

Compilation & Prerequisites

As Ciphermed, Ciphermed-Forests builds on JustGarble which needs AES-NI enable on your CPU. Try less /proc/cpuinfo | grep aes to ensure these instructions are available. If not, you might have to disable all the garbled circuit-based code, or replace AES-NI calls by software AES.

Ciphermed-Forests directly uses GMP, HELib, boost, and others. You will need to install these and their own dependencies.

The C++ support of GMP is used in Ciphermed-Forests, so be sure to use the option --enable-cxx when calling the configure script.

NTL

Note that when building NTL, be sure to make GMP the underlying large integer library by calling ./configure NTL_GMP_LIP=on. For better performances, you might also want to use GF2X (downloadable here). In this case, call ./configure NTL_GMP_LIP=on NTL_GF2X_LIB=on. You will also need to change HELib's makefile (see later).

HELib

HELib is an experimental Level Homomorphic Encryption library by Shai Halevi and Victor Shoup that builds on NTL (and GMP). So be sure to have NTL installed.

We tested our code with HELib commit 3829cac. Newer versions of that library might require modifying the code.

To be properly used in Ciphermed-Forests, HELib's makefile needs to be modified: be sure to add -fPIC to CFLAGS:

CFLAGS = -g -O2 -fPIC -std=c++11

If you decided to use gf2x in NTL, to pass checks, don't forget to add -lfg2x in LDLIBS. Test programs won't compile otherwise.

Other dependencies

Ciphermed-Forests uses the following external libraries:

  • boost (for the sockets)
  • msg_pack (needed by JustGarble)
  • OpenSSL (idem)
  • Google's protocol buffers and the protoc compiler (for serialization)
  • JsonCpp (for ML models I/O)

On Ubuntu, these are available as apt packages and can be installed using the command sudo apt-get install libboost-system-dev libmsgpack-dev libssl-dev libprotoc-dev protobuf-compiler libjsoncpp-dev

About

Implementation of "Identifying Personal DNA Methylation Profiles by Genotype Inference" by Michael Backes, Pascal Berrang, Matthias Bieg, Roland Eils, Carl Herrmann, Mathias Humbert, Irina Lehmann

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 78.0%
  • C 17.2%
  • Python 2.4%
  • Objective-C 1.3%
  • Perl 0.4%
  • Makefile 0.4%
  • Protocol Buffer 0.3%