如何设置连接字符串数据库TDE与证书提供

时间:2022-03-17 11:52:04

I have a local database with the certificate to protect the security of a database. I try using this normal connection string to connect, it failed due this database had set on security. How do I connect this database from C# if in the application provide certificate and password as well? our connection string now.

我有一个带有证书的本地数据库来保护数据库的安全性。我尝试使用此正常连接字符串进行连接,由于此数据库已设置安全性,因此失败。如果在应用程序中提供证书和密码,如何从C#连接此数据库?我们的连接字符串。

global.ConnString = String.Format(@"Server=(localdb)\v11.0;AttachDbFileName={0}\TestTDE\{1};Integrated Security=SSPI;MultipleActiveResultSets=True;Packet Size=4096", Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments), "TDETesting.mdf");

1 个解决方案

#1


0  

You can set the username="username you use to connect to database" password="its password" inside your connection string. try removing Integrated security

您可以在连接字符串中设置username =“用于连接数据库的用户名”password =“its password”。尝试删除集成安全性

#1


0  

You can set the username="username you use to connect to database" password="its password" inside your connection string. try removing Integrated security

您可以在连接字符串中设置username =“用于连接数据库的用户名”password =“its password”。尝试删除集成安全性