Fix perf_crypto_rsa.c after various changes
[oweals/gnunet.git] / src / util / test_socks.c
index 5ca086ee18a15fceaead8f3558845f5a206c8f87..7f1140720e1dafc2639405f40c7636fd66adc5aa 100644 (file)
@@ -1,6 +1,6 @@
 /*
      This file is part of GNUnet.
-     Copyright (C) 2009 Christian Grothoff Jeff Burdges, and other contributing authors
+     Copyright (C) 2015 GNUnet e.V.
 
      GNUnet is free software; you can redistribute it and/or modify
      it under the terms of the GNU General Public License as published
@@ -99,7 +99,7 @@ recv_bounce (void *cls, const struct GNUNET_MessageHeader *got)
   struct GNUNET_MessageHeader msg;
 
   GNUNET_assert (got != NULL);  /* timeout */
-  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 
+  GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
              "Receiving bounce, checking content\n");
   msg.type = htons (MY_TYPE);
   msg.size = htons (sizeof (struct GNUNET_MessageHeader));
@@ -126,7 +126,7 @@ make_msg (void *cls, size_t size, void *buf)
 
 
 static void
-task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
+task (void *cls)
 {
   struct sockaddr_in sa;
   struct sockaddr *sap[2];
@@ -183,16 +183,15 @@ main (int argc, char *argv[])
 
   pid_t pid = fork();
   GNUNET_assert (pid >= 0);
-  if (pid == 0) 
+  if (pid == 0)
   {
     execlp ("ssh",
-           "ssh",
-           "-D", 
-           socksport,
-           "127.0.0.1",
-           "-N",
-           NULL);
-    perror ("execlp (\"ssh\",\"ssh\",\"-D\",\"1081\",\"127.0.0.1\",\"-N\") ");
+            "ssh","-D",socksport,
+            "-o","BatchMode yes",
+            "-o","UserKnownHostsFile /tmp/gnunet_test_socks_ssh_garbage",
+            "-o","StrictHostKeyChecking no",
+            "127.0.0.1","-N",(char*)NULL);
+    perror ("execlp (\"ssh\",\"ssh\",...,\"-D\",\"1081\",\"127.0.0.1\",\"-N\") ");
     printf (""
 "Please ensure you have ssh installed and have sshd installed and running :\n"
 "\tsudo apt-get install openssh-client openssh-server\n"