You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: public/Connect-DbaInstance.ps1
+41-2Lines changed: 41 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -144,6 +144,15 @@ function Connect-DbaInstance {
144
144
Authenticates to Azure SQL Database using an access token generated by Get-AzAccessToken or New-DbaAzAccessToken.
145
145
Use this for service principal authentication or when integrating with Azure automation that provides pre-generated tokens. Tokens expire after one hour and cannot be renewed.
146
146
147
+
.PARAMETERAuthenticationType
148
+
Specifies the authentication method for connecting to Azure SQL or Entra ID-protected SQL Server instances.
149
+
Use "ActiveDirectoryInteractive" for Entra ID (Azure AD) authentication with MFA — a browser dialog will prompt you to select your Entra ID account.
150
+
Use "ActiveDirectoryIntegrated" for Entra ID integrated authentication using your current Windows session.
151
+
Use "ActiveDirectoryPassword" for Entra ID authentication with a username and password via SqlCredential.
152
+
Use "ActiveDirectoryServicePrincipal" for service principal authentication (client ID and secret via SqlCredential).
153
+
Use "ActiveDirectoryManagedIdentity" for managed identity authentication in Azure-hosted environments.
154
+
Use "ActiveDirectoryDeviceCodeFlow" for device code flow authentication.
155
+
147
156
.PARAMETERDedicatedAdminConnection
148
157
Creates a dedicated administrator connection (DAC) for emergency access to SQL Server.
149
158
Use this when SQL Server is unresponsive to regular connections, allowing you to diagnose and resolve critical issues. Remember to manually disconnect the connection when finished.
@@ -343,6 +352,25 @@ function Connect-DbaInstance {
343
352
If a server fails due to certificate validation, automatically retries with TrustServerCertificate enabled.
344
353
This provides a secure-by-default approach for mixed environments without requiring separate connection logic.
0 commit comments