src/vsl_fifo.h

Go to the documentation of this file.
00001 /*
00002  * Copyright 2006, Internet2
00003  * Legal conditions are in file LICENSE
00004  * (MD5 = c434f2e53b8089d8b4d0172c7ce07360).
00005  */
00006 
00007 // Don't document
00008 #ifdef ENABLE_FIFO
00009 
00010 /**
00011  * @file   vsl_ssh.h
00012  * @author Nikolaus Rath
00013  * @brief  Functions for SSH handshake
00014  *
00015  **/
00016 
00017 #ifndef VSL_FIFO_H
00018 #define VSL_FIFO_H
00019 
00020 #include "vsl.h"
00021 #include "vsl_api.h"
00022 
00023 //! Maximum fifo path length for ssh auth
00024 #define MAX_PATH 512
00025 
00026 //! Maximum numer of cached fifo messages
00027 #define MSG_QUEUE_SIZE 64
00028 
00029 //! When to discard a fifo message (seconds)
00030 #define MSG_TIMEOUT 60
00031 
00032 
00033 /*
00034  * Prototypes
00035  */
00036 
00037 /* Client */
00038 int send_ssh_req   (vsl_sock* socket);
00039 int recv_ssh_res   (vsl_sock* socket, const char* path);
00040 int fork_ssh       (vsl_sock* socket, const char* user,
00041                     const char* host, const char* fifo);
00042 int send_key_ssh   (vsl_sock* socket, const char *key);
00043 int close_ssh      (vsl_sock* socket);
00044 int ssh_send_res   (vsl_sock* socket, const char* phrase);
00045 int ssh_recv_cha   (vsl_sock* socket, const char* phrase);
00046 
00047 
00048 /* Server */
00049 int recv_ssh_req   (vsl_sock* socket);
00050 int send_ssh_res   (vsl_sock* socket, const char* path);
00051 int open_fifo      (vsl_sock* socket, const char *path);
00052 int recv_key_ssh   (vsl_sock* socket);
00053 int close_fifo     (vsl_sock* socket);
00054 int ssh_send_cha   (vsl_sock* socket, const char* phrase);
00055 int ssh_recv_res   (vsl_sock* socket, const char* phrase);
00056 
00057 
00058 /* Init & Cleanup */
00059 int ssh_init      (void);
00060 int ssh_destruct  (void);
00061 
00062 
00063 /******************************************************************
00064  * The following functions belong to the API and were removed from
00065  * vsl_api.h
00066  ******************************************************************/
00067 
00068 int vsl_auth_ssh_c      (vsl_sock* socket, const char* user,
00069                          const char* host, const char *path);
00070 int vsl_auth_ssh_s      (vsl_sock* socket, const char* fifo);
00071 
00072 
00073 #endif
00074 
00075 #endif

Generated on Tue Aug 8 16:07:19 2006 for VFER by  doxygen 1.4.7