0
votes

I am able to connect to SQL Azure database using sql authentication . However, I am unable to connect using domain account(domain\AccountName) from Azure VM. I am using SSMS 2016 version and using the option 'Active Directory Integrated' and default database as the azure database.

Few things to keep in mind 1) I have created this Azure database in portal using the same account that I am testing now to connect from Azure VM. 2)This domain account has MFA enabled because while connecting to VPN , I need to enter the password that I get over my phone to login

Below are the errors that I am getting when trying to use each of the options

1) Active Directory Integrated

Cannot connect to XXXXX.database.windows.net.

------------------------------ ADDITIONAL INFORMATION:

Failed to authenticate the user NT Authority\Anonymous Logon in Active Directory (Authentication=ActiveDirectoryIntegrated). Error code 0xCAA2000C; state 10 AADSTS50076: Due to a configuration change made by your administrator, or because you moved to a new location, you must use multi-factor authentication to access xxxxx. Trace ID: 06d7d4bc-4fc2-4ce3-9bda-486e31370300 Correlation ID: ac7592ee-1c21-4875-8455-5a10a9588725 Timestamp: 2018-08-09 06:14:07Z (Microsoft SQL Server, Error: 0)

2) Active Directory Password

Cannot connect to xxx.database.windows.net.

------------------------------ ADDITIONAL INFORMATION:

Failed to authenticate the user User@domainname in Active Directory (Authentication=ActiveDirectoryPassword). Error code 0xCAA2000C; state 10 AADSTS50076: Due to a configuration change made by your administrator, or because you moved to a new location, you must use multi-factor authentication to access xxxx. Trace ID: ac6347b5-c1f8-4f81-8f83-5284b8010400 Correlation ID: 4e67f279-1d47-4ce9-97d7-68e074f616fc Timestamp: 2018-08-09 07:22:40Z (Microsoft SQL Server, Error: 0)

3)Active Directory MFA

Cannot connect to xxx.database.windows.net.

------------------------------ ADDITIONAL INFORMATION:

One or more errors occurred. (mscorlib)


Unable to acquire authorization token (Microsoft.SqlServer.Management.AzureAuthenticationManagement)


One or more errors occurred. (mscorlib)


User canceled authentication (Microsoft.IdentityModel.Clients.ActiveDirectory)

1

1 Answers

0
votes

You are able to connect from an Azure VM because is a trusted location for Azure. You need to create a trusted location with the IP address where you are running SSMS. Please follow instructions on this article.

enter image description here

enter image description here