globus_connect_gridftp_server  16.5
/build/globus-connect-gridftp-server-16.5/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_close(void);
18 
19 typedef enum globus_gfs_log_event_type_e
20 {
21  GLOBUS_GFS_LOG_EVENT_START = 1,
22  GLOBUS_GFS_LOG_EVENT_END,
23  GLOBUS_GFS_LOG_EVENT_MESSAGE,
24  GLOBUS_GFS_LOG_EVENT_ERROR
25 } globus_gfs_log_event_type_t;
26 
27 
28 void
29 globus_i_gfs_log_tr(
30  char * msg,
31  char from,
32  char to);
33 
34 void
35 globus_gfs_log_exit_message(
36  const char * format,
37  ...);
38 
39 void
40 globus_gfs_log_exit_result(
41  const char * lead,
42  globus_result_t result);
43 
44 void
45 globus_gfs_log_event(
46  globus_gfs_log_type_t type,
47  globus_gfs_log_event_type_t event_type,
48  const char * event_name,
49  globus_result_t result,
50  const char * format,
51  ...);
52 
53 void
54 globus_i_gfs_log_transfer(
55  int stripe_count,
56  int stream_count,
57  struct timeval * start_gtd_time,
58  struct timeval * end_gtd_time,
59  char * dest_ip,
60  globus_size_t blksize,
61  globus_size_t tcp_bs,
62  const char * fname,
63  globus_off_t nbytes,
64  int code,
65  char * volume,
66  char * type,
67  char * username,
68  char * retrans,
69  char * taskid);
70 
71 char *
72 globus_i_gfs_log_create_transfer_event_msg(
73  int stripe_count,
74  int stream_count,
75  char * dest_ip,
76  globus_size_t blksize,
77  globus_size_t tcp_bs,
78  const char * fname,
79  globus_off_t nbytes,
80  char * type,
81  char * username,
82  char * retrans,
83  char * taskid);
84 
85 void
86 globus_i_gfs_log_audit_session(
87  time_t ts,
88  char * ref,
89  char * client_ip,
90  int auth,
91  char * p_user,
92  char * s_user,
93  char * root,
94  char * taskid,
95  char * epid,
96  char * userid,
97  char * ownerid);
98 
99 void
100 globus_i_gfs_log_audit_op(
101  time_t ts,
102  char * ref,
103  int op_type,
104  int cmd_type,
105  char * c_path,
106  char * s_path);
107 
108 void
109 globus_i_gfs_log_audit_op_end(
110  time_t ts,
111  char * ref,
112  int op_type,
113  int cmd_type,
114  char * c_path,
115  char * s_path,
116  char * data_ip,
117  globus_off_t nbytes,
118  char * error);
119 
120 #endif