Dockerfile 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. FROM graphene
  2. ENV SGX_SDK=/opt/intel/sgxsdk/
  3. RUN apt install -y nano gdb #tmux #TODO Move tmux to run script and nano to sgx-docker script.
  4. RUN mkdir source
  5. WORKDIR source
  6. ## Setting up prereqs for decryptor - Intel SGX SSL
  7. # Just curling the tar.gz file and then running the build script didn't work as the extracted folder had a different name (dependent on the foldername which was compressed) --- I didnt want to make a new fork of the sgxssl script for that.
  8. RUN git clone https://github.com/openssl/openssl.git OpenSSL_1.1.1d && \
  9. cd OpenSSL_1.1.1d && git checkout tags/OpenSSL_1_1_1d && \
  10. cd ../ && tar -cf OpenSSL_1.1.1d.tar.gz OpenSSL_1.1.1d/
  11. #Setting up SGXSSL with the version of OpenSSL that we downloaded in the previous step.
  12. RUN git clone https://github.com/intel/intel-sgx-ssl.git && \
  13. cd intel-sgx-ssl && git checkout tags/lin_2.5_1.1.1d && \
  14. cp ../OpenSSL_1.1.1d.tar.gz ./openssl_source/ && \
  15. cd Linux && make && make install
  16. #Temp - TODO: Make the git repo public and remove these commands and retest.
  17. COPY gitcrysp-docker-deploy-key.id_rsa /root/.ssh/id_rsa
  18. COPY gitcrysp-docker-deploy-key.id_rsa.pub /root/.ssh/id_rsa.pub
  19. RUN ssh-keyscan git-crysp.uwaterloo.ca > /root/.ssh/known_hosts
  20. #Setting up protobuf definitions for exchanging LA and post-LA messages between enclaves.
  21. RUN git clone gogs@git-crysp.uwaterloo.ca:miti/dhmsgs_proto_defs.git && \
  22. cd dhmsgs_proto_defs/ && protoc --cpp_out=./ ./*.proto
  23. #Setting up the decryptor enclave itself.
  24. RUN git clone gogs@git-crysp.uwaterloo.ca:miti/Decryptor.git && \
  25. cd Decryptor/ && make
  26. #Setting up common files used in the verifier, PHP extension for LA/post-LA message processing.
  27. RUN git clone gogs@git-crysp.uwaterloo.ca:miti/commonVerifierPHPfiles.git
  28. #Setting up the verifier.
  29. RUN git clone gogs@git-crysp.uwaterloo.ca:miti/verifier.git && \
  30. cd verifier/ && make && cp verifier /root/graphene/LibOS/shim/test/native
  31. #Verifier manifest file, makefile changes - comment out JDK/python related content
  32. #WORKDIR /root/graphene/LibOS/shim/test/native
  33. #RUN make SGX=1 && make SGX_RUN=1
  34. RUN apt install -y php7.0-dev
  35. RUN git clone --recursive https://github.com/CopernicaMarketingSoftware/PHP-CPP.git && \
  36. cd PHP-CPP/ && git checkout tags/v2.1.4 && make all && \
  37. cp libphpcpp.so.* /usr/lib/ && make install
  38. RUN git clone gogs@git-crysp.uwaterloo.ca:miti/Apache_PHP_extension.git && \
  39. cd Apache_PHP_extension && \
  40. make