Azure Active Directory 连接字符串 [英] Azure Active Directory Connection String

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

问题描述

我一直在尝试设置我的 IIS 网站的连接字符串以使用以下连接字符串连接到 Azure SQL 数据库:

I've been trying to set up my IIS website's connection string to connect to an Azure SQL Database with the following connection string:

<add name="ConnectionString" connectionString="Server=tcp:some.database.windows.net,1433;Database=myDB;Authentication=Active Directory Integrated;" />

IIS 应用程序池正在使用具有 Azure Active Directory 权限并作为用户添加到 Azure SQL 数据库的服务帐户.

The IIS application pool is using a service account which has Azure Active Directory privileges and is added as an user on the Azure SQL Database.

这在我的本地开发机器上运行良好(可能是因为它使用的是我的凭据而不是服务帐户)但是当我将网站放在 IIS 上时,我得到:

This works fine on my local development machine (probably because it is using my credentials and not a service account) but when I place the site on IIS I get:

System.ArgumentException: Keyword not supported: 'authentication'.

有人知道通过 Azure AD 登录的正确语法吗?

Does anyone know the correct syntax for logging in via Azure AD?

推荐答案

您是否阅读过此故障排除指南,https://azure.microsoft.com/en-us/documentation/articles/sql-database-aad-authentication/#5-configure-your-client-computers?

Have you been through this troubleshooting guide, https://azure.microsoft.com/en-us/documentation/articles/sql-database-aad-authentication/#5-configure-your-client-computers?

特别是,您是否安装了 .NET Framework 4.6 或更高版本?

In particular, do you have .NET Framework 4.6 or later installed?

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

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