本文介绍了Persist Security Info属性= true和Persist安全信息属性= false的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

对于属性:

  Persist Security Info = true 

  Persist Security Info = false 

你能告诉我他们之间有什么区别,如果我不把它放在我的连接中会发生什么?

  connect.ConnectionString =Provider = Microsoft.ACE.OLEDB.12.0; 
数据源= C: / Nourah /下载
/Phase3/Salary.accdb;
Persist Security Info = False;;


解决方案

即使您设置安全信息= true Persist Security Info = false
它不会在前面显示差异。背景



Persist Security Info设置为false 安全敏感的
信息时,如果连接已打开或已处于打开的
状态,则不会作为
连接的一部分返回。



如果设置 Persist Security Info to True ,Windows会记住在连接字符串中指定的密码。





设置 Persist安全信息 true或false仅在您提及用户名和密码时才会生效连接字符串。如果在connectionstring中提及用户名和密码,并将 Persist Security Info 设置为 false ,则无法提取凭据。但是如果你在连接字符串窗口中提供凭据时设置 Persist Security Info 为true,那么就会记住凭证,并且可以在pgm中提取


For the properties:

Persist Security Info=true

and

Persist Security Info=false

Can you tell me what is the difference between them, and if I don't put it in my connection what will happen?

connect.ConnectionString = "Provider=Microsoft.ACE.OLEDB.12.0;
                            Data Source=C:/Users/Nourah/Downloads 
                            /Phase3/Salary.accdb; 
                            Persist Security Info=False;";
解决方案

Even if you set Persist Security Info= true OR Persist Security Info=falseit won't show a difference in front..The difference is happening at background

When Persist Security Info set to false security-sensitiveinformation, such as the password, is not returned as part of theconnection if the connection is open or has ever been in an openstate.

If you set Persist Security Info to True, Windows will remember the password specified in the connection string.

Thats the difference.

MSDN Explanation

setting Persist Security Info true or false will come into effect only if you mention username and password in connection string. If you mention username and password in connectionstring and set Persist Security Info as false then the credentials cannot be extracted. but if you set Persist Security Info as true while giving credentials in the connectionstring windows will remember the credentials and it can extracted in pgm

这篇关于Persist Security Info属性= true和Persist安全信息属性= false的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-11 11:15