最佳实践SQL登录权限级别 [英] Best practice SQL login permission level

查看:60
本文介绍了最佳实践SQL登录权限级别的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们正在使用Entity Framework 4,并且正在使用SQL登录名从应用程序连接到数据库.为该用户设置数据库权限的最佳实践是什么?使用db_datawriter和db_datareader显然很有效,但是 这似乎太慷慨了.

We are using Entity Framework 4 and are using a SQL login to connect to the database from the application. What is the best practice for setting the database permissions for this user? It obviously works great to use db_datawriter and db_datareader, but this seems a bit too generous.

我们正在使用SQL 2005,连接字符串如下所示:

We are using SQL 2005 and connection string looks something like this:

< add name =" AName" connectionString =" metadata = res://*/AName.csdl | res://*/AName.ssdl | res://*/ProcessedBank.msl; provider = System.Data.SqlClient; provider连接字符串=& quot; Data Source = ADatabase; Initial Catalog = ADatabase; Persist Security Info = True;用户ID = AUser; Password = APassword ;; MultipleActiveResultSets = True&". providerName ="System.Data.EntityClient"; />

<add name="AName" connectionString="metadata=res://*/AName.csdl|res://*/AName.ssdl|res://*/ProcessedBank.msl;provider=System.Data.SqlClient;provider connection string=&quot;Data Source=ADatabase;Initial Catalog=ADatabase;Persist Security Info=True;User ID=AUser;Password=APassword;;MultipleActiveResultSets=True&quot;" providerName="System.Data.EntityClient" />

推荐答案

你好,

         谢谢您的发帖!我建议您在( SQL Server > SQL Server论坛 > SQL Server数据访问)论坛,位于: ( http://social.technet.microsoft.com/Forums/en/sqldataaccess/threads ).

           Thank you for your post!  I would suggest posting your question in one of the (SQL Server > SQL Server Forums > SQL Server Data Access ) forum located here:  (http://social.technet.microsoft.com/Forums/en/sqldataaccess/threads).

        希望对您有所帮助.

          Hope that would be helpful.

       祝你有美好的一天!

         Have a great day!

      谢谢&问候

        Thanks & regards,


这篇关于最佳实践SQL登录权限级别的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆