This file is indexed.

/usr/src/openafs-1.6.1/include/afs/afscp.h is in openafs-modules-dkms 1.6.1-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
#ifndef AFS_SRC_LIBAFSCP_AFSCP_H
#define AFS_SRC_LIBAFSCP_AFSCP_H

/* AUTORIGHTS */
#include <afs/param.h>
#include <afs/afsint.h>
#include <afs/afs_consts.h>
#include <afs/cellconfig.h>
#include <afs/dir.h>
#include <afs/afsutil.h>

#ifdef AFS_NT40_ENV
/* not included elsewhere for Windows */
#include <pthread.h>
#endif

struct afscp_server {
    afsUUID id;
    int index;
    int cell;
    int naddrs;
    afs_uint32 addrs[AFS_MAXHOSTS];
    struct rx_connection *conns[AFS_MAXHOSTS];
};

struct afscp_cell {
    int id;
    char name[MAXCELLCHARS + 1];
    struct rx_securityClass *security;
    int scindex;
    struct ubik_client *vlservers;
    int nservers;
    int srvsalloced;
    struct afscp_server **fsservers;
    void *volsbyname;
    void *volsbyid;
    char *realm;
};

struct afscp_volume {
    struct afscp_cell *cell;
    afs_uint32 id;
    int voltype;
    int nservers;
    int servers[AFS_MAXHOSTS];
    char name[AFSNAMEMAX];
    void *statcache;
    void *dircache;
};

struct afscp_venusfid {
    struct afscp_cell *cell;
    struct AFSFid fid;
};

struct afscp_dirent {
    afs_uint32 vnode;
    afs_uint32 unique;
    char name[16 + 32 * (EPP - 2)];
};

struct afscp_dirstream {
    struct afscp_venusfid fid;
    int buflen;
    char *dirbuffer;
    int hashent;
    int entry;
    int dv;
    struct afscp_dirent ret;
};

struct afscp_dircache {
    struct afscp_venusfid me;
    int buflen;
    char *dirbuffer;
    int dv;
    int nwaiters;
    pthread_mutex_t mtx;
    pthread_cond_t cv;
};

struct afscp_statent {
    struct afscp_venusfid me;
    struct AFSFetchStatus status;
    int nwaiters;
    int cleanup;
    pthread_mutex_t mtx;
    pthread_cond_t cv;
};

struct afscp_openfile {
    struct afscp_venusfid fid;
    off_t offset;
};

struct afscp_callback {
    int valid;
    const struct afscp_server *server;
    struct AFSFid fid;
    struct AFSCallBack cb;
    time_t as_of;
};

extern int afscp_errno;
int afscp_Init(const char *);
void afscp_Finalize(void);

int afscp_Insecure(void);
int afscp_AnonymousAuth(int);

void afscp_SetConfDir(char *confDir);

struct afscp_cell *afscp_DefaultCell(void);
struct afscp_cell *afscp_CellByName(const char *, const char *);
int afscp_SetDefaultRealm(const char *);
int afscp_SetDefaultCell(const char *);
struct afscp_cell *afscp_CellById(int);
int afscp_CellId(struct afscp_cell *);
void afscp_FreeAllCells(void);
void afscp_FreeAllServers(void);

struct afscp_server *afscp_ServerById(struct afscp_cell *, afsUUID *);
struct afscp_server *afscp_ServerByAddr(struct afscp_cell *, afs_uint32);
struct afscp_server *afscp_AnyServerByAddr(afs_uint32);
struct afscp_server *afscp_ServerByIndex(int);
struct rx_connection *afscp_ServerConnection(const struct afscp_server *,
					     int);

int afscp_CheckCallBack(const struct afscp_venusfid *fid,
			const struct afscp_server *server,
			afs_uint32 *expiretime);
int afscp_FindCallBack(const struct afscp_venusfid *f,
		       const struct afscp_server *server,
		       struct afscp_callback *ret);
int afscp_AddCallBack(const struct afscp_server *,
		      const struct AFSFid *,
		      const struct AFSFetchStatus *,
		      const struct AFSCallBack *, const time_t);
int afscp_RemoveCallBack(const struct afscp_server *,
			 const struct afscp_venusfid *);
int afscp_ReturnCallBacks(const struct afscp_server *);
int afscp_ReturnAllCallBacks(void);
int afscp_WaitForCallback(const struct afscp_venusfid *fid, int seconds);

/* file metastuff */
/* frees with free() */
struct afscp_venusfid *afscp_MakeFid(struct afscp_cell *, afs_uint32,
				     afs_uint32, afs_uint32);
struct afscp_venusfid *afscp_DupFid(const struct afscp_venusfid *);
void afscp_FreeFid(struct afscp_venusfid *);

struct stat;
int afscp_Stat(const struct afscp_venusfid *, struct stat *);

ssize_t afscp_PRead(const struct afscp_venusfid *, void *, size_t, off_t);
ssize_t afscp_PWrite(const struct afscp_venusfid *, const void *,
		     size_t, off_t);
/*
 * for future implementation: (?)
 * struct afscp_openfile *afscp_FidOpen(const struct afscp_venusfid *);
 * off_t afscp_FSeek(struct afscp_openfile *, off_t, int);
 * ssize_t afscp_FRead(const struct afscp_openfile *, void *, size_t);
 */

/* rpc wrappers */
int afscp_GetStatus(const struct afscp_venusfid *, struct AFSFetchStatus *);
int afscp_StoreStatus(const struct afscp_venusfid *, struct AFSStoreStatus *);
int afscp_CreateFile(const struct afscp_venusfid *, char *,
		     struct AFSStoreStatus *, struct afscp_venusfid **);
int afscp_Lock(const struct afscp_venusfid *, int locktype);
int afscp_MakeDir(const struct afscp_venusfid *, char *,
		  struct AFSStoreStatus *, struct afscp_venusfid **);
int afscp_Symlink(const struct afscp_venusfid *, char *,
		  char *, struct AFSStoreStatus *);
int afscp_RemoveFile(const struct afscp_venusfid *, char *);
int afscp_RemoveDir(const struct afscp_venusfid *, char *);
int afscp_FetchACL(const struct afscp_venusfid *, struct AFSOpaque *);
int afscp_StoreACL(const struct afscp_venusfid *, struct AFSOpaque *);

/* directory parsing stuff*/
struct afscp_dirstream *afscp_OpenDir(const struct afscp_venusfid *);
struct afscp_dirent *afscp_ReadDir(struct afscp_dirstream *);
int afscp_RewindDir(struct afscp_dirstream *);
int afscp_CloseDir(struct afscp_dirstream *);
struct afscp_venusfid *afscp_DirLookup(struct afscp_dirstream *,
				       const char *);
struct afscp_venusfid *afscp_ResolveName(const struct afscp_venusfid *,
					 const char *);
struct afscp_venusfid *afscp_ResolvePath(const char *);
struct afscp_venusfid *afscp_ResolvePathFromVol(const struct afscp_volume *,
						const char *);

/* vldb stuff */
struct afscp_volume *afscp_VolumeByName(struct afscp_cell *,
					const char *, afs_int32);
struct afscp_volume *afscp_VolumeById(struct afscp_cell *, afs_uint32);

#define DIRMODE_CELL	0
#define DIRMODE_DYNROOT	1
int afscp_SetDirMode(int);

#endif /* AFS_SRC_LIBAFSCP_AFSCP_H */