Adam Pritchard  committed 0193017

Changed some mail decryptor code to better fit the server it will run on

  • Participants
  • Parent commits 67808b6

Comments (0)

Files changed (2)

File EmailResponder/FeedbackDecryptor/maildecryptor.conf

 description "Psiphon maildecryptor daemon"
 author "Psiphon Inc."
-env MAILDECRYPTOR_DIR="/opt/psiphon/maildecryptor"
+env MAILDECRYPTOR_DIR=fill-in-with-path-to-source
 # Start manually.
 start on (local-filesystems and net-device-up IFACE!=lo)

File EmailResponder/FeedbackDecryptor/

 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <>.
+if [ ! -f ./maildecryptor.conf ]; then
+  echo "This script must be run from the source directory."
+  exit 1
 echo "You must already have created the user $MAILDECRYPTOR_USER, otherwise this script will fail. See the README for details."
 echo ""
-sudo cp maildecryptor.conf /etc/init
+sed "s|fill-in-with-path-to-source|\"`pwd`\"|" maildecryptor.conf > maildecryptor.conf.configured
-sudo mkdir -p $MAILDECRYPTOR_DIR
+sudo cp maildecryptor.conf.configured /etc/init/maildecryptor.conf
-sudo chmod 0444 $MAILDECRYPTOR_DIR/*
-sudo chmod 0555 $MAILDECRYPTOR_DIR/
-sudo chmod 0400 $MAILDECRYPTOR_DIR/*.pem
-sudo chmod 0400 $MAILDECRYPTOR_DIR/*.json
+sudo chmod 0400 *.pem conf.json
 echo "Done. To start the daemon execute:"
 echo " > sudo start maildecryptor"
+echo ""