globus_connect_gridftp_server  15.91
/build/globus-connect-gridftp-server-15.91/globus_i_gfs_log.h
1 /*
2  * Copyright The University of Chicago
3  *
4  * All Rights Reserved.
5  */
6 
7 #ifndef GLOBUS_I_GFS_LOG_H
8 #define GLOBUS_I_GFS_LOG_H
9 
10 void
11 globus_i_gfs_log_open(void);
12 
13 void
14 globus_i_gfs_log_enable_audit(void);
15 
16 void
17 globus_i_gfs_log_usage_stats_init(void);
18 
19 void
20 globus_i_gfs_log_close(void);
21 
22 typedef enum globus_gfs_log_event_type_e
23 {
24  GLOBUS_GFS_LOG_EVENT_START = 1,
25  GLOBUS_GFS_LOG_EVENT_END,
26  GLOBUS_GFS_LOG_EVENT_MESSAGE,
27  GLOBUS_GFS_LOG_EVENT_ERROR
28 } globus_gfs_log_event_type_t;
29 
30 
31 void
32 globus_i_gfs_log_tr(
33  char * msg,
34  char from,
35  char to);
36 
37 void
38 globus_gfs_log_exit_message(
39  const char * format,
40  ...);
41 
42 void
43 globus_gfs_log_exit_result(
44  const char * lead,
45  globus_result_t result);
46 
47 void
48 globus_gfs_log_event(
49  globus_gfs_log_type_t type,
50  globus_gfs_log_event_type_t event_type,
51  const char * event_name,
52  globus_result_t result,
53  const char * format,
54  ...);
55 
56 void
57 globus_i_gfs_log_transfer(
58  int stripe_count,
59  int stream_count,
60  struct timeval * start_gtd_time,
61  struct timeval * end_gtd_time,
62  char * dest_ip,
63  globus_size_t blksize,
64  globus_size_t tcp_bs,
65  const char * fname,
66  globus_off_t nbytes,
67  int code,
68  char * volume,
69  char * type,
70  char * username,
71  char * retrans,
72  char * taskid);
73 
74 char *
75 globus_i_gfs_log_create_transfer_event_msg(
76  int stripe_count,
77  int stream_count,
78  char * dest_ip,
79  globus_size_t blksize,
80  globus_size_t tcp_bs,
81  const char * fname,
82  globus_off_t nbytes,
83  char * type,
84  char * username,
85  char * retrans,
86  char * taskid);
87 
88 void
89 globus_i_gfs_log_usage_stats(
90  struct timeval * start_gtd_time,
91  struct timeval * end_gtd_time,
92  int stripe_count,
93  int stream_count,
94  globus_size_t blksize,
95  globus_size_t tcp_bs,
96  globus_off_t nbytes,
97  int code,
98  char * type,
99  char * filename,
100  char * dataip,
101  char * clientip,
102  char * username,
103  char * userdn,
104  char * app,
105  char * appver,
106  char * scheme,
107  char * dsi);
108 
109 void
110 globus_i_gfs_log_audit_session(
111  time_t ts,
112  char * ref,
113  char * client_ip,
114  int auth,
115  char * p_user,
116  char * s_user,
117  char * root,
118  char * taskid,
119  char * epid,
120  char * userid,
121  char * ownerid);
122 
123 void
124 globus_i_gfs_log_audit_op(
125  time_t ts,
126  char * ref,
127  int op_type,
128  int cmd_type,
129  char * c_path,
130  char * s_path);
131 
132 void
133 globus_i_gfs_log_audit_op_end(
134  time_t ts,
135  char * ref,
136  int op_type,
137  int cmd_type,
138  char * c_path,
139  char * s_path,
140  char * data_ip,
141  globus_off_t nbytes,
142  char * error);
143 
144 #endif