对于 Sync Framework 客户端应用程序(数据库同步),哪种身份验证方法是正确的?
用户将在互联网连接较差的地区到现场收集 Windows 客户端应用程序的数据。几天甚至几周都没有任何网络连接。幸运者将把他们的笔记本电脑带回地区办事处,以同步他们登录公司网络时收集的数据。其他人将不得不求助于插入客户端/客户互联网连接和/或网吧连接来执行数据同步。
该应用程序将数据存储在本地 SQL Server 2008 R2 Express 数据库上,当连接可用时,客户端将启动与总部 SQL Server 2008 标准的数据库同步。
用户身份验证和基于角色的安全性是应用程序的要求。我应该使用哪种方法:表单身份验证或 Windows 身份验证? (我想我遇到了第三种类型,称为自定义身份验证?)
抱歉,我真的对身份验证的内容迷失了 - 第一次这样做,不确定优点和缺点。每种类型的缺点。谁能建议我在这种情况下应该使用哪个?
更新: 实际上,我现在已经使用连接字符串中的 SQL Server 外部 IP 地址和用户登录的 SQL 身份验证来进行同步。这是一种可接受的做法还是我违反了任何安全原则?
我仍然需要了解基于角色的安全部分 - 基于角色的安全可以与 SQL 身份验证一起使用吗?
此外,新的问题是:事实证明,一些远程用户一旦从总部获得笔记本电脑,可能永远不会再次登录到组织的域,因此他们的登录与域的信任关系会在几个月后过期。因此,我猜 Windows 身份验证无论如何都不可行......
Users will be out in the field collecting data on windows client app in areas with poor internet connection. Days or even weeks at a time away from any network connection. The lucky ones will bring their laptop back to a regional office to sync the data they've collected when they login to the company network. Others will have to resort to plugging into a client/customer internet connection and/or Internet Cafe connection to perform the data sync.
The app stores the data on a local sql server 2008 R2 express database and the client will initiate a database sync to the SQL Server 2008 standard in HQ as and when connection is available.
User Authentication and role based security are requirements of the App. Which method should I be using: Forms Authentication or Windows Authentication ? (And I think I've come across a 3rd type called Custom Authentication ?)
Sorry, I'm really lost on the authentication stuff - first time doing it and not sure of the pros & cons of each type. Can anyone advise which I should be using for this scenario ?
UPDATE: I've actually got the synchronization working now using the SQL Server's external ip address in the connection string and SQL Authentication for the user logins. Would this be an accepted practice or am I violating any security principles?
I still have to get to the role based security piece - can role based security work with SQL Authentication?
Also, new wrinkle: turns out that some of the remote users once they have been issued their laptop from Head Office may never login to the organisation's Domain again so their Login's Trust relationship with the domain expires after a few months. Therefore, I guess Windows Authentication is not viable anyway...
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您将如何连接到总部数据库服务器?
我认为最安全的解决方案是通过 WCF 同步(示例使用 SqlCompact 到 Sql Server over WCF with N-tier 此处)。然后,您可以根据您在 WCF 中实现的安全类型(传输和/或消息)来实现您想要的任何身份验证方案。请参阅 这个和此了解更多信息。
How will you connect to the HQ db server?
Imo the safest solution would be to sync over WCF (sample with SqlCompact to Sql Server over WCF with N-tier here). You can then implement whatever authentication scheme you want depending on the kind of security (transport and/or message) you implement in WCF. See this and this for more info.