C# 获取Checkmarx漏洞问题:Authentication.Credentials。无保护

C# 获取Checkmarx漏洞问题:Authentication.Credentials。无保护,c#,web-config,checkmarx,secure-coding,sast,C#,Web Config,Checkmarx,Secure Coding,Sast,我们最近开始对我们的代码库进行Checkmarx扫描,在该代码库中,我们发现以下漏洞问题,这是由于web.config中connectionstring中提到的扁平密码引起的,如下所示: <connectionStrings> <add name="sqlServer" providerName="System.Data.SqlClient" connectionString="Data So

我们最近开始对我们的代码库进行Checkmarx扫描,在该代码库中,我们发现以下漏洞问题,这是由于web.config中connectionstring中提到的扁平密码引起的,如下所示:

  <connectionStrings>  
  <add
    name="sqlServer"
    providerName="System.Data.SqlClient"
    connectionString="Data Source=localhost;Initial Catalog=StockDB;User Id=vturner;Password=some_password;" />
</connectionStrings>

错误:

身份验证。凭据。无保护


我尝试过一些解决方案,比如加密、参数化配置、加密web.config,但都不起作用。有人能对此提出建议吗?

您能展示一下您的加密解决方案吗?你试过这个吗