Azure的Active Directory和WCF [英] Azure Active Directory and WCF

查看:186
本文介绍了Azure的Active Directory和WCF的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我如何能确保WCF服务使用的Azure Active Directory的:

How can I secure a WCF service using Azure Active Directory:

我的状态:   - 包含业务逻辑,我的WCF服务托管在Azure上WebRole

My Status: - My WCF service that contains the business logic is hosted on Azure WebRole.

我要你的帮助,做到以下几点:

  • 配置在Azure中我的WCF服务,以联合身份验证过程中的Azure Active Directory中。
  • 在配置我的WCF客户提供了[用户名/密码]来从Azure的活动目录令牌。
  • 在配置我的WCF服务,以验证客户端的令牌。

我的环境约束:

  • WCF 4.5。
  • WIF 4.5。
  • 的Visual Studio 2012。
  • 这是一个概念证明,我必须使用自签名的证书。

推荐答案

阿列克谢的回答应该让你开始。但有一件事我会提及:

Alexey's answer should get you started. But one thing I'd mention:

使用Azure的ACS我创建了一个[用户名/密码]为每个用户   通过[ACS服务标识。

Using Azure ACS i have created a [username/password] for every user via [ACS Service identities].

在生产,你不应该这样做。业务标识是为了授权服​​务,这是可信子系统,其中关键本身不暴露于外部。请记住,ACS是一个联合提供者,而不是一个身份提供者。它pricnipally设计用于连接现有的身份系统连接在一起,而不是用于存储用户凭据。如果您的系统使用的增长业务标识为用户凭据,你会碰到的问题的规模和用户帐号(密码)的管理。

In production you shouldn't do this. Service identities are meant to authorize services that are trusted subsystems, where the key itself is not exposed externally. Keep in mind that ACS is a federation provider, not an identity provider. It's pricnipally designed for linking existing identity systems together and not for storing user credentials. If your system grows using service identities as user credentials, you'll run into problems with scale and user account (password) management.

由于概念证明,它的罚款。但是,对于一些真正的你可能会依靠导通$ P $点AD,像Fac​​ebook和谷歌,或检查出的 http://www.windowsazure.com/en-us/manage/services/identity/

As a proof of concept, it's fine. But for something real you might rely on a on-prem AD, consumer identity providers like facebook and google, or check out http://www.windowsazure.com/en-us/manage/services/identity/

这篇关于Azure的Active Directory和WCF的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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