You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Error: The target principal name is incorrect #1621
We have a Net6 Programm wich throws this error (In German: "Der Zielprinzipalname ist falsch").
If we you the same software in an older Version wich works with Net4.8 and System.Data.SqlServer the same connection String could access the Database.
Also Managementstudio could access the DB.
We use "Integrated Security=true" to access the Database.
We also tried to add: encrypt=false to the connection string.
@jogibear9988 is server setup to force encryption with a self-signed certificate? Starting in M.D.S 4.0, the driver will validate server certificates based on the Trust Server Certificate setting when encryption is negotiated by Encrypt=true OR if the server requires encryption. If that is your scenario, you can either install the server certificate on the client as a trusted certificate (most secure) or set Trust Server Certificate=true (less secure because it will trust ANY certificate).
Activity
[-]Error: TargetPricipal is wrong [/-][+]Error: Target Principal is wrong[/+][-]Error: Target Principal is wrong[/-][+]Error: The target principal name is incorrect[/+]jogibear9988 commentedon May 24, 2022
Got it fixed via adding:
Trust Server Certificate = true;
to ConnectionString
see:
#609 (comment)
JRahnama commentedon May 25, 2022
@jogibear9988 thanks for bringing the issue up to our attention. If the problem is solved please feel free to close it.
JRahnama commentedon May 27, 2022
@jogibear9988 is server setup to force encryption with a self-signed certificate? Starting in M.D.S 4.0, the driver will validate server certificates based on the Trust Server Certificate setting when encryption is negotiated by Encrypt=true OR if the server requires encryption. If that is your scenario, you can either install the server certificate on the client as a trusted certificate (most secure) or set Trust Server Certificate=true (less secure because it will trust ANY certificate).
jogibear9988 commentedon May 29, 2022
@JRahnama Don't know... I only know, it worked with the connection sring in net4.8
And it now works after adding: "Trust Server Certificate=true"