+# FIXME: should we run "diagnostics" here to test setup?
+
+
+### SERVER AUTHENTICATION SETUP
+
+# set up monkeysphere authentication
+echo "##################################################"
+echo "### configuring monkeysphere authentication..."
+mkdir -p -m 700 "$MONKEYSPHERE_SYSDATADIR"/authentication/{authorized_keys,core,sphere,tmp}
+cp "$TESTDIR"/etc/monkeysphere/monkeysphere-authentication.conf "$TEMPDIR"/
+cat <<EOF >> "$TEMPDIR"/monkeysphere-authentication.conf
+AUTHORIZED_USER_IDS="$MONKEYSPHERE_HOME/authentication/authorized_user_ids"
+EOF
+
+# setup server authentication
+echo "##################################################"
+echo "### setting up server authentication..."
+monkeysphere-authentication setup
+get_gpg_prng_arg >> "$MONKEYSPHERE_SYSDATADIR"/authentication/sphere/gpg.conf
+