Skip to content

Commit 0891292

Browse files
authored
Merge pull request #177093 from VanMSFT/aadlimitations
Adding limitations for AAD-only
2 parents dbc7ebf + fb5bd58 commit 0891292

5 files changed

+33
-22
lines changed

articles/azure-sql/database/authentication-aad-service-principal-tutorial.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ ms.topic: tutorial
77
author: GithubMirek
88
ms.author: mireks
99
ms.reviewer: vanto
10-
ms.date: 05/10/2021
10+
ms.date: 10/21/2021
1111
ms.custom: devx-track-azurepowershell
1212
---
1313

@@ -111,7 +111,7 @@ if ($role -eq $null) {
111111
$role = Get-AzureADDirectoryRole | Where-Object {$_.displayName -eq $roleName}
112112
}
113113
114-
# Get service principal for managed instance
114+
# Get service principal for server
115115
$roleMember = Get-AzureADServicePrincipal -SearchString $AssignIdentityName
116116
$roleMember.Count
117117
if ($roleMember -eq $null) {

articles/azure-sql/database/authentication-aad-service-principal.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ ms.topic: conceptual
77
author: GithubMirek
88
ms.author: mireks
99
ms.reviewer: vanto
10-
ms.date: 05/11/2021
10+
ms.date: 10/21/2021
1111
---
1212

1313
# Azure Active Directory service principal with Azure SQL
@@ -46,22 +46,22 @@ Supporting this functionality is useful in Azure AD application automation proce
4646

4747
To enable an Azure AD object creation in SQL Database on behalf of an Azure AD application, the following settings are required:
4848

49-
1. Assign the server identity. The assigned server identity represents the Managed Service Identity (MSI). Currently, the server identity for Azure SQL does not support User Managed Identity (UMI).
49+
1. Assign the server identity. The assigned server identity represents the Managed Service Identity (MSI). Currently, the server identity for Azure SQL does not support user-assigned managed identities (UMI).
5050
- For a new Azure SQL logical server, execute the following PowerShell command:
5151

5252
```powershell
5353
New-AzSqlServer -ResourceGroupName <resource group> -Location <Location name> -ServerName <Server name> -ServerVersion "12.0" -SqlAdministratorCredentials (Get-Credential) -AssignIdentity
5454
```
5555
56-
For more information, see the [New-AzSqlServer](/powershell/module/az.sql/new-azsqlserver) command.
56+
For more information, see the [New-AzSqlServer](/powershell/module/az.sql/new-azsqlserver) command, or [New-AzSqlInstance](/powershell/module/az.sql/new-azsqlinstance) command for SQL Managed Instance.
5757
5858
- For existing Azure SQL Logical servers, execute the following command:
5959
6060
```powershell
6161
Set-AzSqlServer -ResourceGroupName <resource group> -ServerName <Server name> -AssignIdentity
6262
```
6363
64-
For more information, see the [Set-AzSqlServer](/powershell/module/az.sql/set-azsqlserver) command.
64+
For more information, see the [Set-AzSqlServer](/powershell/module/az.sql/set-azsqlserver) command, or [Set-AzSqlInstance](/powershell/module/az.sql/set-azsqlinstance) command for SQL Managed Instance.
6565
6666
- To check if the server identity is assigned to the server, execute the Get-AzSqlServer command.
6767

articles/azure-sql/database/authentication-azure-ad-only-authentication.md

Lines changed: 18 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ ms.topic: conceptual
88
author: GithubMirek
99
ms.author: mireks
1010
ms.reviewer: vanto
11-
ms.date: 10/19/2021
11+
ms.date: 10/21/2021
1212
---
1313

1414
# Azure AD-only authentication with Azure SQL
@@ -392,13 +392,26 @@ SELECT SERVERPROPERTY('IsExternalAuthenticationOnly')
392392
- Azure AD users with proper permissions can impersonate existing SQL users.
393393
- Impersonation continues working between SQL authentication users even when the Azure AD-only authentication feature is enabled.
394394

395-
### Limitations for Azure AD-only authentication in managed instance
395+
### Limitations for Azure AD-only authentication in SQL Database
396396

397-
When Azure AD-only authentication is enabled for managed instance, the following features aren't supported:
397+
When Azure AD-only authentication is enabled for SQL Database, the following features aren't supported:
398398

399-
- Transactional replication
399+
- [Azure SQL Database server roles](security-server-roles.md)
400+
- [Elastic jobs](job-automation-overview.md)
401+
- [SQL Data Sync](sql-data-sync-data-sql-server-sql-database.md)
402+
- [Change data capture (CDC)](/sql/relational-databases/track-changes/about-change-data-capture-sql-server)
403+
- [Transactional replication](/azure/azure-sql/managed-instance/replication-transactional-overview) - Since SQL authentication is required for connectivity between replication participants, when Azure AD-only authentication is enabled, transactional replication is not supported for SQL Database for scenarios where transactional replication is used to push changes made in an Azure SQL Managed Instance, on-premises SQL Server, or an Azure VM SQL Server instance to a database in Azure SQL Database
404+
- [SQL insights](/azure/azure-monitor/insights/sql-insights-overview)
405+
- EXEC AS statement for Azure AD group member accounts
406+
407+
### Limitations for Azure AD-only authentication in Managed Instance
408+
409+
When Azure AD-only authentication is enabled for Managed Instance, the following features aren't supported:
410+
411+
- [Transactional replication](/azure/azure-sql/managed-instance/replication-transactional-overview)
412+
- [SQL Agent Jobs in Managed Instance](../managed-instance/job-automation-managed-instance.md) supports Azure AD-only authentication. However, the Azure AD user who is a member of an Azure AD group that has access to the managed instance cannot own SQL Agent Jobs
413+
- [SQL insights](/azure/azure-monitor/insights/sql-insights-overview)
400414
- EXEC AS statement for Azure AD group member accounts
401-
- [SQL Agent Jobs in Managed Instance](../managed-instance/job-automation-managed-instance.md) supports Azure AD-only authentication. However, the Azure AD user who is a member of an Azure AD group that has access to the managed instance cannot own SQL Agent Jobs.
402415

403416
For more limitations, see [T-SQL differences between SQL Server & Azure SQL Managed Instance](../managed-instance/transact-sql-tsql-differences-sql-server.md#logins-and-users).
404417

articles/azure-sql/managed-instance/instance-pools-overview.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ ms.topic: conceptual
1111
author: urosmil
1212
ms.author: urmilano
1313
ms.reviewer: mathoma
14-
ms.date: 09/05/2019
14+
ms.date: 10/21/2021
1515
---
1616
# What is an Azure SQL Managed Instance pool (preview)?
1717
[!INCLUDE[appliesto-sqlmi](../includes/appliesto-sqlmi.md)]
@@ -76,7 +76,7 @@ There are several resource limitations regarding instance pools and instances in
7676
- 8 vCores pool supports up to 200 databases,
7777
- 16 vCores pool supports up to 400 databases,
7878
- 24 and larger vCores pool supports up to 500 databases.
79-
- AAD Admin cannot be set for the instances deployed inside the instance pool therefore AAD Authentication can't be used.
79+
- Azure AD authentication can be used after creating or setting a managed instance with the `-AssignIdentity` flag. For more information, see [New-AzSqlInstance](/powershell/module/az.sql/new-azsqlinstance) and [Set-AzSqlInstance](/powershell/module/az.sql/set-azsqlinstance). Users can then set an Azure AD admin for the instance by following [Provision Azure AD admin (SQL Managed Instance)](/azure/azure-sql/database/authentication-aad-configure#provision-azure-ad-admin-sql-managed-instance).
8080

8181
Total storage allocation and number of databases across all instances must be lower than or equal to the limits exposed by instance pools.
8282

articles/azure-sql/managed-instance/transact-sql-tsql-differences-sql-server.md

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ ms.topic: reference
99
author: danimir
1010
ms.author: danil
1111
ms.reviewer: mathoma, bonova, danil
12-
ms.date: 8/18/2021
12+
ms.date: 10/21/2021
1313
ms.custom: seoapril2019, sqldbrb=1
1414
---
1515

@@ -140,14 +140,14 @@ SQL Managed Instance can't access files, so cryptographic providers can't be cre
140140
SQL Managed Instance supports Azure AD database principals with the syntax `CREATE USER [AADUser/AAD group] FROM EXTERNAL PROVIDER`. This feature is also known as Azure AD contained database users.
141141

142142
- Windows logins created with the `CREATE LOGIN ... FROM WINDOWS` syntax aren't supported. Use Azure Active Directory logins and users.
143-
- The Azure AD user who created the instance has [unrestricted admin privileges](../database/logins-create-manage.md).
143+
- The Azure AD admin for the instance has [unrestricted admin privileges](../database/logins-create-manage.md).
144144
- Non-administrator Azure AD database-level users can be created by using the `CREATE USER ... FROM EXTERNAL PROVIDER` syntax. See [CREATE USER ... FROM EXTERNAL PROVIDER](../database/authentication-aad-configure.md#create-contained-users-mapped-to-azure-ad-identities).
145145
- Azure AD server principals (logins) support SQL features within one SQL Managed Instance only. Features that require cross-instance interaction, no matter whether they're within the same Azure AD tenant or different tenants, aren't supported for Azure AD users. Examples of such features are:
146146

147147
- SQL transactional replication.
148148
- Link server.
149149

150-
- Setting an Azure AD login mapped to an Azure AD group as the database owner isn't supported.
150+
- Setting an Azure AD login mapped to an Azure AD group as the database owner isn't supported. A member of the Azure AD group can be a database owner, even if the login hasn't been created in the database.
151151
- Impersonation of Azure AD server-level principals by using other Azure AD principals is supported, such as the [EXECUTE AS](/sql/t-sql/statements/execute-as-transact-sql) clause. EXECUTE AS limitations are:
152152

153153
- EXECUTE AS USER isn't supported for Azure AD users when the name differs from the login name. An example is when the user is created through the syntax CREATE USER [myAadUser] FROM LOGIN [[email protected]] and impersonation is attempted through EXEC AS USER = _myAadUser_. When you create a **USER** from an Azure AD server principal (login), specify the user_name as the same login_name from **LOGIN**.
@@ -170,15 +170,13 @@ SQL Managed Instance can't access files, so cryptographic providers can't be cre
170170
- If the login is a SQL principal, only logins that are part of the `sysadmin` role can use the create command to create logins for an Azure AD account.
171171
- The Azure AD login must be a member of an Azure AD within the same directory that's used for Azure SQL Managed Instance.
172172
- Azure AD server principals (logins) are visible in Object Explorer starting with SQL Server Management Studio 18.0 preview 5.
173-
- Overlapping Azure AD server principals (logins) with an Azure AD admin account is allowed. Azure AD server principals (logins) take precedence over the Azure AD admin when you resolve the principal and apply permissions to SQL Managed Instance.
173+
- A server principal with *sysadmin* access level is automatically created for the Azure AD admin account once it’s enabled on an instance.
174174
- During authentication, the following sequence is applied to resolve the authenticating principal:
175175

176176
1. If the Azure AD account exists as directly mapped to the Azure AD server principal (login), which is present in sys.server_principals as type "E," grant access and apply permissions of the Azure AD server principal (login).
177-
2. If the Azure AD account is a member of an Azure AD group that's mapped to the Azure AD server principal (login), which is present in sys.server_principals as type "X," grant access and apply permissions of the Azure AD group login.
178-
3. If the Azure AD account is a special portal-configured Azure AD admin for SQL Managed Instance, which doesn't exist in SQL Managed Instance system views, apply special fixed permissions of the Azure AD admin for SQL Managed Instance (legacy mode).
179-
4. If the Azure AD account exists as directly mapped to an Azure AD user in a database, which is present in sys.database_principals as type "E," grant access and apply permissions of the Azure AD database user.
180-
5. If the Azure AD account is a member of an Azure AD group that's mapped to an Azure AD user in a database, which is present in sys.database_principals as type "X," grant access and apply permissions of the Azure AD group login.
181-
6. If there's an Azure AD login mapped to either an Azure AD user account or an Azure AD group account, which resolves to the user who's authenticating, all permissions from this Azure AD login are applied.
177+
1. If the Azure AD account is a member of an Azure AD group that's mapped to the Azure AD server principal (login), which is present in sys.server_principals as type "X," grant access and apply permissions of the Azure AD group login.
178+
1. If the Azure AD account exists as directly mapped to an Azure AD user in a database, which is present in sys.database_principals as type "E," grant access and apply permissions of the Azure AD database user.
179+
1. If the Azure AD account is a member of an Azure AD group that's mapped to an Azure AD user in a database, which is present in sys.database_principals as type "X," grant access and apply permissions of the Azure AD group user.
182180

183181
### Service key and service master key
184182

0 commit comments

Comments
 (0)