Browse Source

Merge branch 'master' of git-crysp.uwaterloo.ca:miti/mitigator

Miti Mazmudar 3 years ago
parent
commit
c6f342c21b
3 changed files with 5 additions and 2 deletions
  1. 3 0
      docker/Dockerfile
  2. 1 1
      docker/deploy_enclaves.sh
  3. 1 1
      run-mitigator

+ 3 - 0
docker/Dockerfile

@@ -61,6 +61,8 @@ RUN git clone https://git-crysp.uwaterloo.ca/miti/Apache_PHP_extension.git && \
 WORKDIR /root/graphene/LibOS/shim/test/apps/apache
 #Modifying the Makefile to generate the php module.
 RUN sed -i s/'LISTEN_HOST ?= 127.0.0.1'/'LISTEN_HOST ?= 0.0.0.0'/g Makefile
+RUN sed -i s/'LISTEN_PORT ?= 8001'/'LISTEN_PORT ?= 80'/g Makefile
+
 RUN sed -i 's:testdata ssldata:ssldata $(INSTALL_DIR)/modules/libphp7.so:' Makefile 
 RUN sed -i s/"'-'"/"'-' | tr '+' 'p'"/g Makefile #Fix for stdc++ to be named as a key sgx.trusted_files.stdcpp in the autogenerated manifest. 
 #Copy the PHP 7 archive (PHPCPP requires at least version 7) 
@@ -87,6 +89,7 @@ RUN echo "extension_dir=/root/graphene/LibOS/shim/test/apps/apache/install/modul
 RUN cp /root/source/Apache_PHP_extension/*.php install/htdocs
 #Fix the configuration file for Apache
 RUN printf '\nAcceptFilter http none\n<IfModule mime_module>\n    AddType application/x-httpd-php .php\n</IfModule>\n' >> install/conf/httpd.conf 
+RUN sed -i 's/DirectoryIndex.*/DirectoryIndex index.php index.html/g' install/conf/httpd.conf
 
 WORKDIR /root
 COPY deploy_enclaves.sh ./

+ 1 - 1
docker/deploy_enclaves.sh

@@ -1,6 +1,6 @@
 #!/bin/bash
 #To exit a tmux session, use Ctrl+B and then press D. 
-#To enter a tmux session, use tmux at -t <session_name> where session_name is decryptor, verifier or phpext.
+#To enter a tmux session, use tmux at -t <session_name> where session_name is decryptor, verifier or php_server.
 #List existing sessions by pressing tmux ls.
 
 cd ~/graphene && make SGX=1 sgx-tokens

+ 1 - 1
run-mitigator

@@ -1,2 +1,2 @@
 #!/bin/bash
-docker run --device /dev/isgx --device /dev/gsgx --name mitigator --rm -p 8001:8001 -dt mitigator bash -c "start-aesmd && exec bash"
+docker run --device /dev/isgx --device /dev/gsgx --name mitigator --rm -p 80:80 -dt mitigator bash -c "start-aesmd && exec bash"