Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 9 additions & 3 deletions frigate/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,17 +1,23 @@
# Unfortunately, no version of Ubuntu > 18.04 is supported. This is because we use
# Semi-Honest-BMR for executing the generated circuit, which does not compile on Ubuntu > 18.04.
# See: https://github.com/cryptobiu/Semi-Honest-BMR/issues/2

FROM ubuntu:18.04
WORKDIR /root
RUN apt-get update && apt-get install -y \
g++ \
git \
flex \
make \
python \
python3 \
vim \
wget
ADD source/ /root/source

ADD README.md .
COPY source/frigate.vim /root/source/frigate.vim
ADD install.sh .

RUN ["bash", "install.sh"]

ADD source/ /root/frigaterelease/src/tests
CMD ["/bin/bash"]

12 changes: 6 additions & 6 deletions frigate/README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# Frigate

[Frigate](https://bitbucket.org/bmood/frigaterelease). is a circuit compiler that consumes a novel C-like language and produces a custom Boolean circuit representation for any number of inputs. The fraework emphasizes its use of good software engineering techniques, including a test suite and a focus on modularity and extensibility. The circuit format minimizes file size and the framewor includes an interpreter to efficiently interface between garbled circuits and other applications.
[Frigate](https://bitbucket.org/bmood/frigaterelease) is a circuit compiler that consumes a novel C-like language and produces a custom Boolean circuit representation for any number of inputs. The framework emphasizes its use of good software engineering techniques, including a test suite and a focus on modularity and extensibility. The circuit format minimizes file size and the framework includes an interpreter to efficiently interface between garbled circuits and other applications.

Frigate's type system is simple, with three native types: signed and unsigned integers of arbitrary size and structs. Frigate supports arrays within structs only.aThe compiler provides useful errors and there is documentation of interpreter options and a language desription.
Frigate's type system is simple, with three native types: signed and unsigned integers of arbitrary size and structs. Frigate supports arrays only within structs. The compiler provides useful errors and there is documentation of interpreter options and a language desription.

Frigate was developed by Benjamin Mood, Debayan Gupta, Henry Carter, Kevin R. B. Butler, and Patrick Traynor.

Our recommendation: Frigate provides an expressive C-like language for fast circuit generation and is a good way to estimate circuit size for a given computaion. However, we note that linking Frigate to an implementaiton wil require additional work by the user.
Our recommendation: Frigate provides an expressive C-like language for fast circuit generation and is a good way to estimate circuit size for a given computaion. However, we note that linking Frigate to an implementation will require additional work by the user.

## Docker setup
Create a Docker image. This will take a moment. You only have to do this once.
Expand All @@ -21,12 +21,12 @@ $ docker run -it --rm frigate

## Architecture
Frigate is a circuit compiler. Compiling the code provides an executable that
converts `.wir` files to circuits, in a special compressed frigate format. There
converts `.wir` files to circuits in a special compressed frigate format. There
is also an option to produce output in other formats (e.g. gate by gate).

Since Frigate does not have a way to evaluate these circuits we have also
included in the docker the BMR implementation developed by Bar-Ilan Cryptography
Research Group which can be used to securely evaluate circuits.
included the BMR implementation developed by Bar-Ilan Cryptography
Research Group in the Docker container, which can be used to securely evaluate circuits.
The implementation is available [on Github](https://github.com/cryptobiu/Semi-Honest-BMR).
It is based on the paper "[Optimizing Semi-Homest Secure Multiparty Computation
for the Internet](https://eprint.iacr.org/2016/1066.pdf)" by Aner Ben-Afraim, Yehuda Lindell and Eran Omri.
Expand Down
26 changes: 15 additions & 11 deletions frigate/install.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,20 @@
set -ex

# install bison dependencies
wget http://ftp.br.debian.org/debian/pool/main/b/bison/libbison-dev_3.6.3+dfsg-1_amd64.deb
dpkg -i libbison-dev_3.6.3+dfsg-1_amd64.deb

wget http://ftp.br.debian.org/debian/pool/main/b/bison/bison_3.6.3+dfsg-1_amd64.deb
dpkg -i bison_3.6.3+dfsg-1_amd64.deb

rm libbison-dev_3.6.3+dfsg-1_amd64.deb
rm bison_3.6.3+dfsg-1_amd64.deb
# install bison dependencies
#wget http://ftp.br.debian.org/debian/pool/main/b/bison/libbison-dev_3.6.3+dfsg-1_amd64.deb
#dpkg -i libbison-dev_3.6.3+dfsg-1_amd64.deb
#
#wget http://ftp.br.debian.org/debian/pool/main/b/bison/bison_3.6.3+dfsg-1_amd64.deb
#dpkg -i bison_3.6.3+dfsg-1_amd64.deb
#
#rm libbison-dev_3.6.3+dfsg-1_amd64.deb
#rm bison_3.6.3+dfsg-1_amd64.deb

wget http://launchpadlibrarian.net/140087283/libbison-dev_2.7.1.dfsg-1_amd64.deb
wget http://launchpadlibrarian.net/140087282/bison_2.7.1.dfsg-1_amd64.deb
dpkg -i libbison-dev_2.7.1.dfsg-1_amd64.deb
dpkg -i bison_2.7.1.dfsg-1_amd64.deb

# install frigate
git clone https://bitbucket.org/bmood/frigaterelease.git
Expand All @@ -16,9 +23,6 @@ cd frigaterelease/src
make
cp frigate /bin/

# copy our examples
cp -r ~/source/* tests

# add a vim syntax file :)
cd
mkdir -p .vim/syntax
Expand Down