Header And Logo

PostgreSQL
| The world's most advanced open source database.

Data Structures | Defines | Typedefs | Variables

pqcomm.h File Reference

#include <sys/socket.h>
#include <netdb.h>
#include <netinet/in.h>
Include dependency graph for pqcomm.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  sockaddr_storage
struct  SockAddr
struct  StartupPacket
struct  CancelRequestPacket

Defines

#define ss_family   ss_stuff.sa.sa_family
#define UNIXSOCK_PATH(path, port, sockdir)
#define UNIXSOCK_PATH_BUFLEN   sizeof(((struct sockaddr_un *) NULL)->sun_path)
#define PG_PROTOCOL_MAJOR(v)   ((v) >> 16)
#define PG_PROTOCOL_MINOR(v)   ((v) & 0x0000ffff)
#define PG_PROTOCOL(m, n)   (((m) << 16) | (n))
#define PG_PROTOCOL_EARLIEST   PG_PROTOCOL(1,0)
#define PG_PROTOCOL_LATEST   PG_PROTOCOL(3,0)
#define SM_DATABASE   64
#define SM_USER   32
#define SM_DATABASE_USER   (SM_DATABASE+SM_USER+1)
#define SM_OPTIONS   64
#define SM_UNUSED   64
#define SM_TTY   64
#define MAX_STARTUP_PACKET_LENGTH   10000
#define AUTH_REQ_OK   0
#define AUTH_REQ_KRB4   1
#define AUTH_REQ_KRB5   2
#define AUTH_REQ_PASSWORD   3
#define AUTH_REQ_CRYPT   4
#define AUTH_REQ_MD5   5
#define AUTH_REQ_SCM_CREDS   6
#define AUTH_REQ_GSS   7
#define AUTH_REQ_GSS_CONT   8
#define AUTH_REQ_SSPI   9
#define CANCEL_REQUEST_CODE   PG_PROTOCOL(1234,5678)
#define NEGOTIATE_SSL_CODE   PG_PROTOCOL(1234,5679)

Typedefs

typedef uint32 ProtocolVersion
typedef ProtocolVersion MsgType
typedef uint32 PacketLen
typedef struct StartupPacket StartupPacket
typedef uint32 AuthRequest
typedef struct CancelRequestPacket CancelRequestPacket

Variables

bool Db_user_namespace

Define Documentation

#define AUTH_REQ_CRYPT   4

Definition at line 169 of file pqcomm.h.

Referenced by pg_fe_sendauth().

#define AUTH_REQ_GSS   7

Definition at line 172 of file pqcomm.h.

Referenced by ClientAuthentication(), and pg_fe_sendauth().

#define AUTH_REQ_GSS_CONT   8

Definition at line 173 of file pqcomm.h.

Referenced by pg_fe_sendauth(), PQconnectPoll(), and sendAuthRequest().

#define AUTH_REQ_KRB4   1

Definition at line 166 of file pqcomm.h.

Referenced by pg_fe_sendauth().

#define AUTH_REQ_KRB5   2

Definition at line 167 of file pqcomm.h.

Referenced by ClientAuthentication(), and pg_fe_sendauth().

#define AUTH_REQ_MD5   5
#define AUTH_REQ_OK   0

Definition at line 165 of file pqcomm.h.

Referenced by ClientAuthentication(), pg_fe_sendauth(), PQconnectPoll(), and sendAuthRequest().

#define AUTH_REQ_PASSWORD   3
#define AUTH_REQ_SCM_CREDS   6

Definition at line 171 of file pqcomm.h.

Referenced by pg_fe_sendauth().

#define AUTH_REQ_SSPI   9

Definition at line 174 of file pqcomm.h.

Referenced by ClientAuthentication(), and pg_fe_sendauth().

#define CANCEL_REQUEST_CODE   PG_PROTOCOL(1234,5678)

Definition at line 187 of file pqcomm.h.

Referenced by internal_cancel(), and ProcessStartupPacket().

#define MAX_STARTUP_PACKET_LENGTH   10000

Definition at line 160 of file pqcomm.h.

Referenced by ProcessStartupPacket().

#define NEGOTIATE_SSL_CODE   PG_PROTOCOL(1234,5679)

Definition at line 202 of file pqcomm.h.

Referenced by PQconnectPoll(), and ProcessStartupPacket().

#define PG_PROTOCOL (   m,
  n 
)    (((m) << 16) | (n))

Definition at line 106 of file pqcomm.h.

Referenced by connectDBStart(), and PQconnectPoll().

#define PG_PROTOCOL_EARLIEST   PG_PROTOCOL(1,0)

Definition at line 110 of file pqcomm.h.

Referenced by ProcessStartupPacket().

#define PG_PROTOCOL_LATEST   PG_PROTOCOL(3,0)

Definition at line 111 of file pqcomm.h.

Referenced by ProcessStartupPacket().

#define PG_PROTOCOL_MAJOR (   v  )     ((v) >> 16)
#define PG_PROTOCOL_MINOR (   v  )     ((v) & 0x0000ffff)

Definition at line 105 of file pqcomm.h.

Referenced by ProcessStartupPacket().

#define SM_DATABASE   64

Definition at line 133 of file pqcomm.h.

Referenced by pqBuildStartupPacket2().

#define SM_DATABASE_USER   (SM_DATABASE+SM_USER+1)

Definition at line 136 of file pqcomm.h.

#define SM_OPTIONS   64

Definition at line 137 of file pqcomm.h.

Referenced by pqBuildStartupPacket2().

#define SM_TTY   64

Definition at line 139 of file pqcomm.h.

Referenced by pqBuildStartupPacket2().

#define SM_UNUSED   64

Definition at line 138 of file pqcomm.h.

#define SM_USER   32

Definition at line 134 of file pqcomm.h.

Referenced by pqBuildStartupPacket2().

#define ss_family   ss_stuff.sa.sa_family

Definition at line 54 of file pqcomm.h.

#define UNIXSOCK_PATH (   path,
  port,
  sockdir 
)
Value:
snprintf(path, sizeof(path), "%s/.s.PGSQL.%d", \
                ((sockdir) && *(sockdir) != '\0') ? (sockdir) : \
                DEFAULT_PGSOCKET_DIR, \
                (port))

Definition at line 70 of file pqcomm.h.

Referenced by connectDBStart(), and StreamServerPort().

#define UNIXSOCK_PATH_BUFLEN   sizeof(((struct sockaddr_un *) NULL)->sun_path)

Definition at line 86 of file pqcomm.h.

Referenced by connectDBStart(), and StreamServerPort().


Typedef Documentation

Definition at line 176 of file pqcomm.h.

Definition at line 115 of file pqcomm.h.

typedef uint32 PacketLen

Definition at line 124 of file pqcomm.h.

Definition at line 113 of file pqcomm.h.

typedef struct StartupPacket StartupPacket

Variable Documentation

Definition at line 253 of file postmaster.c.

Referenced by ClientAuthentication(), parse_hba_line(), and ProcessStartupPacket().