www.pudn.com > DTMS.rar > PASS.H
/*#define _XOPEN_SOURCE #include#include #include #include */ #define PASWDFILE "passwd" /* #define USABLEUIDFILE "usableuid"*/ #define SEPR ':' #define SALT "dt" /*#define newline '\n'*/ #define UIDLEN 4 /*#define MAXLINE 1024*/ #define HDR_OFF 0 /*int PASFD=-1;*/ struct password { char *user; char *password; /*int uid; time_t regtime;*/ }; int UsrStore(char *psd,char *usr); int GetUid(); int _pas_Store(char *buf,int paslen); int TestPsd(char *psd,char *usr); struct password *_pas_GetOneRecd(char *buf,struct password *pp); char *_pas_GetOneLine(char *buf); void _pas_SetWorkPoint(off_t offset);