Код: Выделить всё
Npgsql.NpgsqlException
HResult=0x80004005
Message=Failed to establish a connection to 'denodo-host'.
Source=Npgsql
StackTrace:
at Npgsql.NpgsqlClosedState.Open(NpgsqlConnector context, Int32 timeout)
at Npgsql.NpgsqlConnector.Open()
at Npgsql.NpgsqlConnectorPool.GetPooledConnector(NpgsqlConnection Connection)
at Npgsql.NpgsqlConnectorPool.RequestPooledConnectorInternal(NpgsqlConnection Connection)
at Npgsql.NpgsqlConnectorPool.RequestConnector(NpgsqlConnection Connection)
at Npgsql.NpgsqlConnection.Open()
at Denodo.ADONetSample.Main(String[] args) in C:\Users\Hero\vdp-clients-
ADO.NET\Program.cs:line 67
Inner Exception 1:
AuthenticationException: A call to SSPI failed, see inner exception.
Inner Exception 2:
Win32Exception: The client and server cannot communicate, because they do not possess a
common algorithm
Код: Выделить всё
string connectionString = "Server=" + host + ";Port=" + port +";User Id=" + user + ";Password=" + password + ";Database=" + db + ";SSL=True;Sslmode=Allow;";
NpgsqlConnectionStringBuilder b = new NpgsqlConnectionStringBuilder(connectionString)
{
SSL = true,
SslMode = SslMode.Allow
};
using (NpgsqlConnection connection = new NpgsqlConnection(b))
{
ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Tls12;
connection.UseSslStream = true;
connection.Open();
// NpgsqlCommand code....
}
Эта проблема связана только с SecurityProtocol?
Тогда как я могу знаете версию сервера?
Подробнее здесь: https://stackoverflow.com/questions/792 ... cate-becau
Мобильная версия