45 const char **logdetail)
88 (
errcode(ERRCODE_PROTOCOL_VIOLATION),
89 errmsg(
"expected SASL response, got message type %d",
105 elog(
DEBUG4,
"processing received SASL response of length %d",
buf.len);
115 const char *selected_mech;
131 opaq = mech->
init(
port, selected_mech, shadow_pass);
171 elog(
ERROR,
"output message found after SASL exchange failure");
176 elog(
DEBUG4,
"sending SASL challenge of length %d", outputlen);
int CheckSASLAuth(const pg_be_sasl_mech *mech, Port *port, char *shadow_pass, const char **logdetail)
void sendAuthRequest(Port *port, AuthRequest areq, const char *extradata, int extralen)
#define Assert(condition)
int errcode(int sqlerrcode)
int errmsg(const char *fmt,...)
#define ereport(elevel,...)
void pfree(void *pointer)
int pq_getmessage(StringInfo s, int maxlen)
void pq_startmsgread(void)
#define AUTH_REQ_SASL_CONT
#define PqMsg_SASLResponse
#define AUTH_REQ_SASL_FIN
#define PG_SASL_EXCHANGE_FAILURE
#define PG_SASL_EXCHANGE_CONTINUE
#define PG_SASL_EXCHANGE_SUCCESS
void appendStringInfoChar(StringInfo str, char ch)
void initStringInfo(StringInfo str)
int(* exchange)(void *state, const char *input, int inputlen, char **output, int *outputlen, const char **logdetail)
void(* get_mechanisms)(Port *port, StringInfo buf)
void *(* init)(Port *port, const char *mech, const char *shadow_pass)