source: TI05-delivery/trunk/src/bbftp-server-3.2.0/includes/daemon_proto.h @ 988

Subversion URL: http://proj.badc.rl.ac.uk/svn/ndg/TI05-delivery/trunk/src/bbftp-server-3.2.0/includes/daemon_proto.h@988
Revision 988, 4.5 KB checked in by spascoe, 13 years ago (diff)

Completed the authorisation API refactoring to add 2 new functions
bbftpd_private_authz_retr() and bbftpd_private_authz_store().

Line 
1/*
2 * includes/daemon_proto.h
3 * Copyright (C) 1999, 2000, 2001, 2002 IN2P3, CNRS
4 * bbftp@in2p3.fr
5 * http://doc.in2p3.fr/bbftp
6 *
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation; either version 2
10 * of the License, or any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
20 */ 
21
22/****************************************************************************
23
24 
25 
26 daemon_proto.h v 2.1.0 2001/03/21  - Header creation
27
28*****************************************************************************/
29/*
30** Prototype for utilities
31*/
32void checkfromwhere() ;
33int checkprotocol() ;
34void clean_child() ;
35void exit_clean() ;
36int bbftpd_checkendchild(int status) ;
37void strip_trailing_slashes (char *path) ;
38void free_all_var() ;
39/*
40** Prototypes for message routines
41*/
42int discardmessage(int sock,int msglen,int to) ;
43int readmessage(int sock,char *buffer,int msglen,int to) ;
44void reply(int n, char *str) ;
45int writemessage(int sock,char *buffer,int msglen,int to) ;
46/*
47** Prototypes for signal routines
48*/
49void bbftpd_sigchld(int sig) ;
50void bbftpd_sighup( int sig) ;
51void bbftpd_sigterm(int sig) ;
52int bbftpd_checkendchild(int status) ;
53int bbftpd_setsignals() ;
54int bbftpd_blockallsignals() ;
55/*
56** Prototype for sockets
57*/
58
59/*
60** Prototype for global private authentication routines
61*/
62int bbftpd_private_receive_connection(int msglen) ;
63int bbftpd_private_send(char *buffertosend, int buffertosendlength, char *logmessage) ;
64int bbftpd_private_recv(char *buffertorecv, int lengthtorecv, char *logmessage) ;
65#ifdef NDG_AUTH
66int bbftpd_private_initialise(char *logmessage);
67void bbftpd_private_sigaction(int sig);
68void bbftpd_private_atexit(void);
69#endif // NDG_AUTH
70/*
71** Prototype for user private authentication routines
72*/
73int bbftpd_private_auth(char *logmessage) ;
74#ifdef NDG_AUTH
75int bbftpd_private_init(char *logmessage);
76void bbftpd_private_finalise(void);
77void bbftpd_private_auth_finalise(void);
78int bbftpd_private_authz_control(int msgcode, int transferoption, char *path, char *logmessage);
79int bbftpd_private_authz_retr(char *path, char *logmessage);
80int bbftpd_private_authz_store(char *path, char *logmessage);
81#endif // NDG_AUTH
82/*
83** Prototype for retr routines
84*/
85int bbftpd_retrcheckfile(char *filename,char *logmessage) ;
86int bbftpd_retrlistdir(char *pattern,char **filelist,int *filelistlen,char *logmessage) ;
87int bbftpd_retrtransferfile(char *filename,int simulation,char *logmessage) ;
88
89int bbftpd_retrcheckfile_rfio(char *filename,char *logmessage) ;
90int bbftpd_retrlistdir_rfio(char *pattern,char **filelist,int *filelistlen,char *logmessage) ;
91int bbftpd_retrtransferfile_rfio(char *filename,int simulation,char *logmessage) ;
92/*
93** Prototype for store routines
94*/
95int bbftpd_storecheckoptions(char *logmessage) ;
96int bbftpd_storechmod(char *filename,int mode,char *logmessage) ;
97int bbftpd_storeclosecastfile(char *filename,char *logmessage) ;
98int bbftpd_storecreatefile(char *filename, char *logmessage) ;
99int bbftpd_storemkdir(char *dirname,char *logmessage,int recursif) ;
100int bbftpd_storerename(char *newfilename,char *oldfilename,char *logmessage) ;
101int bbftpd_storetransferfile(char *filename,int simulation,char *logmessage) ;
102int bbftpd_storeunlink(char *filename) ;
103int bbftpd_storeutime(char *filename,struct utimbuf *ftime,char *logmessage) ;
104
105int bbftpd_storecheckoptions_rfio(char *logmessage) ;
106int bbftpd_storechmod_rfio(char *filename,int mode,char *logmessage) ;
107int bbftpd_storeclosecastfile_rfio(char *filename,char *logmessage) ;
108int bbftpd_storecreatefile_rfio(char *filename, char *logmessage) ;
109int bbftpd_storemkdir_rfio(char *dirname,char *logmessage,int recursif) ;
110int bbftpd_storerename_rfio(char *newfilename,char *oldfilename,char *logmessage) ;
111int bbftpd_storetransferfile_rfio(char *filename,int simulation,char *logmessage) ;
112int bbftpd_storeunlink_rfio(char *filename) ;
113/*
114** Prototype for mains routines
115*/
116int bbftpd_cd(int sock,int msglen) ;
117int bbftpd_list(char *pattern,char *logmessage) ;
118int bbftpd_mkdir(int sock,int msglen) ;
119int bbftpd_readcontrol(int msgcode,int msglen) ;
120
Note: See TracBrowser for help on using the repository browser.