diff options
author | Marc G. Fournier <scrappy@hub.org> | 1996-07-09 06:22:35 +0000 |
---|---|---|
committer | Marc G. Fournier <scrappy@hub.org> | 1996-07-09 06:22:35 +0000 |
commit | d31084e9d1118b25fd16580d9d8c2924b5740dff (patch) | |
tree | 3179e66307d54df9c7b966543550e601eb55e668 /src/backend/libpq/auth.h |
Postgres95 1.01 Distribution - Virgin SourcesPG95-1_01
Diffstat (limited to 'src/backend/libpq/auth.h')
-rw-r--r-- | src/backend/libpq/auth.h | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/src/backend/libpq/auth.h b/src/backend/libpq/auth.h new file mode 100644 index 00000000000..adda8dc13c4 --- /dev/null +++ b/src/backend/libpq/auth.h @@ -0,0 +1,49 @@ +/*------------------------------------------------------------------------- + * + * auth.h-- + * Definitions for network authentication routines + * + * + * Copyright (c) 1994, Regents of the University of California + * + * $Id: auth.h,v 1.1.1.1 1996/07/09 06:21:30 scrappy Exp $ + * + *------------------------------------------------------------------------- + */ +#ifndef AUTH_H +#define AUTH_H + +#include "c.h" +#include "libpq/pqcomm.h" + +/*---------------------------------------------------------------- + * Common routines and definitions + *---------------------------------------------------------------- + */ + +/* what we call "no authentication system" */ +#define UNAUTHNAME "unauth" + +/* what a frontend uses by default */ +#if !defined(KRB4) && !defined(KRB5) +#define DEFAULT_CLIENT_AUTHSVC UNAUTHNAME +#else /* KRB4 || KRB5 */ +#define DEFAULT_CLIENT_AUTHSVC "kerberos" +#endif /* KRB4 || KRB5 */ + +extern int fe_sendauth(MsgType msgtype, Port *port, char *hostname); +extern void fe_setauthsvc(char *name); +extern MsgType fe_getauthsvc(); +extern char *fe_getauthname(void); +extern int be_recvauth(MsgType msgtype, Port *port, char *username, StartupInfo* sp); +extern void be_setauthsvc(char *name); +extern int be_getauthsvc(MsgType msgtype); + +/* the value that matches any dbName value when doing + host based authentication*/ +#define ALL_DBNAME "*" + +#define PG_KRB4_VERSION "PGVER4.1" /* at most KRB_SENDAUTH_VLEN chars */ +#define PG_KRB5_VERSION "PGVER5.1" + +#endif /* AUTH_H */ |