1

I'm working on an application which consists of a Web Application and a Standalone Application. Both of the applications use the same database and require authentication and authorization.

Within the Standalone Application a web browser needs to be opened, going to a page within the Web Application. This page is for authorized users only.

Could anyone tell me if there is an easy way to automatically login within the Web Application via the Standalone Application? Besides using cookies or providing a token in the url. Thank you.

4

3 回答 3

0

将登录凭据(用户名和密码)存储在用户的本地文件系统中。但不推荐,因为任何有权访问文件系统的人都可以轻松读取用户的密码。

于 2010-06-11T17:10:28.907 回答
0

如果您的组织使用单点登录,那么您可以使用该流程。如果不是,那么您可以将加密密钥作为包含验证信息的 URL 参数的一部分传递,并在您的 Web 应用程序中验证它。为了保护密钥,您可能每次都需要向其中添加随机数据,这样用户就不能总是复制密钥并直接访问网页。我能想到的其他选项是将用户 ID 作为 URL 的一部分传递,然后在用户表中进行查询以重新验证 Web 应用程序中的用户。但这是一种额外的处理,我想你在这里试图避免..

于 2010-06-11T17:17:05.847 回答
0

您如何处理身份验证?如果您从桌面应用程序直接连接到数据库,并且数据库保存了授权信息,例如用户和密码的 SQL 表,那么您只需对数据库进行查询并直接从应用程序授权,而无需转到网页。

于 2010-06-11T17:04:03.187 回答