Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitfb8ac3f

Browse files
committed
Dept. of third thoughts: in fact, libpq should support SCM_CREDS challenge
even when HAVE_GETPEEREID is defined, else it will be unable to connect topre-7.4 backends that are using IDENT authentication.
1 parentb8f2980 commitfb8ac3f

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

‎src/interfaces/libpq/fe-auth.c

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
* exceed INITIAL_EXPBUFFER_SIZE (currently 256 bytes).
1111
*
1212
* IDENTIFICATION
13-
* $PostgreSQL: pgsql/src/interfaces/libpq/fe-auth.c,v 1.87 2003/12/20 18:24:52 tgl Exp $
13+
* $PostgreSQL: pgsql/src/interfaces/libpq/fe-auth.c,v 1.88 2003/12/20 18:45:49 tgl Exp $
1414
*
1515
*-------------------------------------------------------------------------
1616
*/
@@ -450,16 +450,15 @@ pg_krb5_sendauth(char *PQerrormsg, int sock, const char *hostname)
450450
/*
451451
* Respond to AUTH_REQ_SCM_CREDS challenge.
452452
*
453-
* Note:the backend will not use this challenge if HAVE_GETPEEREID
454-
* or SO_PEERCRED is defined,so we don't bother to compileany code
455-
*in that case, even if the facility is available.
453+
* Note:current backends will not use this challenge if HAVE_GETPEEREID
454+
* or SO_PEERCRED is defined,but pre-7.4 backends might, so compilethe
455+
*code anyway.
456456
*/
457457
staticint
458458
pg_local_sendauth(char*PQerrormsg,PGconn*conn)
459459
{
460-
#if !defined(HAVE_GETPEEREID)&& !defined(SO_PEERCRED)&& \
461-
(defined(HAVE_STRUCT_CMSGCRED)|| defined(HAVE_STRUCT_FCRED)|| \
462-
(defined(HAVE_STRUCT_SOCKCRED)&& defined(LOCAL_CREDS)))
460+
#if defined(HAVE_STRUCT_CMSGCRED)|| defined(HAVE_STRUCT_FCRED)|| \
461+
(defined(HAVE_STRUCT_SOCKCRED)&& defined(LOCAL_CREDS))
463462
charbuf;
464463
structioveciov;
465464
structmsghdrmsg;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp