Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rTi4A-005cmt-8I for pgsql-hackers@arkaria.postgresql.org; Sat, 27 Jan 2024 12:45:46 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1rTi46-0062x8-L6 for pgsql-hackers@arkaria.postgresql.org; Sat, 27 Jan 2024 12:45:42 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rTi46-0062wz-6I for pgsql-hackers@lists.postgresql.org; Sat, 27 Jan 2024 12:45:42 +0000 Received: from mail-ed1-x52f.google.com ([2a00:1450:4864:20::52f]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1rTi43-003dTR-AU for pgsql-hackers@lists.postgresql.org; Sat, 27 Jan 2024 12:45:40 +0000 Received: by mail-ed1-x52f.google.com with SMTP id 4fb4d7f45d1cf-55eb1f9d1f0so751902a12.0 for ; Sat, 27 Jan 2024 04:45:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kleczek.org; s=google; t=1706359536; x=1706964336; darn=lists.postgresql.org; h=to:date:message-id:subject:mime-version:content-transfer-encoding :from:from:to:cc:subject:date:message-id:reply-to; bh=4vVaGt4rvFIhneHxFn5vQZXTtxRQkKDiGQf3ooKeaNM=; b=Vu7icCnmPjID1oFq0ckqBdhmxZQKXt1dxZ5pTUPOtOMXbJ1W8nrHi0g2P1Z60vBWny 7pxghOEx3ezirbO34f9Ni7YekLSrmMNTc2+aWTulm6QhIJ01eCtq6HMi9auPtKKVgx/p jxLEjnW/jURWyP1i21VwoTpv7r/wt1Bz33bEM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1706359536; x=1706964336; h=to:date:message-id:subject:mime-version:content-transfer-encoding :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=4vVaGt4rvFIhneHxFn5vQZXTtxRQkKDiGQf3ooKeaNM=; b=SUmESnJ/Gu8gMZ8uuwJYXqaCsuUMVXDK3oXwhJJO1NkoP/KWNu98Y8QCOlb+rcoAIL EgN9vHSttkw7dVrvR5APxK7JSBIKVjt7w+tiQdByIbsp/rsS+/yaApi5rqEgnf1jkFA7 /c5QESy+ALFwDlHQUrKo6hUv+uXs0AgwnnQn97fdd6ggb8ixp1LDil2qK0re5w5D63ex Yk42A11H0Nyqf75wT60Ai+QMXc/i9Wvixgu+/wfVxd4r8lJuWWO3/enBsUOcH+QS849b etg41Ar/i7voLS8fJmgrrFSHm0MVWyMR3A5Uvm9mRsQDYLevXIfPMwMGR9A8IBdUg2mL yeIA== X-Gm-Message-State: AOJu0YxpYwUUgLHooOsZq08KEYyN76QwanwWO2vdMratecpg00IoLCwT VubwWXGGho8VokAWhzZOFrZ40rjbxiM8PRFaEmrMeTbidPisuvbgC7+/1h60rDAKrANMluQa5w4 l X-Google-Smtp-Source: AGHT+IHFVFSzu0Rpezt0X25OFePJ9QxiObHfkLycVioKzIOTsjj3oMLHz/C48dems+6uJqf3xx0KnA== X-Received: by 2002:aa7:c54b:0:b0:55c:43fe:285f with SMTP id s11-20020aa7c54b000000b0055c43fe285fmr3812202edr.14.1706359536275; Sat, 27 Jan 2024 04:45:36 -0800 (PST) Received: from smtpclient.apple (b15.kleczek.org. [185.20.172.182]) by smtp.gmail.com with ESMTPSA id k1-20020a05640212c100b0055e35d72025sm855381edx.49.2024.01.27.04.45.35 for (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Sat, 27 Jan 2024 04:45:35 -0800 (PST) From: =?utf-8?Q?Micha=C5=82_K=C5=82eczek?= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3774.200.91.1.1\)) Subject: Segmentation fault on FreeBSD with GSSAPI authentication Message-Id: <01704B7E-9948-4926-AD7D-D76C55FCF02A@kleczek.org> Date: Sat, 27 Jan 2024 13:45:23 +0100 To: PostgreSQL Hackers X-Mailer: Apple Mail (2.3774.200.91.1.1) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Hi All, I am trying to use GSSAPI (Kerberos auth) on FreeBSD. After several attempts I was able to build PostgreSQL 16 from FreeBSD = ports with GSSAPI support. The steps were: 1. Uninstall Heimdal 2. Install krb5 (MIT Kerberos) 3. Build Pg with GSSAPI support I configured pg_hba.conf to require GSSAPI authentication for one of the = users. When trying to connect using =E2=80=9Cpsql -h postgres=E2=80=9D = (postgres is the name of the host) I get: psql: error: connection to server at =E2=80=9Cpostgres.[domainname]=E2=80=9D= ([ipaddress]), port 5432 failed: connection to server at = =E2=80=9Cpostgres.[domainname]=E2=80=9D ([ipaddress]), port 5432 failed: = server closed the connection unexpectedly This probably means the server terminated abnormally before or while processing the request. Configured Pg to debug log and here are the relevant syslog entries: an 27 13:33:45 postgres postgres[61605]: [36-1] 2024-01-27 13:33:45.779 = CET [61605] DEBUG: forked new backend, pid=3D61626 socket=3D10 Jan 27 13:33:45 postgres postgres[61605]: [37-1] 2024-01-27 13:33:45.786 = CET [61605] DEBUG: forked new backend, pid=3D61627 socket=3D10 Jan 27 13:33:45 postgres postgres[61605]: [38-1] 2024-01-27 13:33:45.786 = CET [61605] DEBUG: reaping dead processes Jan 27 13:33:45 postgres postgres[61605]: [39-1] 2024-01-27 13:33:45.787 = CET [61605] DEBUG: server process (PID 61626) was terminated by signal = 11: Segmentation fault Jan 27 13:33:45 postgres postgres[61605]: [40-1] 2024-01-27 13:33:45.787 = CET [61605] LOG: server process (PID 61626) was terminated by signal = 11: Segmentation fault Jan 27 13:33:45 postgres postgres[61605]: [41-1] 2024-01-27 13:33:45.787 = CET [61605] LOG: terminating any other active server processes Jan 27 13:33:45 postgres postgres[61605]: [42-1] 2024-01-27 13:33:45.787 = CET [61605] DEBUG: sending SIGQUIT to process 61611 Jan 27 13:33:45 postgres postgres[61605]: [43-1] 2024-01-27 13:33:45.787 = CET [61605] DEBUG: sending SIGQUIT to process 61627 Jan 27 13:33:45 postgres postgres[61605]: [44-1] 2024-01-27 13:33:45.787 = CET [61605] DEBUG: sending SIGQUIT to process 61607 Jan 27 13:33:45 postgres postgres[61605]: [45-1] 2024-01-27 13:33:45.787 = CET [61605] DEBUG: sending SIGQUIT to process 61606 Jan 27 13:33:45 postgres postgres[61605]: [46-1] 2024-01-27 13:33:45.787 = CET [61605] DEBUG: sending SIGQUIT to process 61609 Jan 27 13:33:45 postgres postgres[61605]: [47-1] 2024-01-27 13:33:45.787 = CET [61605] DEBUG: sending SIGQUIT to process 61610 Jan 27 13:33:45 postgres postgres[61605]: [48-1] 2024-01-27 13:33:45.789 = CET [61605] DEBUG: reaping dead processes Jan 27 13:33:45 postgres postgres[61605]: [49-1] 2024-01-27 13:33:45.789 = CET [61605] DEBUG: server process (PID 61627) exited with exit code 2 I am not familiar enough with FreeBSD to be able to gather any crash = dumps or backtraces, I am afraid. -- Michal=