小编Fin*_*rta的帖子

通过具有 MFA(Active Directory 交互)的 PowerShell 对 SQL Server 进行身份验证

我正在尝试设置一个 PowerShell 脚本以在我们的 Azure SQL Server 数据库上启用始终加密。我正在遵循本指南,其中提供了以下示例代码:

# Import the SqlServer module
Import-Module "SqlServer"  

# Connect to your database
# Set the valid server name, database name and authentication keywords in the connection string
$serverName = "<Azure SQL server name>.database.windows.net"
$databaseName = "<database name>"
$connStr = "Server = " + $serverName + "; Database = " + $databaseName + "; Authentication = Active Directory Integrated"
$database = Get-SqlDatabase -ConnectionString $connStr

# List column master keys for the specified …
Run Code Online (Sandbox Code Playgroud)

sql-server powershell azure-sql-database always-encrypted

2
推荐指数
1
解决办法
2729
查看次数