-
Notifications
You must be signed in to change notification settings - Fork 310
Description
Describe the bug
MDS' managed SNI implementation is sending the SPN in the format MSSQLSVC/SERVERNAME.FQDN:INSTANCENAME instead of MSSQLSVC/SERVERNAME.FQDN:PORT when making TCP connections to named instances.
To reproduce
Connect to a named instance via TCP, managed SNI, and Kerberos auth. Using a network capture, you can see MDS gets a ticket using the named instance instead of the port number.
Expected behavior
MDS should use the MSSQLSVC/SERVERNAME.FQDN:PORT format for consistency with other drivers and aligning with the docs:
User-specified SPNs are supported in client drivers. However, if an SPN isn't provided, it is generated automatically based on the type of a client connection. For a TCP connection, an SPN in the format
MSSQLSvc/FQDN:[<port>]
is used for both the named and default instances.
For named pipes and shared memory connections, an SPN in the format
MSSQLSvc/<FQDN>:<instancename>
is used for a named instance andMSSQLSvc/<FQDN>
is used for the default instance.
Further technical details
Microsoft.Data.SqlClient version: latest 5.1.1
.NET target: .NET (non Framework)
SQL Server version: All
Operating system: Linux (or managed SNI on Windows)
Metadata
Metadata
Assignees
Labels
Type
Projects
Status