From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: Ayush Tiwari Date: Fri, 1 May 2026 12:00:00 +0530 Subject: [PATCH v2] Fix Windows SSPI auth in sequence subscription test The sequence subscription test switches regress_seq_sub to connect to the publisher as regress_seq_repl when checking behavior with insufficient sequence privileges. On Windows, pg_regress --config-auth configures TAP nodes to use SSPI authentication for TCP connections, and only the bootstrap user plus roles listed with --create-role are mapped in pg_ident.conf. Without adding regress_seq_repl to the publisher's auth_extra list, the subscription worker can fail with SSPI authentication failure before it reaches the intended insufficient-privilege scenario. Initialize the publisher with an auth mapping for regress_seq_repl, matching other tests that authenticate as non-default roles. --- v2: Add a comment explaining why the auth_extra setup is needed on Windows. src/test/subscription/t/036_sequences.pl | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/test/subscription/t/036_sequences.pl b/src/test/subscription/t/036_sequences.pl index e6dd3b069b8..387b057268d 100644 --- a/src/test/subscription/t/036_sequences.pl +++ b/src/test/subscription/t/036_sequences.pl @@ -10,7 +10,11 @@ use Test::More; # Initialize publisher node my $node_publisher = PostgreSQL::Test::Cluster->new('publisher'); -$node_publisher->init(allows_streaming => 'logical'); +# Make sure pg_hba.conf is set up to allow connections from regress_seq_repl. +# This is only needed on Windows machines that don't use UNIX sockets. +$node_publisher->init( + allows_streaming => 'logical', + auth_extra => [ '--create-role' => 'regress_seq_repl' ]); $node_publisher->start; # Initialize subscriber node -- 2.34.1