encrypt SQL connectionstring c#

前端 未结 5 1074
离开以前
离开以前 2020-11-30 09:21

I created an c# application (not asp webpage) which connects to a sql 2005 server. In my sourcecode the password and userid for this sql-server is coded plain text in Connec

5条回答
  •  一个人的身影
    2020-11-30 09:23

    You can encrypt sections in the app.config in the same way as web.config. MS calls it Protected Configuration. Since both the enrypted data and the key resides on the same machine it only makes it harder but in theory not impossible to get to the data.

提交回复
热议问题