diff --git a/swaggerci/security/.gitattributes b/swaggerci/security/.gitattributes
new file mode 100644
index 000000000000..2125666142eb
--- /dev/null
+++ b/swaggerci/security/.gitattributes
@@ -0,0 +1 @@
+* text=auto
\ No newline at end of file
diff --git a/swaggerci/security/.gitignore b/swaggerci/security/.gitignore
new file mode 100644
index 000000000000..7998f37e1e47
--- /dev/null
+++ b/swaggerci/security/.gitignore
@@ -0,0 +1,5 @@
+bin
+obj
+.vs
+tools
+test/*-TestResults.xml
\ No newline at end of file
diff --git a/swaggerci/security/Az.SecurityCenter.csproj b/swaggerci/security/Az.SecurityCenter.csproj
new file mode 100644
index 000000000000..c9379c600b59
--- /dev/null
+++ b/swaggerci/security/Az.SecurityCenter.csproj
@@ -0,0 +1,44 @@
+
+
+
+ 0.1.0
+ 7.1
+ netstandard2.0
+ Library
+ Az.SecurityCenter.private
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter
+ true
+ false
+ ./bin
+ $(OutputPath)
+ Az.SecurityCenter.nuspec
+ true
+
+
+ 1998, 1591
+ true
+
+
+
+
+ false
+ TRACE;DEBUG;NETSTANDARD
+
+
+
+ true
+ true
+ MSSharedLibKey.snk
+ TRACE;RELEASE;NETSTANDARD;SIGN
+
+
+
+
+
+
+
+
+ $(DefaultItemExcludes);resources/**
+
+
+
\ No newline at end of file
diff --git a/swaggerci/security/Az.SecurityCenter.format.ps1xml b/swaggerci/security/Az.SecurityCenter.format.ps1xml
new file mode 100644
index 000000000000..e26ac5e3a374
--- /dev/null
+++ b/swaggerci/security/Az.SecurityCenter.format.ps1xml
@@ -0,0 +1,705 @@
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.SecurityCenterIdentity
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.SecurityCenterIdentity
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Id
+
+
+ ResourceId
+
+
+ RuleId
+
+
+ ScanId
+
+
+ ScanResultId
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.Baseline
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.Baseline
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ExpectedResult
+
+
+ UpdatedTime
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.BaselineAdjustedResult
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.BaselineAdjustedResult
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ResultsNotInBaseline
+
+
+ ResultsOnlyInBaseline
+
+
+ Status
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.BenchmarkReference
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.BenchmarkReference
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Benchmark
+
+
+ Reference
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.QueryCheck
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.QueryCheck
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ColumnName
+
+
+ ExpectedResult
+
+
+ Query
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.Remediation
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.Remediation
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Automated
+
+
+ Description
+
+
+ PortalLink
+
+
+ Script
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.RuleResults
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.RuleResults
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Id
+
+
+ Name
+
+
+ Type
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.RuleResultsInput
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.RuleResultsInput
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ LatestScan
+
+
+ Result
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.RuleResultsProperties
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.RuleResultsProperties
+
+
+
+
+
+
+
+
+
+
+
+ Result
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.RulesResultsInput
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.RulesResultsInput
+
+
+
+
+
+
+
+
+
+
+
+ LatestScan
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.RulesResultsInputResults
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.RulesResultsInputResults
+
+
+
+
+
+
+
+
+
+
+
+ Item
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.Scan
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.Scan
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Id
+
+
+ Name
+
+
+ Type
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.ScanProperties
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.ScanProperties
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Database
+
+
+ EndTime
+
+
+ HighSeverityFailedRulesCount
+
+
+ IsBaselineApplied
+
+
+ LastScanTime
+
+
+ LowSeverityFailedRulesCount
+
+
+ MediumSeverityFailedRulesCount
+
+
+ Server
+
+
+ SqlVersion
+
+
+ StartTime
+
+
+ State
+
+
+ TotalFailedRulesCount
+
+
+ TotalPassedRulesCount
+
+
+ TotalRulesCount
+
+
+ TriggerType
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.ScanResult
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.ScanResult
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Id
+
+
+ Name
+
+
+ Type
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.ScanResultProperties
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.ScanResultProperties
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ IsTrimmed
+
+
+ QueryResult
+
+
+ RuleId
+
+
+ Status
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.VaRule
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.VaRule
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Category
+
+
+ Description
+
+
+ Rationale
+
+
+ RuleId
+
+
+ RuleType
+
+
+ Severity
+
+
+ Title
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.CloudErrorBody
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.CloudErrorBody
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Code
+
+
+ Message
+
+
+ Target
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ErrorAdditionalInfo
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ErrorAdditionalInfo
+
+
+
+
+
+
+
+
+
+
+
+ Type
+
+
+
+
+
+
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.Resource
+
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.Resource
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Id
+
+
+ Name
+
+
+ Type
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/swaggerci/security/Az.SecurityCenter.nuspec b/swaggerci/security/Az.SecurityCenter.nuspec
new file mode 100644
index 000000000000..9eae6070afc6
--- /dev/null
+++ b/swaggerci/security/Az.SecurityCenter.nuspec
@@ -0,0 +1,32 @@
+
+
+
+ Az.SecurityCenter
+ 0.1.0
+ Microsoft Corporation
+ Microsoft Corporation
+ true
+ https://aka.ms/azps-license
+ https://github.com/Azure/azure-powershell
+ Microsoft Azure PowerShell: $(service-name) cmdlets
+
+ Microsoft Corporation. All rights reserved.
+ Azure ResourceManager ARM PSModule $(service-name)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/swaggerci/security/Az.SecurityCenter.psd1 b/swaggerci/security/Az.SecurityCenter.psd1
new file mode 100644
index 000000000000..30fbd9b1563d
--- /dev/null
+++ b/swaggerci/security/Az.SecurityCenter.psd1
@@ -0,0 +1,24 @@
+@{
+ GUID = '4adbc6f1-550c-4369-9c2a-33541458a7b1'
+ RootModule = './Az.SecurityCenter.psm1'
+ ModuleVersion = '0.1.0'
+ CompatiblePSEditions = 'Core', 'Desktop'
+ Author = 'Microsoft Corporation'
+ CompanyName = 'Microsoft Corporation'
+ Copyright = 'Microsoft Corporation. All rights reserved.'
+ Description = 'Microsoft Azure PowerShell: SecurityCenter cmdlets'
+ PowerShellVersion = '5.1'
+ DotNetFrameworkVersion = '4.7.2'
+ RequiredAssemblies = './bin/Az.SecurityCenter.private.dll'
+ FormatsToProcess = './Az.SecurityCenter.format.ps1xml'
+ FunctionsToExport = 'Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule', 'Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule', 'Get-AzSecurityCenterSqlVulnerabilityAssessmentScan', 'Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult', 'New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule', 'Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule', '*'
+ AliasesToExport = '*'
+ PrivateData = @{
+ PSData = @{
+ Tags = 'Azure', 'ResourceManager', 'ARM', 'PSModule', 'SecurityCenter'
+ LicenseUri = 'https://aka.ms/azps-license'
+ ProjectUri = 'https://github.com/Azure/azure-powershell'
+ ReleaseNotes = ''
+ }
+ }
+}
diff --git a/swaggerci/security/Az.SecurityCenter.psm1 b/swaggerci/security/Az.SecurityCenter.psm1
new file mode 100644
index 000000000000..e1ad8dbcf597
--- /dev/null
+++ b/swaggerci/security/Az.SecurityCenter.psm1
@@ -0,0 +1,107 @@
+# region Generated
+ # ----------------------------------------------------------------------------------
+ # Copyright (c) Microsoft Corporation. All rights reserved.
+# Licensed under the MIT License. See License.txt in the project root for license information.
+# Code generated by Microsoft (R) AutoRest Code Generator.
+# Changes may cause incorrect behavior and will be lost if the code is regenerated.
+ # ----------------------------------------------------------------------------------
+ # Load required Az.Accounts module
+ $accountsName = 'Az.Accounts'
+ $accountsModule = Get-Module -Name $accountsName
+ if(-not $accountsModule) {
+ $localAccountsPath = Join-Path $PSScriptRoot 'generated/modules'
+ if(Test-Path -Path $localAccountsPath) {
+ $localAccounts = Get-ChildItem -Path $localAccountsPath -Recurse -Include 'Az.Accounts.psd1' | Select-Object -Last 1
+ if($localAccounts) {
+ $accountsModule = Import-Module -Name ($localAccounts.FullName) -Scope Global -PassThru
+ }
+ }
+ if(-not $accountsModule) {
+ $hasAdequateVersion = (Get-Module -Name $accountsName -ListAvailable | Where-Object { $_.Version -ge [System.Version]'2.7.5' } | Measure-Object).Count -gt 0
+ if($hasAdequateVersion) {
+ $accountsModule = Import-Module -Name $accountsName -MinimumVersion 2.7.5 -Scope Global -PassThru
+ }
+ }
+ }
+
+ if(-not $accountsModule) {
+ Write-Error "`nThis module requires $accountsName version 2.7.5 or greater. For installation instructions, please see: https://learn.microsoft.com/powershell/azure/install-az-ps" -ErrorAction Stop
+ } elseif (($accountsModule.Version -lt [System.Version]'2.7.5') -and (-not $localAccounts)) {
+ Write-Error "`nThis module requires $accountsName version 2.7.5 or greater. An earlier version of Az.Accounts is imported in the current PowerShell session. If you are running test, please try to add the switch '-RegenerateSupportModule' when executing 'test-module.ps1'. Otherwise please open a new PowerShell session and import this module again.`nAdditionally, this error could indicate that multiple incompatible versions of Azure PowerShell modules are installed on your system. For troubleshooting information, please see: https://aka.ms/azps-version-error" -ErrorAction Stop
+ }
+ Write-Information "Loaded Module '$($accountsModule.Name)'"
+
+ # Load the private module dll
+ $null = Import-Module -Name (Join-Path $PSScriptRoot './bin/Az.SecurityCenter.private.dll')
+
+ # Get the private module's instance
+ $instance = [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Module]::Instance
+
+ # Ask for the shared functionality table
+ $VTable = Register-AzModule
+
+ # Tweaks the pipeline on module load
+ $instance.OnModuleLoad = $VTable.OnModuleLoad
+
+ # Following two delegates are added for telemetry
+ $instance.GetTelemetryId = $VTable.GetTelemetryId
+ $instance.Telemetry = $VTable.Telemetry
+
+
+ # Tweaks the pipeline per call
+ $instance.OnNewRequest = $VTable.OnNewRequest
+
+ # Gets shared parameter values
+ $instance.GetParameterValue = $VTable.GetParameterValue
+
+ # Allows shared module to listen to events from this module
+ $instance.EventListener = $VTable.EventListener
+
+ # Gets shared argument completers
+ $instance.ArgumentCompleter = $VTable.ArgumentCompleter
+
+ # The name of the currently selected Azure profile
+ $instance.ProfileName = $VTable.ProfileName
+
+
+ # Load the custom module
+ $customModulePath = Join-Path $PSScriptRoot './custom/Az.SecurityCenter.custom.psm1'
+ if(Test-Path $customModulePath) {
+ $null = Import-Module -Name $customModulePath
+ }
+
+ # Export nothing to clear implicit exports
+ Export-ModuleMember
+
+ # Export proxy cmdlet scripts
+ $exportsPath = Join-Path $PSScriptRoot './exports'
+ $directories = Get-ChildItem -Directory -Path $exportsPath
+ $profileDirectory = $null
+ if($instance.ProfileName) {
+ if(($directories | ForEach-Object { $_.Name }) -contains $instance.ProfileName) {
+ $profileDirectory = $directories | Where-Object { $_.Name -eq $instance.ProfileName }
+ } else {
+ # Don't export anything if the profile doesn't exist for the module
+ $exportsPath = $null
+ Write-Warning "Selected Azure profile '$($instance.ProfileName)' does not exist for module '$($instance.Name)'. No cmdlets were loaded."
+ }
+ } elseif(($directories | Measure-Object).Count -gt 0) {
+ # Load the last folder if no profile is selected
+ $profileDirectory = $directories | Select-Object -Last 1
+ }
+
+ if($profileDirectory) {
+ Write-Information "Loaded Azure profile '$($profileDirectory.Name)' for module '$($instance.Name)'"
+ $exportsPath = $profileDirectory.FullName
+ }
+
+ if($exportsPath) {
+ Get-ChildItem -Path $exportsPath -Recurse -Include '*.ps1' -File | ForEach-Object { . $_.FullName }
+ $cmdletNames = Get-ScriptCmdlet -ScriptFolder $exportsPath
+ Export-ModuleMember -Function $cmdletNames -Alias (Get-ScriptCmdlet -ScriptFolder $exportsPath -AsAlias)
+ }
+
+ # Finalize initialization of this module
+ $instance.Init();
+ Write-Information "Loaded Module '$($instance.Name)'"
+# endregion
diff --git a/swaggerci/security/MSSharedLibKey.snk b/swaggerci/security/MSSharedLibKey.snk
new file mode 100644
index 000000000000..695f1b38774e
Binary files /dev/null and b/swaggerci/security/MSSharedLibKey.snk differ
diff --git a/swaggerci/security/README.md b/swaggerci/security/README.md
new file mode 100644
index 000000000000..b3b4bceaad9b
--- /dev/null
+++ b/swaggerci/security/README.md
@@ -0,0 +1,27 @@
+
+# Az.SecurityCenter
+This directory contains the PowerShell module for the SecurityCenter service.
+
+---
+## Status
+[](https://www.powershellgallery.com/packages/Az.SecurityCenter/)
+
+## Info
+- Modifiable: yes
+- Generated: all
+- Committed: yes
+- Packaged: yes
+
+---
+## Detail
+This module was primarily generated via [AutoRest](https://github.com/Azure/autorest) using the [PowerShell](https://github.com/Azure/autorest.powershell) extension.
+
+## Module Requirements
+- [Az.Accounts module](https://www.powershellgallery.com/packages/Az.Accounts/), version 2.7.5 or greater
+
+## Authentication
+AutoRest does not generate authentication code for the module. Authentication is handled via Az.Accounts by altering the HTTP payload before it is sent.
+
+## Development
+For information on how to develop for `Az.SecurityCenter`, see [how-to.md](how-to.md).
+
diff --git a/swaggerci/security/build-module.ps1 b/swaggerci/security/build-module.ps1
new file mode 100644
index 000000000000..361dc26a6c4e
--- /dev/null
+++ b/swaggerci/security/build-module.ps1
@@ -0,0 +1,153 @@
+# ----------------------------------------------------------------------------------
+# Copyright (c) Microsoft Corporation. All rights reserved.
+# Licensed under the MIT License. See License.txt in the project root for license information.
+# Code generated by Microsoft (R) AutoRest Code Generator.
+# Changes may cause incorrect behavior and will be lost if the code is regenerated.
+# ----------------------------------------------------------------------------------
+param([switch]$Isolated, [switch]$Run, [switch]$Test, [switch]$Docs, [switch]$Pack, [switch]$Code, [switch]$Release, [switch]$Debugger, [switch]$NoDocs)
+$ErrorActionPreference = 'Stop'
+
+if($PSEdition -ne 'Core') {
+ Write-Error 'This script requires PowerShell Core to execute. [Note] Generated cmdlets will work in both PowerShell Core or Windows PowerShell.'
+}
+
+if(-not $Isolated -and -not $Debugger) {
+ Write-Host -ForegroundColor Green 'Creating isolated process...'
+ $pwsh = [System.Diagnostics.Process]::GetCurrentProcess().Path
+ & "$pwsh" -NonInteractive -NoLogo -NoProfile -File $MyInvocation.MyCommand.Path @PSBoundParameters -Isolated
+
+ if($LastExitCode -ne 0) {
+ # Build failed. Don't attempt to run the module.
+ return
+ }
+
+ if($Test) {
+ . (Join-Path $PSScriptRoot 'test-module.ps1')
+ if($LastExitCode -ne 0) {
+ # Tests failed. Don't attempt to run the module.
+ return
+ }
+ }
+
+ if($Docs) {
+ . (Join-Path $PSScriptRoot 'generate-help.ps1')
+ if($LastExitCode -ne 0) {
+ # Docs generation failed. Don't attempt to run the module.
+ return
+ }
+ }
+
+ if($Pack) {
+ . (Join-Path $PSScriptRoot 'pack-module.ps1')
+ if($LastExitCode -ne 0) {
+ # Packing failed. Don't attempt to run the module.
+ return
+ }
+ }
+
+ $runModulePath = Join-Path $PSScriptRoot 'run-module.ps1'
+ if($Code) {
+ . $runModulePath -Code
+ } elseif($Run) {
+ . $runModulePath
+ } else {
+ Write-Host -ForegroundColor Cyan "To run this module in an isolated PowerShell session, run the 'run-module.ps1' script or provide the '-Run' parameter to this script."
+ }
+ return
+}
+
+$binFolder = Join-Path $PSScriptRoot 'bin'
+$objFolder = Join-Path $PSScriptRoot 'obj'
+
+if(-not $Debugger) {
+ Write-Host -ForegroundColor Green 'Cleaning build folders...'
+ $null = Remove-Item -Recurse -ErrorAction SilentlyContinue -Path $binFolder, $objFolder
+
+ if((Test-Path $binFolder) -or (Test-Path $objFolder)) {
+ Write-Host -ForegroundColor Cyan 'Did you forget to exit your isolated module session before rebuilding?'
+ Write-Error 'Unable to clean ''bin'' or ''obj'' folder. A process may have an open handle.'
+ }
+
+ Write-Host -ForegroundColor Green 'Compiling module...'
+ $buildConfig = 'Debug'
+ if($Release) {
+ $buildConfig = 'Release'
+ }
+ dotnet publish $PSScriptRoot --verbosity quiet --configuration $buildConfig /nologo
+ if($LastExitCode -ne 0) {
+ Write-Error 'Compilation failed.'
+ }
+
+ $null = Remove-Item -Recurse -ErrorAction SilentlyContinue -Path (Join-Path $binFolder 'Debug'), (Join-Path $binFolder 'Release')
+}
+
+$dll = Join-Path $PSScriptRoot 'bin/Az.SecurityCenter.private.dll'
+if(-not (Test-Path $dll)) {
+ Write-Error "Unable to find output assembly in '$binFolder'."
+}
+
+# Load DLL to use build-time cmdlets
+$null = Import-Module -Name $dll
+
+$modulePaths = $dll
+$customPsm1 = Join-Path $PSScriptRoot 'custom/Az.SecurityCenter.custom.psm1'
+if(Test-Path $customPsm1) {
+ $modulePaths = @($dll, $customPsm1)
+}
+
+$exportsFolder = Join-Path $PSScriptRoot 'exports'
+if(Test-Path $exportsFolder) {
+ $null = Get-ChildItem -Path $exportsFolder -Recurse -Exclude 'README.md' | Remove-Item -Recurse -ErrorAction SilentlyContinue
+}
+$null = New-Item -ItemType Directory -Force -Path $exportsFolder
+
+$internalFolder = Join-Path $PSScriptRoot 'internal'
+if(Test-Path $internalFolder) {
+ $null = Get-ChildItem -Path $internalFolder -Recurse -Exclude '*.psm1', 'README.md' | Remove-Item -Recurse -ErrorAction SilentlyContinue
+}
+$null = New-Item -ItemType Directory -Force -Path $internalFolder
+
+$psd1 = Join-Path $PSScriptRoot './Az.SecurityCenter.psd1'
+$guid = Get-ModuleGuid -Psd1Path $psd1
+$moduleName = 'Az.SecurityCenter'
+$examplesFolder = Join-Path $PSScriptRoot 'examples'
+$null = New-Item -ItemType Directory -Force -Path $examplesFolder
+
+Write-Host -ForegroundColor Green 'Creating cmdlets for specified models...'
+$modelCmdlets = @()
+if ($modelCmdlets.Count -gt 0) {
+ . (Join-Path $PSScriptRoot 'create-model-cmdlets.ps1')
+ CreateModelCmdlet($modelCmdlets)
+}
+
+if($NoDocs) {
+ Write-Host -ForegroundColor Green 'Creating exports...'
+ Export-ProxyCmdlet -ModuleName $moduleName -ModulePath $modulePaths -ExportsFolder $exportsFolder -InternalFolder $internalFolder -ExcludeDocs -ExamplesFolder $examplesFolder
+} else {
+ Write-Host -ForegroundColor Green 'Creating exports and docs...'
+ $moduleDescription = 'Microsoft Azure PowerShell: SecurityCenter cmdlets'
+ $docsFolder = Join-Path $PSScriptRoot 'docs'
+ if(Test-Path $docsFolder) {
+ $null = Get-ChildItem -Path $docsFolder -Recurse -Exclude 'README.md' | Remove-Item -Recurse -ErrorAction SilentlyContinue
+ }
+ $null = New-Item -ItemType Directory -Force -Path $docsFolder
+ Export-ProxyCmdlet -ModuleName $moduleName -ModulePath $modulePaths -ExportsFolder $exportsFolder -InternalFolder $internalFolder -ModuleDescription $moduleDescription -DocsFolder $docsFolder -ExamplesFolder $examplesFolder -ModuleGuid $guid
+}
+
+Write-Host -ForegroundColor Green 'Creating format.ps1xml...'
+$formatPs1xml = Join-Path $PSScriptRoot './Az.SecurityCenter.format.ps1xml'
+Export-FormatPs1xml -FilePath $formatPs1xml
+
+Write-Host -ForegroundColor Green 'Creating psd1...'
+$customFolder = Join-Path $PSScriptRoot 'custom'
+Export-Psd1 -ExportsFolder $exportsFolder -CustomFolder $customFolder -Psd1Path $psd1 -ModuleGuid $guid
+
+Write-Host -ForegroundColor Green 'Creating test stubs...'
+$testFolder = Join-Path $PSScriptRoot 'test'
+$null = New-Item -ItemType Directory -Force -Path $testFolder
+Export-TestStub -ModuleName $moduleName -ExportsFolder $exportsFolder -OutputFolder $testFolder
+
+Write-Host -ForegroundColor Green 'Creating example stubs...'
+Export-ExampleStub -ExportsFolder $exportsFolder -OutputFolder $examplesFolder
+
+Write-Host -ForegroundColor Green '-------------Done-------------'
diff --git a/swaggerci/security/check-dependencies.ps1 b/swaggerci/security/check-dependencies.ps1
new file mode 100644
index 000000000000..ec3055201a71
--- /dev/null
+++ b/swaggerci/security/check-dependencies.ps1
@@ -0,0 +1,57 @@
+# ----------------------------------------------------------------------------------
+# Copyright (c) Microsoft Corporation. All rights reserved.
+# Licensed under the MIT License. See License.txt in the project root for license information.
+# Code generated by Microsoft (R) AutoRest Code Generator.
+# Changes may cause incorrect behavior and will be lost if the code is regenerated.
+# ----------------------------------------------------------------------------------
+param([switch]$Isolated, [switch]$Accounts, [switch]$Pester, [switch]$Resources)
+$ErrorActionPreference = 'Stop'
+
+if(-not $Isolated) {
+ Write-Host -ForegroundColor Green 'Creating isolated process...'
+ $pwsh = [System.Diagnostics.Process]::GetCurrentProcess().Path
+ & "$pwsh" -NoExit -NoLogo -NoProfile -File $MyInvocation.MyCommand.Path @PSBoundParameters -Isolated
+ return
+}
+
+function DownloadModule ([bool]$predicate, [string]$path, [string]$moduleName, [string]$versionMinimum, [string]$requiredVersion) {
+ if($predicate) {
+ $module = Get-Module -ListAvailable -Name $moduleName
+ if((-not $module) -or ($versionMinimum -and ($module | ForEach-Object { $_.Version } | Where-Object { $_ -ge [System.Version]$versionMinimum } | Measure-Object).Count -eq 0) -or ($requiredVersion -and ($module | ForEach-Object { $_.Version } | Where-Object { $_ -eq [System.Version]$requiredVersion } | Measure-Object).Count -eq 0)) {
+ $null = New-Item -ItemType Directory -Force -Path $path
+ Write-Host -ForegroundColor Green "Installing local $moduleName module into '$path'..."
+ if ($requiredVersion) {
+ Find-Module -Name $moduleName -RequiredVersion $requiredVersion -Repository PSGallery | Save-Module -Path $path
+ }elseif($versionMinimum) {
+ Find-Module -Name $moduleName -MinimumVersion $versionMinimum -Repository PSGallery | Save-Module -Path $path
+ } else {
+ Find-Module -Name $moduleName -Repository PSGallery | Save-Module -Path $path
+ }
+ }
+ }
+}
+
+$ProgressPreference = 'SilentlyContinue'
+$all = (@($Accounts.IsPresent, $Pester.IsPresent) | Select-Object -Unique | Measure-Object).Count -eq 1
+
+$localModulesPath = Join-Path $PSScriptRoot 'generated/modules'
+if(Test-Path -Path $localModulesPath) {
+ $env:PSModulePath = "$localModulesPath$([IO.Path]::PathSeparator)$env:PSModulePath"
+}
+
+DownloadModule -predicate ($all -or $Accounts) -path $localModulesPath -moduleName 'Az.Accounts' -versionMinimum '2.7.5'
+DownloadModule -predicate ($all -or $Pester) -path $localModulesPath -moduleName 'Pester' -requiredVersion '4.10.1'
+
+$tools = Join-Path $PSScriptRoot 'tools'
+$resourceDir = Join-Path $tools 'Resources'
+$resourceModule = Join-Path $HOME '.PSSharedModules\Resources\Az.Resources.TestSupport.psm1'
+
+if ($Resources.IsPresent -and ((-not (Test-Path -Path $resourceModule)) -or $RegenerateSupportModule.IsPresent)) {
+ Write-Host -ForegroundColor Green "Building local Resource module used for test..."
+ Set-Location $resourceDir
+ $null = autorest .\README.md --use:@autorest/powershell@3.0.414 --output-folder=$HOME/.PSSharedModules/Resources
+ $null = Copy-Item custom/* $HOME/.PSSharedModules/Resources/custom/
+ Set-Location $HOME/.PSSharedModules/Resources
+ $null = .\build-module.ps1
+ Set-Location $PSScriptRoot
+}
diff --git a/swaggerci/security/create-model-cmdlets.ps1 b/swaggerci/security/create-model-cmdlets.ps1
new file mode 100644
index 000000000000..f7cb51f73e89
--- /dev/null
+++ b/swaggerci/security/create-model-cmdlets.ps1
@@ -0,0 +1,163 @@
+# ----------------------------------------------------------------------------------
+# Copyright (c) Microsoft Corporation. All rights reserved.
+# Licensed under the MIT License. See License.txt in the project root for license information.
+# Code generated by Microsoft (R) AutoRest Code Generator.
+# Changes may cause incorrect behavior and will be lost if the code is regenerated.
+# ----------------------------------------------------------------------------------
+
+function CreateModelCmdlet {
+
+ param([string[]]$Models)
+
+ if ($Models.Count -eq 0)
+ {
+ return
+ }
+
+ $ModelCsPath = Join-Path (Join-Path $PSScriptRoot 'generated/api') 'Models'
+ $ModuleName = 'SecurityCenter'
+ $OutputDir = Join-Path $PSScriptRoot 'custom/autogen-model-cmdlets'
+ $null = New-Item -ItemType Directory -Force -Path $OutputDir
+
+ $CsFiles = Get-ChildItem -Path $ModelCsPath -Recurse -Filter *.cs
+ $Content = ''
+ $null = $CsFiles | ForEach-Object -Process { if ($_.Name.Split('.').count -eq 2 )
+ { $Content += get-content $_.fullname -raw
+ } }
+
+ $Tree = [Microsoft.CodeAnalysis.CSharp.SyntaxFactory]::ParseCompilationUnit($Content)
+ $Nodes = $Tree.ChildNodes().ChildNodes()
+ foreach ($Model in $Models)
+ {
+ $InterfaceNode = $Nodes | Where-Object { ($_.Keyword.value -eq 'interface') -and ($_.Identifier.value -eq "I$Model") }
+ if ($InterfaceNode.count -eq 0) {
+ continue
+ }
+ # through a queue, we iterate all the parent models.
+ $Queue = @($InterfaceNode)
+ $visited = @("I$Model")
+ $AllInterfaceNodes = @()
+ while ($Queue.count -ne 0)
+ {
+ $AllInterfaceNodes += $Queue[0]
+ # Baselist contains the direct parent models.
+ foreach ($parent in $Queue[0].BaseList.Types)
+ {
+ if (($parent.Type.Right.Identifier.Value -ne 'IJsonSerializable') -and (-not $visited.Contains($parent.Type.Right.Identifier.Value)))
+ {
+ $Queue = [Array]$Queue + ($Nodes | Where-Object { ($_.Keyword.value -eq 'interface') -and ($_.Identifier.value -eq $parent.Type.Right.Identifier.Value) })
+ $visited = [Array]$visited + $parent.Type.Right.Identifier.Value
+ }
+ }
+ $first, $Queue = $Queue
+ }
+
+ $Namespace = $InterfaceNode.Parent.Name
+ $ObjectType = $Model
+ $ObjectTypeWithNamespace = "${Namespace}.${ObjectType}"
+ # remove duplicated module name
+ if ($ObjectType.StartsWith($ModuleName)) {
+ $ModulePrefix = ''
+ } else {
+ $ModulePrefix = $ModuleName
+ }
+ $OutputPath = Join-Path -ChildPath "New-Az${ModulePrefix}${ObjectType}Object.ps1" -Path $OutputDir
+
+ $ParameterDefineScriptList = New-Object System.Collections.Generic.List[string]
+ $ParameterAssignScriptList = New-Object System.Collections.Generic.List[string]
+ foreach ($Node in $AllInterfaceNodes)
+ {
+ foreach ($Member in $Node.Members)
+ {
+ $Arguments = $Member.AttributeLists.Attributes.ArgumentList.Arguments
+ $Required = $false
+ $Description = ""
+ $Readonly = $False
+ foreach ($Argument in $Arguments)
+ {
+ if ($Argument.NameEquals.Name.Identifier.Value -eq "Required")
+ {
+ $Required = $Argument.Expression.Token.Value
+ }
+ if ($Argument.NameEquals.Name.Identifier.Value -eq "Description")
+ {
+ $Description = $Argument.Expression.Token.Value.Trim('.').replace('"', '`"')
+ }
+ if ($Argument.NameEquals.Name.Identifier.Value -eq "Readonly")
+ {
+ $Readonly = $Argument.Expression.Token.Value
+ }
+ }
+ if ($Readonly)
+ {
+ continue
+ }
+ $Identifier = $Member.Identifier.Value
+ $Type = $Member.Type.ToString().replace('?', '').Split("::")[-1]
+ $ParameterDefinePropertyList = New-Object System.Collections.Generic.List[string]
+ if ($Required)
+ {
+ $ParameterDefinePropertyList.Add("Mandatory")
+ }
+ if ($Description -ne "")
+ {
+ $ParameterDefinePropertyList.Add("HelpMessage=`"${Description}.`"")
+ }
+ $ParameterDefineProperty = [System.String]::Join(", ", $ParameterDefinePropertyList)
+ # check whether completer is needed
+ $completer = '';
+ if($Type.Split('.').Split('.')[-2] -eq 'Support') {
+ # If Type is an array, need to strip []
+ $strippedType = $Type.Replace('[]', '')
+ $completer += "`n [ArgumentCompleter([${strippedType}])]"
+ }
+ $ParameterDefineScript = "
+ [Parameter($ParameterDefineProperty)]${completer}
+ [${Type}]
+ `$${Identifier}"
+ $ParameterDefineScriptList.Add($ParameterDefineScript)
+ $ParameterAssignScriptList.Add("
+ if (`$PSBoundParameters.ContainsKey('${Identifier}')) {
+ `$Object.${Identifier} = `$${Identifier}
+ }")
+ }
+ }
+ $ParameterDefineScript = $ParameterDefineScriptList | Join-String -Separator ","
+ $ParameterAssignScript = $ParameterAssignScriptList | Join-String -Separator ""
+
+ $Script = "
+# ----------------------------------------------------------------------------------
+# Copyright (c) Microsoft Corporation. All rights reserved.
+# Licensed under the MIT License. See License.txt in the project root for license information.
+# Code generated by Microsoft (R) AutoRest Code Generator.
+# Changes may cause incorrect behavior and will be lost if the code is regenerated.
+# ----------------------------------------------------------------------------------
+
+<#
+.Synopsis
+Create an in-memory object for ${ObjectType}.
+.Description
+Create an in-memory object for ${ObjectType}.
+
+.Outputs
+${ObjectTypeWithNamespace}
+.Link
+https://learn.microsoft.com/powershell/module/az.${ModuleName}/new-Az${ModulePrefix}${ObjectType}Object
+#>
+function New-Az${ModulePrefix}${ObjectType}Object {
+ [OutputType('${ObjectTypeWithNamespace}')]
+ [CmdletBinding(PositionalBinding=`$false)]
+ Param(
+${ParameterDefineScript}
+ )
+
+ process {
+ `$Object = [${ObjectTypeWithNamespace}]::New()
+${ParameterAssignScript}
+ return `$Object
+ }
+}
+"
+ Set-Content -Path $OutputPath -Value $Script
+ }
+}
diff --git a/swaggerci/security/custom/Az.SecurityCenter.custom.psm1 b/swaggerci/security/custom/Az.SecurityCenter.custom.psm1
new file mode 100644
index 000000000000..eab7d9dcab72
--- /dev/null
+++ b/swaggerci/security/custom/Az.SecurityCenter.custom.psm1
@@ -0,0 +1,17 @@
+# region Generated
+ # Load the private module dll
+ $null = Import-Module -PassThru -Name (Join-Path $PSScriptRoot '../bin/Az.SecurityCenter.private.dll')
+
+ # Load the internal module
+ $internalModulePath = Join-Path $PSScriptRoot '../internal/Az.SecurityCenter.internal.psm1'
+ if(Test-Path $internalModulePath) {
+ $null = Import-Module -Name $internalModulePath
+ }
+
+ # Export nothing to clear implicit exports
+ Export-ModuleMember
+
+ # Export script cmdlets
+ Get-ChildItem -Path $PSScriptRoot -Recurse -Include '*.ps1' -File | ForEach-Object { . $_.FullName }
+ Export-ModuleMember -Function (Get-ScriptCmdlet -ScriptFolder $PSScriptRoot) -Alias (Get-ScriptCmdlet -ScriptFolder $PSScriptRoot -AsAlias)
+# endregion
diff --git a/swaggerci/security/custom/README.md b/swaggerci/security/custom/README.md
new file mode 100644
index 000000000000..b6af9de6e229
--- /dev/null
+++ b/swaggerci/security/custom/README.md
@@ -0,0 +1,41 @@
+# Custom
+This directory contains custom implementation for non-generated cmdlets for the `Az.SecurityCenter` module. Both scripts (`.ps1`) and C# files (`.cs`) can be implemented here. They will be used during the build process in `build-module.ps1`, and create cmdlets into the `../exports` folder. The only generated file into this folder is the `Az.SecurityCenter.custom.psm1`. This file should not be modified.
+
+## Info
+- Modifiable: yes
+- Generated: partial
+- Committed: yes
+- Packaged: yes
+
+## Details
+For `Az.SecurityCenter` to use custom cmdlets, it does this two different ways. We **highly recommend** creating script cmdlets, as they are easier to write and allow access to the other exported cmdlets. C# cmdlets *cannot access exported cmdlets*.
+
+For C# cmdlets, they are compiled with the rest of the generated low-level cmdlets into the `./bin/Az.SecurityCenter.private.dll`. The names of the cmdlets (methods) and files must follow the `[cmdletName]_[variantName]` syntax used for generated cmdlets. The `variantName` is used as the `ParameterSetName`, so use something appropriate that doesn't clash with already created variant or parameter set names. You cannot use the `ParameterSetName` property in the `Parameter` attribute on C# cmdlets. Each cmdlet must be separated into variants using the same pattern as seen in the `generated/cmdlets` folder.
+
+For script cmdlets, these are loaded via the `Az.SecurityCenter.custom.psm1`. Then, during the build process, this module is loaded and processed in the same manner as the C# cmdlets. The fundamental difference is the script cmdlets use the `ParameterSetName` attribute and C# cmdlets do not. To create a script cmdlet variant of a generated cmdlet, simply decorate all parameters in the script with the new `ParameterSetName` in the `Parameter` attribute. This will appropriately treat each parameter set as a separate variant when processed to be exported during the build.
+
+## Purpose
+This allows the modules to have cmdlets that were not defined in the REST specification. It also allows combining logic using generated cmdlets. This is a level of customization beyond what can be done using the [readme configuration options](https://github.com/Azure/autorest/blob/master/docs/powershell/options.md) that are currently available. These custom cmdlets are then referenced by the cmdlets created at build-time in the `../exports` folder.
+
+## Usage
+The easiest way currently to start developing custom cmdlets is to copy an existing cmdlet. For C# cmdlets, copy one from the `generated/cmdlets` folder. For script cmdlets, build the project using `build-module.ps1` and copy one of the scripts from the `../exports` folder. After that, if you want to add new parameter sets, follow the guidelines in the `Details` section above. For implementing a new cmdlets, at minimum, please keep these parameters:
+- Break
+- DefaultProfile
+- HttpPipelineAppend
+- HttpPipelinePrepend
+- Proxy
+- ProxyCredential
+- ProxyUseDefaultCredentials
+
+These provide functionality to our HTTP pipeline and other useful features. In script, you can forward these parameters using `$PSBoundParameters` to the other cmdlets you're calling within `Az.SecurityCenter`. For C#, follow the usage seen in the `ProcessRecordAsync` method.
+
+### Attributes
+For processing the cmdlets, we've created some additional attributes:
+- `Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.DescriptionAttribute`
+ - Used in C# cmdlets to provide a high-level description of the cmdlet. This is propagated to reference documentation via [help comments](https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_comment_based_help) in the exported scripts.
+- `Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.DoNotExportAttribute`
+ - Used in C# and script cmdlets to suppress creating an exported cmdlet at build-time. These cmdlets will *not be exposed* by `Az.SecurityCenter`.
+- `Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.InternalExportAttribute`
+ - Used in C# cmdlets to route exported cmdlets to the `../internal`, which are *not exposed* by `Az.SecurityCenter`. For more information, see [README.md](../internal/README.md) in the `../internal` folder.
+- `Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.ProfileAttribute`
+ - Used in C# and script cmdlets to define which Azure profiles the cmdlet supports. This is only supported for Azure (`--azure`) modules.
\ No newline at end of file
diff --git a/swaggerci/security/docs/Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md b/swaggerci/security/docs/Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md
new file mode 100644
index 000000000000..5aa80f9ed5aa
--- /dev/null
+++ b/swaggerci/security/docs/Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md
@@ -0,0 +1,245 @@
+---
+external help file:
+Module Name: Az.SecurityCenter
+online version: https://learn.microsoft.com/powershell/module/az.securitycenter/add-azsecuritycentersqlvulnerabilityassessmentbaselinerule
+schema: 2.0.0
+---
+
+# Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule
+
+## SYNOPSIS
+Add a list of baseline rules.
+Will overwrite any previously existing results (for all rules).
+
+## SYNTAX
+
+### AddExpanded (Default)
+```
+Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule -ResourceId -WorkspaceId
+ [-LatestScan] [-Result ] [-DefaultProfile ] [-Confirm] [-WhatIf] []
+```
+
+### Add
+```
+Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule -ResourceId -WorkspaceId
+ -Body [-DefaultProfile ] [-Confirm] [-WhatIf] []
+```
+
+### AddViaIdentity
+```
+Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule -InputObject
+ -WorkspaceId -Body [-DefaultProfile ] [-Confirm] [-WhatIf]
+ []
+```
+
+### AddViaIdentityExpanded
+```
+Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule -InputObject
+ -WorkspaceId [-LatestScan] [-Result ] [-DefaultProfile ] [-Confirm] [-WhatIf]
+ []
+```
+
+## DESCRIPTION
+Add a list of baseline rules.
+Will overwrite any previously existing results (for all rules).
+
+## EXAMPLES
+
+### Example 1: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+### Example 2: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+## PARAMETERS
+
+### -Body
+Rules results input.
+To construct, see NOTES section for BODY properties and create a hash table.
+
+```yaml
+Type: Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRulesResultsInput
+Parameter Sets: Add, AddViaIdentity
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: True (ByValue)
+Accept wildcard characters: False
+```
+
+### -DefaultProfile
+The credentials, account, tenant, and subscription used for communication with Azure.
+
+```yaml
+Type: System.Management.Automation.PSObject
+Parameter Sets: (All)
+Aliases: AzureRMContext, AzureCredential
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -InputObject
+Identity Parameter
+To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
+
+```yaml
+Type: Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+Parameter Sets: AddViaIdentity, AddViaIdentityExpanded
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: True (ByValue)
+Accept wildcard characters: False
+```
+
+### -LatestScan
+Take results from latest scan.
+
+```yaml
+Type: System.Management.Automation.SwitchParameter
+Parameter Sets: AddExpanded, AddViaIdentityExpanded
+Aliases:
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -ResourceId
+The identifier of the resource.
+
+```yaml
+Type: System.String
+Parameter Sets: Add, AddExpanded
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -Result
+Expected results to be inserted into the baseline.Leave this field empty it LatestScan == true.
+
+```yaml
+Type: System.Collections.Hashtable
+Parameter Sets: AddExpanded, AddViaIdentityExpanded
+Aliases:
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -WorkspaceId
+The workspace Id.
+
+```yaml
+Type: System.String
+Parameter Sets: (All)
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -Confirm
+Prompts you for confirmation before running the cmdlet.
+
+```yaml
+Type: System.Management.Automation.SwitchParameter
+Parameter Sets: (All)
+Aliases: cf
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -WhatIf
+Shows what would happen if the cmdlet runs.
+The cmdlet is not run.
+
+```yaml
+Type: System.Management.Automation.SwitchParameter
+Parameter Sets: (All)
+Aliases: wi
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### CommonParameters
+This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
+
+## INPUTS
+
+### Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRulesResultsInput
+
+### Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+
+## OUTPUTS
+
+### Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRuleResults
+
+## NOTES
+
+ALIASES
+
+COMPLEX PARAMETER PROPERTIES
+
+To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
+
+
+`BODY `: Rules results input.
+ - `[LatestScan ]`: Take results from latest scan.
+ - `[Result ]`: Expected results to be inserted into the baseline. Leave this field empty it LatestScan == true.
+ - `[(Any) ]`: This indicates any property can be added to this object.
+
+`INPUTOBJECT `: Identity Parameter
+ - `[Id ]`: Resource identity path
+ - `[ResourceId ]`: The identifier of the resource.
+ - `[RuleId ]`: The rule Id.
+ - `[ScanId ]`: The scan Id. Type 'latest' to get the scan record for the latest scan.
+ - `[ScanResultId ]`: The rule Id of the results.
+
+## RELATED LINKS
+
diff --git a/swaggerci/security/docs/Az.SecurityCenter.md b/swaggerci/security/docs/Az.SecurityCenter.md
new file mode 100644
index 000000000000..5ee091a96b91
--- /dev/null
+++ b/swaggerci/security/docs/Az.SecurityCenter.md
@@ -0,0 +1,33 @@
+---
+Module Name: Az.SecurityCenter
+Module Guid: 4adbc6f1-550c-4369-9c2a-33541458a7b1
+Download Help Link: https://learn.microsoft.com/powershell/module/az.securitycenter
+Help Version: 1.0.0.0
+Locale: en-US
+---
+
+# Az.SecurityCenter Module
+## Description
+Microsoft Azure PowerShell: SecurityCenter cmdlets
+
+## Az.SecurityCenter Cmdlets
+### [Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule](Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md)
+Add a list of baseline rules.
+Will overwrite any previously existing results (for all rules).
+
+### [Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule](Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md)
+Gets the results for a given rule in the Baseline.
+
+### [Get-AzSecurityCenterSqlVulnerabilityAssessmentScan](Get-AzSecurityCenterSqlVulnerabilityAssessmentScan.md)
+Gets the scan details of a single scan record.
+
+### [Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult](Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult.md)
+Gets the scan results of a single rule in a scan record.
+
+### [New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule](New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md)
+Creates a Baseline for a rule in a database.
+Will overwrite any previously existing results.
+
+### [Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule](Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md)
+Deletes a rule from the Baseline of a given database.
+
diff --git a/swaggerci/security/docs/Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md b/swaggerci/security/docs/Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md
new file mode 100644
index 000000000000..62833bf3c345
--- /dev/null
+++ b/swaggerci/security/docs/Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md
@@ -0,0 +1,166 @@
+---
+external help file:
+Module Name: Az.SecurityCenter
+online version: https://learn.microsoft.com/powershell/module/az.securitycenter/get-azsecuritycentersqlvulnerabilityassessmentbaselinerule
+schema: 2.0.0
+---
+
+# Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule
+
+## SYNOPSIS
+Gets the results for a given rule in the Baseline.
+
+## SYNTAX
+
+### List (Default)
+```
+Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule -ResourceId -WorkspaceId
+ [-DefaultProfile ] []
+```
+
+### Get
+```
+Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule -ResourceId -RuleId
+ -WorkspaceId [-DefaultProfile ] []
+```
+
+### GetViaIdentity
+```
+Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule -InputObject
+ -WorkspaceId [-DefaultProfile ] []
+```
+
+## DESCRIPTION
+Gets the results for a given rule in the Baseline.
+
+## EXAMPLES
+
+### Example 1: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+### Example 2: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+## PARAMETERS
+
+### -DefaultProfile
+The credentials, account, tenant, and subscription used for communication with Azure.
+
+```yaml
+Type: System.Management.Automation.PSObject
+Parameter Sets: (All)
+Aliases: AzureRMContext, AzureCredential
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -InputObject
+Identity Parameter
+To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
+
+```yaml
+Type: Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+Parameter Sets: GetViaIdentity
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: True (ByValue)
+Accept wildcard characters: False
+```
+
+### -ResourceId
+The identifier of the resource.
+
+```yaml
+Type: System.String
+Parameter Sets: Get, List
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -RuleId
+The rule Id.
+
+```yaml
+Type: System.String
+Parameter Sets: Get
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -WorkspaceId
+The workspace Id.
+
+```yaml
+Type: System.String
+Parameter Sets: (All)
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### CommonParameters
+This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
+
+## INPUTS
+
+### Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+
+## OUTPUTS
+
+### Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRuleResults
+
+## NOTES
+
+ALIASES
+
+COMPLEX PARAMETER PROPERTIES
+
+To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
+
+
+`INPUTOBJECT `: Identity Parameter
+ - `[Id ]`: Resource identity path
+ - `[ResourceId ]`: The identifier of the resource.
+ - `[RuleId ]`: The rule Id.
+ - `[ScanId ]`: The scan Id. Type 'latest' to get the scan record for the latest scan.
+ - `[ScanResultId ]`: The rule Id of the results.
+
+## RELATED LINKS
+
diff --git a/swaggerci/security/docs/Get-AzSecurityCenterSqlVulnerabilityAssessmentScan.md b/swaggerci/security/docs/Get-AzSecurityCenterSqlVulnerabilityAssessmentScan.md
new file mode 100644
index 000000000000..ce95811a2511
--- /dev/null
+++ b/swaggerci/security/docs/Get-AzSecurityCenterSqlVulnerabilityAssessmentScan.md
@@ -0,0 +1,167 @@
+---
+external help file:
+Module Name: Az.SecurityCenter
+online version: https://learn.microsoft.com/powershell/module/az.securitycenter/get-azsecuritycentersqlvulnerabilityassessmentscan
+schema: 2.0.0
+---
+
+# Get-AzSecurityCenterSqlVulnerabilityAssessmentScan
+
+## SYNOPSIS
+Gets the scan details of a single scan record.
+
+## SYNTAX
+
+### List (Default)
+```
+Get-AzSecurityCenterSqlVulnerabilityAssessmentScan -ResourceId -WorkspaceId
+ [-DefaultProfile ] []
+```
+
+### Get
+```
+Get-AzSecurityCenterSqlVulnerabilityAssessmentScan -ResourceId -ScanId -WorkspaceId
+ [-DefaultProfile ] []
+```
+
+### GetViaIdentity
+```
+Get-AzSecurityCenterSqlVulnerabilityAssessmentScan -InputObject
+ -WorkspaceId [-DefaultProfile ] []
+```
+
+## DESCRIPTION
+Gets the scan details of a single scan record.
+
+## EXAMPLES
+
+### Example 1: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+### Example 2: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+## PARAMETERS
+
+### -DefaultProfile
+The credentials, account, tenant, and subscription used for communication with Azure.
+
+```yaml
+Type: System.Management.Automation.PSObject
+Parameter Sets: (All)
+Aliases: AzureRMContext, AzureCredential
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -InputObject
+Identity Parameter
+To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
+
+```yaml
+Type: Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+Parameter Sets: GetViaIdentity
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: True (ByValue)
+Accept wildcard characters: False
+```
+
+### -ResourceId
+The identifier of the resource.
+
+```yaml
+Type: System.String
+Parameter Sets: Get, List
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -ScanId
+The scan Id.
+Type 'latest' to get the scan record for the latest scan.
+
+```yaml
+Type: System.String
+Parameter Sets: Get
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -WorkspaceId
+The workspace Id.
+
+```yaml
+Type: System.String
+Parameter Sets: (All)
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### CommonParameters
+This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
+
+## INPUTS
+
+### Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+
+## OUTPUTS
+
+### Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IScan
+
+## NOTES
+
+ALIASES
+
+COMPLEX PARAMETER PROPERTIES
+
+To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
+
+
+`INPUTOBJECT `: Identity Parameter
+ - `[Id ]`: Resource identity path
+ - `[ResourceId ]`: The identifier of the resource.
+ - `[RuleId ]`: The rule Id.
+ - `[ScanId ]`: The scan Id. Type 'latest' to get the scan record for the latest scan.
+ - `[ScanResultId ]`: The rule Id of the results.
+
+## RELATED LINKS
+
diff --git a/swaggerci/security/docs/Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult.md b/swaggerci/security/docs/Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult.md
new file mode 100644
index 000000000000..4adefc858892
--- /dev/null
+++ b/swaggerci/security/docs/Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult.md
@@ -0,0 +1,182 @@
+---
+external help file:
+Module Name: Az.SecurityCenter
+online version: https://learn.microsoft.com/powershell/module/az.securitycenter/get-azsecuritycentersqlvulnerabilityassessmentscanresult
+schema: 2.0.0
+---
+
+# Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult
+
+## SYNOPSIS
+Gets the scan results of a single rule in a scan record.
+
+## SYNTAX
+
+### List (Default)
+```
+Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult -ResourceId -ScanId
+ -WorkspaceId [-DefaultProfile ] []
+```
+
+### Get
+```
+Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult -ResourceId -ScanId
+ -ScanResultId -WorkspaceId [-DefaultProfile ] []
+```
+
+### GetViaIdentity
+```
+Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult -InputObject
+ -WorkspaceId [-DefaultProfile ] []
+```
+
+## DESCRIPTION
+Gets the scan results of a single rule in a scan record.
+
+## EXAMPLES
+
+### Example 1: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+### Example 2: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+## PARAMETERS
+
+### -DefaultProfile
+The credentials, account, tenant, and subscription used for communication with Azure.
+
+```yaml
+Type: System.Management.Automation.PSObject
+Parameter Sets: (All)
+Aliases: AzureRMContext, AzureCredential
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -InputObject
+Identity Parameter
+To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
+
+```yaml
+Type: Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+Parameter Sets: GetViaIdentity
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: True (ByValue)
+Accept wildcard characters: False
+```
+
+### -ResourceId
+The identifier of the resource.
+
+```yaml
+Type: System.String
+Parameter Sets: Get, List
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -ScanId
+The scan Id.
+Type 'latest' to get the scan results for the latest scan.
+
+```yaml
+Type: System.String
+Parameter Sets: Get, List
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -ScanResultId
+The rule Id of the results.
+
+```yaml
+Type: System.String
+Parameter Sets: Get
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -WorkspaceId
+The workspace Id.
+
+```yaml
+Type: System.String
+Parameter Sets: (All)
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### CommonParameters
+This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
+
+## INPUTS
+
+### Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+
+## OUTPUTS
+
+### Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IScanResult
+
+## NOTES
+
+ALIASES
+
+COMPLEX PARAMETER PROPERTIES
+
+To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
+
+
+`INPUTOBJECT `: Identity Parameter
+ - `[Id ]`: Resource identity path
+ - `[ResourceId ]`: The identifier of the resource.
+ - `[RuleId ]`: The rule Id.
+ - `[ScanId ]`: The scan Id. Type 'latest' to get the scan record for the latest scan.
+ - `[ScanResultId ]`: The rule Id of the results.
+
+## RELATED LINKS
+
diff --git a/swaggerci/security/docs/New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md b/swaggerci/security/docs/New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md
new file mode 100644
index 000000000000..f9b1fe7661e4
--- /dev/null
+++ b/swaggerci/security/docs/New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md
@@ -0,0 +1,187 @@
+---
+external help file:
+Module Name: Az.SecurityCenter
+online version: https://learn.microsoft.com/powershell/module/az.securitycenter/new-azsecuritycentersqlvulnerabilityassessmentbaselinerule
+schema: 2.0.0
+---
+
+# New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule
+
+## SYNOPSIS
+Creates a Baseline for a rule in a database.
+Will overwrite any previously existing results.
+
+## SYNTAX
+
+```
+New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule -ResourceId -RuleId
+ -WorkspaceId [-LatestScan] [-Result ] [-DefaultProfile ] [-Confirm] [-WhatIf]
+ []
+```
+
+## DESCRIPTION
+Creates a Baseline for a rule in a database.
+Will overwrite any previously existing results.
+
+## EXAMPLES
+
+### Example 1: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+### Example 2: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+## PARAMETERS
+
+### -DefaultProfile
+The credentials, account, tenant, and subscription used for communication with Azure.
+
+```yaml
+Type: System.Management.Automation.PSObject
+Parameter Sets: (All)
+Aliases: AzureRMContext, AzureCredential
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -LatestScan
+Take results from latest scan.
+
+```yaml
+Type: System.Management.Automation.SwitchParameter
+Parameter Sets: (All)
+Aliases:
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -ResourceId
+The identifier of the resource.
+
+```yaml
+Type: System.String
+Parameter Sets: (All)
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -Result
+Expected results to be inserted into the baseline.Leave this field empty it LatestScan == true.
+
+```yaml
+Type: System.String[][]
+Parameter Sets: (All)
+Aliases:
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -RuleId
+The rule Id.
+
+```yaml
+Type: System.String
+Parameter Sets: (All)
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -WorkspaceId
+The workspace Id.
+
+```yaml
+Type: System.String
+Parameter Sets: (All)
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -Confirm
+Prompts you for confirmation before running the cmdlet.
+
+```yaml
+Type: System.Management.Automation.SwitchParameter
+Parameter Sets: (All)
+Aliases: cf
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -WhatIf
+Shows what would happen if the cmdlet runs.
+The cmdlet is not run.
+
+```yaml
+Type: System.Management.Automation.SwitchParameter
+Parameter Sets: (All)
+Aliases: wi
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### CommonParameters
+This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
+
+## INPUTS
+
+## OUTPUTS
+
+### Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRuleResults
+
+## NOTES
+
+ALIASES
+
+## RELATED LINKS
+
diff --git a/swaggerci/security/docs/README.md b/swaggerci/security/docs/README.md
new file mode 100644
index 000000000000..d7fb9c8d5904
--- /dev/null
+++ b/swaggerci/security/docs/README.md
@@ -0,0 +1,11 @@
+# Docs
+This directory contains the documentation of the cmdlets for the `Az.SecurityCenter` module. To run documentation generation, use the `generate-help.ps1` script at the root module folder. Files in this folder will *always be overridden on regeneration*. To update documentation examples, please use the `../examples` folder.
+
+## Info
+- Modifiable: no
+- Generated: all
+- Committed: yes
+- Packaged: yes
+
+## Details
+The process of documentation generation loads `Az.SecurityCenter` and analyzes the exported cmdlets from the module. It recognizes the [help comments](https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_comment_based_help) that are generated into the scripts in the `../exports` folder. Additionally, when writing custom cmdlets in the `../custom` folder, you can use the help comments syntax, which decorate the exported scripts at build-time. The documentation examples are taken from the `../examples` folder.
\ No newline at end of file
diff --git a/swaggerci/security/docs/Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md b/swaggerci/security/docs/Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md
new file mode 100644
index 000000000000..1062ff4ae7c9
--- /dev/null
+++ b/swaggerci/security/docs/Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md
@@ -0,0 +1,206 @@
+---
+external help file:
+Module Name: Az.SecurityCenter
+online version: https://learn.microsoft.com/powershell/module/az.securitycenter/remove-azsecuritycentersqlvulnerabilityassessmentbaselinerule
+schema: 2.0.0
+---
+
+# Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule
+
+## SYNOPSIS
+Deletes a rule from the Baseline of a given database.
+
+## SYNTAX
+
+### Delete (Default)
+```
+Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule -ResourceId -RuleId
+ -WorkspaceId [-DefaultProfile ] [-PassThru] [-Confirm] [-WhatIf] []
+```
+
+### DeleteViaIdentity
+```
+Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule -InputObject
+ -WorkspaceId [-DefaultProfile ] [-PassThru] [-Confirm] [-WhatIf] []
+```
+
+## DESCRIPTION
+Deletes a rule from the Baseline of a given database.
+
+## EXAMPLES
+
+### Example 1: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+### Example 2: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+## PARAMETERS
+
+### -DefaultProfile
+The credentials, account, tenant, and subscription used for communication with Azure.
+
+```yaml
+Type: System.Management.Automation.PSObject
+Parameter Sets: (All)
+Aliases: AzureRMContext, AzureCredential
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -InputObject
+Identity Parameter
+To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
+
+```yaml
+Type: Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+Parameter Sets: DeleteViaIdentity
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: True (ByValue)
+Accept wildcard characters: False
+```
+
+### -PassThru
+Returns true when the command succeeds
+
+```yaml
+Type: System.Management.Automation.SwitchParameter
+Parameter Sets: (All)
+Aliases:
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -ResourceId
+The identifier of the resource.
+
+```yaml
+Type: System.String
+Parameter Sets: Delete
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -RuleId
+The rule Id.
+
+```yaml
+Type: System.String
+Parameter Sets: Delete
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -WorkspaceId
+The workspace Id.
+
+```yaml
+Type: System.String
+Parameter Sets: (All)
+Aliases:
+
+Required: True
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -Confirm
+Prompts you for confirmation before running the cmdlet.
+
+```yaml
+Type: System.Management.Automation.SwitchParameter
+Parameter Sets: (All)
+Aliases: cf
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### -WhatIf
+Shows what would happen if the cmdlet runs.
+The cmdlet is not run.
+
+```yaml
+Type: System.Management.Automation.SwitchParameter
+Parameter Sets: (All)
+Aliases: wi
+
+Required: False
+Position: Named
+Default value: None
+Accept pipeline input: False
+Accept wildcard characters: False
+```
+
+### CommonParameters
+This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
+
+## INPUTS
+
+### Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+
+## OUTPUTS
+
+### System.Boolean
+
+## NOTES
+
+ALIASES
+
+COMPLEX PARAMETER PROPERTIES
+
+To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
+
+
+`INPUTOBJECT `: Identity Parameter
+ - `[Id ]`: Resource identity path
+ - `[ResourceId ]`: The identifier of the resource.
+ - `[RuleId ]`: The rule Id.
+ - `[ScanId ]`: The scan Id. Type 'latest' to get the scan record for the latest scan.
+ - `[ScanResultId ]`: The rule Id of the results.
+
+## RELATED LINKS
+
diff --git a/swaggerci/security/examples/Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md b/swaggerci/security/examples/Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md
new file mode 100644
index 000000000000..6ee1a83db970
--- /dev/null
+++ b/swaggerci/security/examples/Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md
@@ -0,0 +1,22 @@
+### Example 1: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+### Example 2: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
diff --git a/swaggerci/security/examples/Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md b/swaggerci/security/examples/Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md
new file mode 100644
index 000000000000..6ee1a83db970
--- /dev/null
+++ b/swaggerci/security/examples/Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md
@@ -0,0 +1,22 @@
+### Example 1: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+### Example 2: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
diff --git a/swaggerci/security/examples/Get-AzSecurityCenterSqlVulnerabilityAssessmentScan.md b/swaggerci/security/examples/Get-AzSecurityCenterSqlVulnerabilityAssessmentScan.md
new file mode 100644
index 000000000000..6ee1a83db970
--- /dev/null
+++ b/swaggerci/security/examples/Get-AzSecurityCenterSqlVulnerabilityAssessmentScan.md
@@ -0,0 +1,22 @@
+### Example 1: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+### Example 2: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
diff --git a/swaggerci/security/examples/Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult.md b/swaggerci/security/examples/Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult.md
new file mode 100644
index 000000000000..6ee1a83db970
--- /dev/null
+++ b/swaggerci/security/examples/Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult.md
@@ -0,0 +1,22 @@
+### Example 1: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+### Example 2: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
diff --git a/swaggerci/security/examples/New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md b/swaggerci/security/examples/New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md
new file mode 100644
index 000000000000..6ee1a83db970
--- /dev/null
+++ b/swaggerci/security/examples/New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md
@@ -0,0 +1,22 @@
+### Example 1: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+### Example 2: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
diff --git a/swaggerci/security/examples/Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md b/swaggerci/security/examples/Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md
new file mode 100644
index 000000000000..6ee1a83db970
--- /dev/null
+++ b/swaggerci/security/examples/Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.md
@@ -0,0 +1,22 @@
+### Example 1: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
+### Example 2: {{ Add title here }}
+```powershell
+{{ Add code here }}
+```
+
+```output
+{{ Add output here }}
+```
+
+{{ Add description here }}
+
diff --git a/swaggerci/security/export-surface.ps1 b/swaggerci/security/export-surface.ps1
new file mode 100644
index 000000000000..89d0e4411ae0
--- /dev/null
+++ b/swaggerci/security/export-surface.ps1
@@ -0,0 +1,33 @@
+# ----------------------------------------------------------------------------------
+# Copyright (c) Microsoft Corporation. All rights reserved.
+# Licensed under the MIT License. See License.txt in the project root for license information.
+# Code generated by Microsoft (R) AutoRest Code Generator.
+# Changes may cause incorrect behavior and will be lost if the code is regenerated.
+# ----------------------------------------------------------------------------------
+param([switch]$Isolated, [switch]$IncludeGeneralParameters, [switch]$UseExpandedFormat)
+$ErrorActionPreference = 'Stop'
+
+$pwsh = [System.Diagnostics.Process]::GetCurrentProcess().Path
+if(-not $Isolated) {
+ Write-Host -ForegroundColor Green 'Creating isolated process...'
+ & "$pwsh" -NonInteractive -NoLogo -NoProfile -File $MyInvocation.MyCommand.Path @PSBoundParameters -Isolated
+ return
+}
+
+$dll = Join-Path $PSScriptRoot 'bin/Az.SecurityCenter.private.dll'
+if(-not (Test-Path $dll)) {
+ Write-Error "Unable to find output assembly in '$binFolder'."
+}
+$null = Import-Module -Name $dll
+
+$moduleName = 'Az.SecurityCenter'
+$exportsFolder = Join-Path $PSScriptRoot 'exports'
+$resourcesFolder = Join-Path $PSScriptRoot 'resources'
+
+Export-CmdletSurface -ModuleName $moduleName -CmdletFolder $exportsFolder -OutputFolder $resourcesFolder -IncludeGeneralParameters $IncludeGeneralParameters.IsPresent -UseExpandedFormat $UseExpandedFormat.IsPresent
+Write-Host -ForegroundColor Green "CmdletSurface file(s) created in '$resourcesFolder'"
+
+Export-ModelSurface -OutputFolder $resourcesFolder -UseExpandedFormat $UseExpandedFormat.IsPresent
+Write-Host -ForegroundColor Green "ModelSurface file created in '$resourcesFolder'"
+
+Write-Host -ForegroundColor Green '-------------Done-------------'
\ No newline at end of file
diff --git a/swaggerci/security/exports/Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.ps1 b/swaggerci/security/exports/Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.ps1
new file mode 100644
index 000000000000..9e757f3ff5bd
--- /dev/null
+++ b/swaggerci/security/exports/Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.ps1
@@ -0,0 +1,217 @@
+
+# ----------------------------------------------------------------------------------
+# Copyright (c) Microsoft Corporation. All rights reserved.
+# Licensed under the MIT License. See License.txt in the project root for license information.
+# Code generated by Microsoft (R) AutoRest Code Generator.
+# Changes may cause incorrect behavior and will be lost if the code is regenerated.
+# ----------------------------------------------------------------------------------
+
+<#
+.Synopsis
+Add a list of baseline rules.
+Will overwrite any previously existing results (for all rules).
+.Description
+Add a list of baseline rules.
+Will overwrite any previously existing results (for all rules).
+.Example
+{{ Add code here }}
+.Example
+{{ Add code here }}
+
+.Inputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRulesResultsInput
+.Inputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+.Outputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRuleResults
+.Notes
+COMPLEX PARAMETER PROPERTIES
+
+To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
+
+BODY : Rules results input.
+ [LatestScan ]: Take results from latest scan.
+ [Result ]: Expected results to be inserted into the baseline. Leave this field empty it LatestScan == true.
+ [(Any) ]: This indicates any property can be added to this object.
+
+INPUTOBJECT : Identity Parameter
+ [Id ]: Resource identity path
+ [ResourceId ]: The identifier of the resource.
+ [RuleId ]: The rule Id.
+ [ScanId ]: The scan Id. Type 'latest' to get the scan record for the latest scan.
+ [ScanResultId ]: The rule Id of the results.
+.Link
+https://learn.microsoft.com/powershell/module/az.securitycenter/add-azsecuritycentersqlvulnerabilityassessmentbaselinerule
+#>
+function Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule {
+[OutputType([Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRuleResults])]
+[CmdletBinding(DefaultParameterSetName='AddExpanded', PositionalBinding=$false, SupportsShouldProcess, ConfirmImpact='Medium')]
+param(
+ [Parameter(ParameterSetName='Add', Mandatory)]
+ [Parameter(ParameterSetName='AddExpanded', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The identifier of the resource.
+ ${ResourceId},
+
+ [Parameter(ParameterSetName='AddViaIdentity', Mandatory, ValueFromPipeline)]
+ [Parameter(ParameterSetName='AddViaIdentityExpanded', Mandatory, ValueFromPipeline)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity]
+ # Identity Parameter
+ # To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
+ ${InputObject},
+
+ [Parameter(Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Query')]
+ [System.String]
+ # The workspace Id.
+ ${WorkspaceId},
+
+ [Parameter(ParameterSetName='Add', Mandatory, ValueFromPipeline)]
+ [Parameter(ParameterSetName='AddViaIdentity', Mandatory, ValueFromPipeline)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Body')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRulesResultsInput]
+ # Rules results input.
+ # To construct, see NOTES section for BODY properties and create a hash table.
+ ${Body},
+
+ [Parameter(ParameterSetName='AddExpanded')]
+ [Parameter(ParameterSetName='AddViaIdentityExpanded')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Body')]
+ [System.Management.Automation.SwitchParameter]
+ # Take results from latest scan.
+ ${LatestScan},
+
+ [Parameter(ParameterSetName='AddExpanded')]
+ [Parameter(ParameterSetName='AddViaIdentityExpanded')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Body')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(PossibleTypes=([Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRulesResultsInputResults]))]
+ [System.Collections.Hashtable]
+ # Expected results to be inserted into the baseline.Leave this field empty it LatestScan == true.
+ ${Result},
+
+ [Parameter()]
+ [Alias('AzureRMContext', 'AzureCredential')]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Azure')]
+ [System.Management.Automation.PSObject]
+ # The credentials, account, tenant, and subscription used for communication with Azure.
+ ${DefaultProfile},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Wait for .NET debugger to attach
+ ${Break},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be appended to the front of the pipeline
+ ${HttpPipelineAppend},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be prepended to the front of the pipeline
+ ${HttpPipelinePrepend},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Uri]
+ # The URI for the proxy server to use
+ ${Proxy},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.PSCredential]
+ # Credentials for a proxy server to use for the remote call
+ ${ProxyCredential},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Use the default credentials for the proxy
+ ${ProxyUseDefaultCredentials}
+)
+
+begin {
+ try {
+ $outBuffer = $null
+ if ($PSBoundParameters.TryGetValue('OutBuffer', [ref]$outBuffer)) {
+ $PSBoundParameters['OutBuffer'] = 1
+ }
+ $parameterSet = $PSCmdlet.ParameterSetName
+
+ if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
+ [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $Host.Version.ToString()
+ }
+ $preTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ if ($preTelemetryId -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId =(New-Guid).ToString()
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Create', $MyInvocation, $parameterSet, $PSCmdlet)
+ } else {
+ $internalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ if ($internalCalledCmdlets -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $MyInvocation.MyCommand.Name
+ } else {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets += ',' + $MyInvocation.MyCommand.Name
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = 'internal'
+ }
+
+ $mapping = @{
+ Add = 'Az.SecurityCenter.private\Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_Add';
+ AddExpanded = 'Az.SecurityCenter.private\Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_AddExpanded';
+ AddViaIdentity = 'Az.SecurityCenter.private\Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_AddViaIdentity';
+ AddViaIdentityExpanded = 'Az.SecurityCenter.private\Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_AddViaIdentityExpanded';
+ }
+ $cmdInfo = Get-Command -Name $mapping[$parameterSet]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.MessageAttributeHelper]::ProcessCustomAttributesAtRuntime($cmdInfo, $MyInvocation, $parameterSet, $PSCmdlet)
+ $wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
+ $scriptCmd = {& $wrappedCmd @PSBoundParameters}
+ $steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
+ $steppablePipeline.Begin($PSCmdlet)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+
+process {
+ try {
+ $steppablePipeline.Process($_)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+
+ finally {
+ $backupTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ $backupInternalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+
+}
+end {
+ try {
+ $steppablePipeline.End()
+
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $backupTelemetryId
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $backupInternalCalledCmdlets
+ if ($preTelemetryId -eq '') {
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Send', $MyInvocation, $parameterSet, $PSCmdlet)
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $preTelemetryId
+
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+}
diff --git a/swaggerci/security/exports/Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.ps1 b/swaggerci/security/exports/Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.ps1
new file mode 100644
index 000000000000..b2166f637d7f
--- /dev/null
+++ b/swaggerci/security/exports/Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.ps1
@@ -0,0 +1,189 @@
+
+# ----------------------------------------------------------------------------------
+# Copyright (c) Microsoft Corporation. All rights reserved.
+# Licensed under the MIT License. See License.txt in the project root for license information.
+# Code generated by Microsoft (R) AutoRest Code Generator.
+# Changes may cause incorrect behavior and will be lost if the code is regenerated.
+# ----------------------------------------------------------------------------------
+
+<#
+.Synopsis
+Gets the results for a given rule in the Baseline.
+.Description
+Gets the results for a given rule in the Baseline.
+.Example
+{{ Add code here }}
+.Example
+{{ Add code here }}
+
+.Inputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+.Outputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRuleResults
+.Notes
+COMPLEX PARAMETER PROPERTIES
+
+To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
+
+INPUTOBJECT : Identity Parameter
+ [Id ]: Resource identity path
+ [ResourceId ]: The identifier of the resource.
+ [RuleId ]: The rule Id.
+ [ScanId ]: The scan Id. Type 'latest' to get the scan record for the latest scan.
+ [ScanResultId ]: The rule Id of the results.
+.Link
+https://learn.microsoft.com/powershell/module/az.securitycenter/get-azsecuritycentersqlvulnerabilityassessmentbaselinerule
+#>
+function Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule {
+[OutputType([Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRuleResults])]
+[CmdletBinding(DefaultParameterSetName='List', PositionalBinding=$false)]
+param(
+ [Parameter(ParameterSetName='Get', Mandatory)]
+ [Parameter(ParameterSetName='List', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The identifier of the resource.
+ ${ResourceId},
+
+ [Parameter(ParameterSetName='Get', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The rule Id.
+ ${RuleId},
+
+ [Parameter(ParameterSetName='GetViaIdentity', Mandatory, ValueFromPipeline)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity]
+ # Identity Parameter
+ # To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
+ ${InputObject},
+
+ [Parameter(Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Query')]
+ [System.String]
+ # The workspace Id.
+ ${WorkspaceId},
+
+ [Parameter()]
+ [Alias('AzureRMContext', 'AzureCredential')]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Azure')]
+ [System.Management.Automation.PSObject]
+ # The credentials, account, tenant, and subscription used for communication with Azure.
+ ${DefaultProfile},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Wait for .NET debugger to attach
+ ${Break},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be appended to the front of the pipeline
+ ${HttpPipelineAppend},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be prepended to the front of the pipeline
+ ${HttpPipelinePrepend},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Uri]
+ # The URI for the proxy server to use
+ ${Proxy},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.PSCredential]
+ # Credentials for a proxy server to use for the remote call
+ ${ProxyCredential},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Use the default credentials for the proxy
+ ${ProxyUseDefaultCredentials}
+)
+
+begin {
+ try {
+ $outBuffer = $null
+ if ($PSBoundParameters.TryGetValue('OutBuffer', [ref]$outBuffer)) {
+ $PSBoundParameters['OutBuffer'] = 1
+ }
+ $parameterSet = $PSCmdlet.ParameterSetName
+
+ if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
+ [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $Host.Version.ToString()
+ }
+ $preTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ if ($preTelemetryId -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId =(New-Guid).ToString()
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Create', $MyInvocation, $parameterSet, $PSCmdlet)
+ } else {
+ $internalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ if ($internalCalledCmdlets -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $MyInvocation.MyCommand.Name
+ } else {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets += ',' + $MyInvocation.MyCommand.Name
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = 'internal'
+ }
+
+ $mapping = @{
+ Get = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_Get';
+ GetViaIdentity = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_GetViaIdentity';
+ List = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_List';
+ }
+ $cmdInfo = Get-Command -Name $mapping[$parameterSet]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.MessageAttributeHelper]::ProcessCustomAttributesAtRuntime($cmdInfo, $MyInvocation, $parameterSet, $PSCmdlet)
+ $wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
+ $scriptCmd = {& $wrappedCmd @PSBoundParameters}
+ $steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
+ $steppablePipeline.Begin($PSCmdlet)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+
+process {
+ try {
+ $steppablePipeline.Process($_)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+
+ finally {
+ $backupTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ $backupInternalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+
+}
+end {
+ try {
+ $steppablePipeline.End()
+
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $backupTelemetryId
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $backupInternalCalledCmdlets
+ if ($preTelemetryId -eq '') {
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Send', $MyInvocation, $parameterSet, $PSCmdlet)
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $preTelemetryId
+
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+}
diff --git a/swaggerci/security/exports/Get-AzSecurityCenterSqlVulnerabilityAssessmentScan.ps1 b/swaggerci/security/exports/Get-AzSecurityCenterSqlVulnerabilityAssessmentScan.ps1
new file mode 100644
index 000000000000..9e0ca1e2a4ad
--- /dev/null
+++ b/swaggerci/security/exports/Get-AzSecurityCenterSqlVulnerabilityAssessmentScan.ps1
@@ -0,0 +1,190 @@
+
+# ----------------------------------------------------------------------------------
+# Copyright (c) Microsoft Corporation. All rights reserved.
+# Licensed under the MIT License. See License.txt in the project root for license information.
+# Code generated by Microsoft (R) AutoRest Code Generator.
+# Changes may cause incorrect behavior and will be lost if the code is regenerated.
+# ----------------------------------------------------------------------------------
+
+<#
+.Synopsis
+Gets the scan details of a single scan record.
+.Description
+Gets the scan details of a single scan record.
+.Example
+{{ Add code here }}
+.Example
+{{ Add code here }}
+
+.Inputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+.Outputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IScan
+.Notes
+COMPLEX PARAMETER PROPERTIES
+
+To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
+
+INPUTOBJECT : Identity Parameter
+ [Id ]: Resource identity path
+ [ResourceId ]: The identifier of the resource.
+ [RuleId ]: The rule Id.
+ [ScanId ]: The scan Id. Type 'latest' to get the scan record for the latest scan.
+ [ScanResultId ]: The rule Id of the results.
+.Link
+https://learn.microsoft.com/powershell/module/az.securitycenter/get-azsecuritycentersqlvulnerabilityassessmentscan
+#>
+function Get-AzSecurityCenterSqlVulnerabilityAssessmentScan {
+[OutputType([Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IScan])]
+[CmdletBinding(DefaultParameterSetName='List', PositionalBinding=$false)]
+param(
+ [Parameter(ParameterSetName='Get', Mandatory)]
+ [Parameter(ParameterSetName='List', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The identifier of the resource.
+ ${ResourceId},
+
+ [Parameter(ParameterSetName='Get', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The scan Id.
+ # Type 'latest' to get the scan record for the latest scan.
+ ${ScanId},
+
+ [Parameter(ParameterSetName='GetViaIdentity', Mandatory, ValueFromPipeline)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity]
+ # Identity Parameter
+ # To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
+ ${InputObject},
+
+ [Parameter(Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Query')]
+ [System.String]
+ # The workspace Id.
+ ${WorkspaceId},
+
+ [Parameter()]
+ [Alias('AzureRMContext', 'AzureCredential')]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Azure')]
+ [System.Management.Automation.PSObject]
+ # The credentials, account, tenant, and subscription used for communication with Azure.
+ ${DefaultProfile},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Wait for .NET debugger to attach
+ ${Break},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be appended to the front of the pipeline
+ ${HttpPipelineAppend},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be prepended to the front of the pipeline
+ ${HttpPipelinePrepend},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Uri]
+ # The URI for the proxy server to use
+ ${Proxy},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.PSCredential]
+ # Credentials for a proxy server to use for the remote call
+ ${ProxyCredential},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Use the default credentials for the proxy
+ ${ProxyUseDefaultCredentials}
+)
+
+begin {
+ try {
+ $outBuffer = $null
+ if ($PSBoundParameters.TryGetValue('OutBuffer', [ref]$outBuffer)) {
+ $PSBoundParameters['OutBuffer'] = 1
+ }
+ $parameterSet = $PSCmdlet.ParameterSetName
+
+ if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
+ [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $Host.Version.ToString()
+ }
+ $preTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ if ($preTelemetryId -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId =(New-Guid).ToString()
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Create', $MyInvocation, $parameterSet, $PSCmdlet)
+ } else {
+ $internalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ if ($internalCalledCmdlets -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $MyInvocation.MyCommand.Name
+ } else {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets += ',' + $MyInvocation.MyCommand.Name
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = 'internal'
+ }
+
+ $mapping = @{
+ Get = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentScan_Get';
+ GetViaIdentity = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentScan_GetViaIdentity';
+ List = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentScan_List';
+ }
+ $cmdInfo = Get-Command -Name $mapping[$parameterSet]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.MessageAttributeHelper]::ProcessCustomAttributesAtRuntime($cmdInfo, $MyInvocation, $parameterSet, $PSCmdlet)
+ $wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
+ $scriptCmd = {& $wrappedCmd @PSBoundParameters}
+ $steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
+ $steppablePipeline.Begin($PSCmdlet)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+
+process {
+ try {
+ $steppablePipeline.Process($_)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+
+ finally {
+ $backupTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ $backupInternalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+
+}
+end {
+ try {
+ $steppablePipeline.End()
+
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $backupTelemetryId
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $backupInternalCalledCmdlets
+ if ($preTelemetryId -eq '') {
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Send', $MyInvocation, $parameterSet, $PSCmdlet)
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $preTelemetryId
+
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+}
diff --git a/swaggerci/security/exports/Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult.ps1 b/swaggerci/security/exports/Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult.ps1
new file mode 100644
index 000000000000..850958be91fe
--- /dev/null
+++ b/swaggerci/security/exports/Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult.ps1
@@ -0,0 +1,197 @@
+
+# ----------------------------------------------------------------------------------
+# Copyright (c) Microsoft Corporation. All rights reserved.
+# Licensed under the MIT License. See License.txt in the project root for license information.
+# Code generated by Microsoft (R) AutoRest Code Generator.
+# Changes may cause incorrect behavior and will be lost if the code is regenerated.
+# ----------------------------------------------------------------------------------
+
+<#
+.Synopsis
+Gets the scan results of a single rule in a scan record.
+.Description
+Gets the scan results of a single rule in a scan record.
+.Example
+{{ Add code here }}
+.Example
+{{ Add code here }}
+
+.Inputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+.Outputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IScanResult
+.Notes
+COMPLEX PARAMETER PROPERTIES
+
+To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
+
+INPUTOBJECT : Identity Parameter
+ [Id ]: Resource identity path
+ [ResourceId ]: The identifier of the resource.
+ [RuleId ]: The rule Id.
+ [ScanId ]: The scan Id. Type 'latest' to get the scan record for the latest scan.
+ [ScanResultId ]: The rule Id of the results.
+.Link
+https://learn.microsoft.com/powershell/module/az.securitycenter/get-azsecuritycentersqlvulnerabilityassessmentscanresult
+#>
+function Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult {
+[OutputType([Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IScanResult])]
+[CmdletBinding(DefaultParameterSetName='List', PositionalBinding=$false)]
+param(
+ [Parameter(ParameterSetName='Get', Mandatory)]
+ [Parameter(ParameterSetName='List', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The identifier of the resource.
+ ${ResourceId},
+
+ [Parameter(ParameterSetName='Get', Mandatory)]
+ [Parameter(ParameterSetName='List', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The scan Id.
+ # Type 'latest' to get the scan results for the latest scan.
+ ${ScanId},
+
+ [Parameter(ParameterSetName='Get', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The rule Id of the results.
+ ${ScanResultId},
+
+ [Parameter(ParameterSetName='GetViaIdentity', Mandatory, ValueFromPipeline)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity]
+ # Identity Parameter
+ # To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
+ ${InputObject},
+
+ [Parameter(Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Query')]
+ [System.String]
+ # The workspace Id.
+ ${WorkspaceId},
+
+ [Parameter()]
+ [Alias('AzureRMContext', 'AzureCredential')]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Azure')]
+ [System.Management.Automation.PSObject]
+ # The credentials, account, tenant, and subscription used for communication with Azure.
+ ${DefaultProfile},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Wait for .NET debugger to attach
+ ${Break},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be appended to the front of the pipeline
+ ${HttpPipelineAppend},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be prepended to the front of the pipeline
+ ${HttpPipelinePrepend},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Uri]
+ # The URI for the proxy server to use
+ ${Proxy},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.PSCredential]
+ # Credentials for a proxy server to use for the remote call
+ ${ProxyCredential},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Use the default credentials for the proxy
+ ${ProxyUseDefaultCredentials}
+)
+
+begin {
+ try {
+ $outBuffer = $null
+ if ($PSBoundParameters.TryGetValue('OutBuffer', [ref]$outBuffer)) {
+ $PSBoundParameters['OutBuffer'] = 1
+ }
+ $parameterSet = $PSCmdlet.ParameterSetName
+
+ if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
+ [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $Host.Version.ToString()
+ }
+ $preTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ if ($preTelemetryId -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId =(New-Guid).ToString()
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Create', $MyInvocation, $parameterSet, $PSCmdlet)
+ } else {
+ $internalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ if ($internalCalledCmdlets -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $MyInvocation.MyCommand.Name
+ } else {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets += ',' + $MyInvocation.MyCommand.Name
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = 'internal'
+ }
+
+ $mapping = @{
+ Get = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult_Get';
+ GetViaIdentity = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult_GetViaIdentity';
+ List = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult_List';
+ }
+ $cmdInfo = Get-Command -Name $mapping[$parameterSet]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.MessageAttributeHelper]::ProcessCustomAttributesAtRuntime($cmdInfo, $MyInvocation, $parameterSet, $PSCmdlet)
+ $wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
+ $scriptCmd = {& $wrappedCmd @PSBoundParameters}
+ $steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
+ $steppablePipeline.Begin($PSCmdlet)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+
+process {
+ try {
+ $steppablePipeline.Process($_)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+
+ finally {
+ $backupTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ $backupInternalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+
+}
+end {
+ try {
+ $steppablePipeline.End()
+
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $backupTelemetryId
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $backupInternalCalledCmdlets
+ if ($preTelemetryId -eq '') {
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Send', $MyInvocation, $parameterSet, $PSCmdlet)
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $preTelemetryId
+
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+}
diff --git a/swaggerci/security/exports/New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.ps1 b/swaggerci/security/exports/New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.ps1
new file mode 100644
index 000000000000..0e7c749f0334
--- /dev/null
+++ b/swaggerci/security/exports/New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.ps1
@@ -0,0 +1,181 @@
+
+# ----------------------------------------------------------------------------------
+# Copyright (c) Microsoft Corporation. All rights reserved.
+# Licensed under the MIT License. See License.txt in the project root for license information.
+# Code generated by Microsoft (R) AutoRest Code Generator.
+# Changes may cause incorrect behavior and will be lost if the code is regenerated.
+# ----------------------------------------------------------------------------------
+
+<#
+.Synopsis
+Creates a Baseline for a rule in a database.
+Will overwrite any previously existing results.
+.Description
+Creates a Baseline for a rule in a database.
+Will overwrite any previously existing results.
+.Example
+{{ Add code here }}
+.Example
+{{ Add code here }}
+
+.Outputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRuleResults
+.Link
+https://learn.microsoft.com/powershell/module/az.securitycenter/new-azsecuritycentersqlvulnerabilityassessmentbaselinerule
+#>
+function New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule {
+[OutputType([Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRuleResults])]
+[CmdletBinding(DefaultParameterSetName='CreateExpanded', PositionalBinding=$false, SupportsShouldProcess, ConfirmImpact='Medium')]
+param(
+ [Parameter(Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The identifier of the resource.
+ ${ResourceId},
+
+ [Parameter(Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The rule Id.
+ ${RuleId},
+
+ [Parameter(Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Query')]
+ [System.String]
+ # The workspace Id.
+ ${WorkspaceId},
+
+ [Parameter()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Body')]
+ [System.Management.Automation.SwitchParameter]
+ # Take results from latest scan.
+ ${LatestScan},
+
+ [Parameter()]
+ [AllowEmptyCollection()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Body')]
+ [System.String[][]]
+ # Expected results to be inserted into the baseline.Leave this field empty it LatestScan == true.
+ ${Result},
+
+ [Parameter()]
+ [Alias('AzureRMContext', 'AzureCredential')]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Azure')]
+ [System.Management.Automation.PSObject]
+ # The credentials, account, tenant, and subscription used for communication with Azure.
+ ${DefaultProfile},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Wait for .NET debugger to attach
+ ${Break},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be appended to the front of the pipeline
+ ${HttpPipelineAppend},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be prepended to the front of the pipeline
+ ${HttpPipelinePrepend},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Uri]
+ # The URI for the proxy server to use
+ ${Proxy},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.PSCredential]
+ # Credentials for a proxy server to use for the remote call
+ ${ProxyCredential},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Use the default credentials for the proxy
+ ${ProxyUseDefaultCredentials}
+)
+
+begin {
+ try {
+ $outBuffer = $null
+ if ($PSBoundParameters.TryGetValue('OutBuffer', [ref]$outBuffer)) {
+ $PSBoundParameters['OutBuffer'] = 1
+ }
+ $parameterSet = $PSCmdlet.ParameterSetName
+
+ if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
+ [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $Host.Version.ToString()
+ }
+ $preTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ if ($preTelemetryId -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId =(New-Guid).ToString()
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Create', $MyInvocation, $parameterSet, $PSCmdlet)
+ } else {
+ $internalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ if ($internalCalledCmdlets -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $MyInvocation.MyCommand.Name
+ } else {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets += ',' + $MyInvocation.MyCommand.Name
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = 'internal'
+ }
+
+ $mapping = @{
+ CreateExpanded = 'Az.SecurityCenter.private\New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_CreateExpanded';
+ }
+ $cmdInfo = Get-Command -Name $mapping[$parameterSet]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.MessageAttributeHelper]::ProcessCustomAttributesAtRuntime($cmdInfo, $MyInvocation, $parameterSet, $PSCmdlet)
+ $wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
+ $scriptCmd = {& $wrappedCmd @PSBoundParameters}
+ $steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
+ $steppablePipeline.Begin($PSCmdlet)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+
+process {
+ try {
+ $steppablePipeline.Process($_)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+
+ finally {
+ $backupTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ $backupInternalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+
+}
+end {
+ try {
+ $steppablePipeline.End()
+
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $backupTelemetryId
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $backupInternalCalledCmdlets
+ if ($preTelemetryId -eq '') {
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Send', $MyInvocation, $parameterSet, $PSCmdlet)
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $preTelemetryId
+
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+}
diff --git a/swaggerci/security/exports/ProxyCmdletDefinitions.ps1 b/swaggerci/security/exports/ProxyCmdletDefinitions.ps1
new file mode 100644
index 000000000000..7a18b0c58aaf
--- /dev/null
+++ b/swaggerci/security/exports/ProxyCmdletDefinitions.ps1
@@ -0,0 +1,1132 @@
+
+# ----------------------------------------------------------------------------------
+# Copyright (c) Microsoft Corporation. All rights reserved.
+# Licensed under the MIT License. See License.txt in the project root for license information.
+# Code generated by Microsoft (R) AutoRest Code Generator.
+# Changes may cause incorrect behavior and will be lost if the code is regenerated.
+# ----------------------------------------------------------------------------------
+
+<#
+.Synopsis
+Add a list of baseline rules.
+Will overwrite any previously existing results (for all rules).
+.Description
+Add a list of baseline rules.
+Will overwrite any previously existing results (for all rules).
+.Example
+{{ Add code here }}
+.Example
+{{ Add code here }}
+
+.Inputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRulesResultsInput
+.Inputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+.Outputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRuleResults
+.Notes
+COMPLEX PARAMETER PROPERTIES
+
+To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
+
+BODY : Rules results input.
+ [LatestScan ]: Take results from latest scan.
+ [Result ]: Expected results to be inserted into the baseline. Leave this field empty it LatestScan == true.
+ [(Any) ]: This indicates any property can be added to this object.
+
+INPUTOBJECT : Identity Parameter
+ [Id ]: Resource identity path
+ [ResourceId ]: The identifier of the resource.
+ [RuleId ]: The rule Id.
+ [ScanId ]: The scan Id. Type 'latest' to get the scan record for the latest scan.
+ [ScanResultId ]: The rule Id of the results.
+.Link
+https://learn.microsoft.com/powershell/module/az.securitycenter/add-azsecuritycentersqlvulnerabilityassessmentbaselinerule
+#>
+function Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule {
+[OutputType([Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRuleResults])]
+[CmdletBinding(DefaultParameterSetName='AddExpanded', PositionalBinding=$false, SupportsShouldProcess, ConfirmImpact='Medium')]
+param(
+ [Parameter(ParameterSetName='Add', Mandatory)]
+ [Parameter(ParameterSetName='AddExpanded', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The identifier of the resource.
+ ${ResourceId},
+
+ [Parameter(ParameterSetName='AddViaIdentity', Mandatory, ValueFromPipeline)]
+ [Parameter(ParameterSetName='AddViaIdentityExpanded', Mandatory, ValueFromPipeline)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity]
+ # Identity Parameter
+ # To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
+ ${InputObject},
+
+ [Parameter(Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Query')]
+ [System.String]
+ # The workspace Id.
+ ${WorkspaceId},
+
+ [Parameter(ParameterSetName='Add', Mandatory, ValueFromPipeline)]
+ [Parameter(ParameterSetName='AddViaIdentity', Mandatory, ValueFromPipeline)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Body')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRulesResultsInput]
+ # Rules results input.
+ # To construct, see NOTES section for BODY properties and create a hash table.
+ ${Body},
+
+ [Parameter(ParameterSetName='AddExpanded')]
+ [Parameter(ParameterSetName='AddViaIdentityExpanded')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Body')]
+ [System.Management.Automation.SwitchParameter]
+ # Take results from latest scan.
+ ${LatestScan},
+
+ [Parameter(ParameterSetName='AddExpanded')]
+ [Parameter(ParameterSetName='AddViaIdentityExpanded')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Body')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(PossibleTypes=([Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRulesResultsInputResults]))]
+ [System.Collections.Hashtable]
+ # Expected results to be inserted into the baseline.Leave this field empty it LatestScan == true.
+ ${Result},
+
+ [Parameter()]
+ [Alias('AzureRMContext', 'AzureCredential')]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Azure')]
+ [System.Management.Automation.PSObject]
+ # The credentials, account, tenant, and subscription used for communication with Azure.
+ ${DefaultProfile},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Wait for .NET debugger to attach
+ ${Break},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be appended to the front of the pipeline
+ ${HttpPipelineAppend},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be prepended to the front of the pipeline
+ ${HttpPipelinePrepend},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Uri]
+ # The URI for the proxy server to use
+ ${Proxy},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.PSCredential]
+ # Credentials for a proxy server to use for the remote call
+ ${ProxyCredential},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Use the default credentials for the proxy
+ ${ProxyUseDefaultCredentials}
+)
+
+begin {
+ try {
+ $outBuffer = $null
+ if ($PSBoundParameters.TryGetValue('OutBuffer', [ref]$outBuffer)) {
+ $PSBoundParameters['OutBuffer'] = 1
+ }
+ $parameterSet = $PSCmdlet.ParameterSetName
+
+ if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
+ [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $Host.Version.ToString()
+ }
+ $preTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ if ($preTelemetryId -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId =(New-Guid).ToString()
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Create', $MyInvocation, $parameterSet, $PSCmdlet)
+ } else {
+ $internalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ if ($internalCalledCmdlets -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $MyInvocation.MyCommand.Name
+ } else {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets += ',' + $MyInvocation.MyCommand.Name
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = 'internal'
+ }
+
+ $mapping = @{
+ Add = 'Az.SecurityCenter.private\Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_Add';
+ AddExpanded = 'Az.SecurityCenter.private\Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_AddExpanded';
+ AddViaIdentity = 'Az.SecurityCenter.private\Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_AddViaIdentity';
+ AddViaIdentityExpanded = 'Az.SecurityCenter.private\Add-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_AddViaIdentityExpanded';
+ }
+ $cmdInfo = Get-Command -Name $mapping[$parameterSet]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.MessageAttributeHelper]::ProcessCustomAttributesAtRuntime($cmdInfo, $MyInvocation, $parameterSet, $PSCmdlet)
+ $wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
+ $scriptCmd = {& $wrappedCmd @PSBoundParameters}
+ $steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
+ $steppablePipeline.Begin($PSCmdlet)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+
+process {
+ try {
+ $steppablePipeline.Process($_)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+
+ finally {
+ $backupTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ $backupInternalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+
+}
+end {
+ try {
+ $steppablePipeline.End()
+
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $backupTelemetryId
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $backupInternalCalledCmdlets
+ if ($preTelemetryId -eq '') {
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Send', $MyInvocation, $parameterSet, $PSCmdlet)
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $preTelemetryId
+
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+}
+
+<#
+.Synopsis
+Gets the results for a given rule in the Baseline.
+.Description
+Gets the results for a given rule in the Baseline.
+.Example
+{{ Add code here }}
+.Example
+{{ Add code here }}
+
+.Inputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+.Outputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRuleResults
+.Notes
+COMPLEX PARAMETER PROPERTIES
+
+To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
+
+INPUTOBJECT : Identity Parameter
+ [Id ]: Resource identity path
+ [ResourceId ]: The identifier of the resource.
+ [RuleId ]: The rule Id.
+ [ScanId ]: The scan Id. Type 'latest' to get the scan record for the latest scan.
+ [ScanResultId ]: The rule Id of the results.
+.Link
+https://learn.microsoft.com/powershell/module/az.securitycenter/get-azsecuritycentersqlvulnerabilityassessmentbaselinerule
+#>
+function Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule {
+[OutputType([Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRuleResults])]
+[CmdletBinding(DefaultParameterSetName='List', PositionalBinding=$false)]
+param(
+ [Parameter(ParameterSetName='Get', Mandatory)]
+ [Parameter(ParameterSetName='List', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The identifier of the resource.
+ ${ResourceId},
+
+ [Parameter(ParameterSetName='Get', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The rule Id.
+ ${RuleId},
+
+ [Parameter(ParameterSetName='GetViaIdentity', Mandatory, ValueFromPipeline)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity]
+ # Identity Parameter
+ # To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
+ ${InputObject},
+
+ [Parameter(Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Query')]
+ [System.String]
+ # The workspace Id.
+ ${WorkspaceId},
+
+ [Parameter()]
+ [Alias('AzureRMContext', 'AzureCredential')]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Azure')]
+ [System.Management.Automation.PSObject]
+ # The credentials, account, tenant, and subscription used for communication with Azure.
+ ${DefaultProfile},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Wait for .NET debugger to attach
+ ${Break},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be appended to the front of the pipeline
+ ${HttpPipelineAppend},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be prepended to the front of the pipeline
+ ${HttpPipelinePrepend},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Uri]
+ # The URI for the proxy server to use
+ ${Proxy},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.PSCredential]
+ # Credentials for a proxy server to use for the remote call
+ ${ProxyCredential},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Use the default credentials for the proxy
+ ${ProxyUseDefaultCredentials}
+)
+
+begin {
+ try {
+ $outBuffer = $null
+ if ($PSBoundParameters.TryGetValue('OutBuffer', [ref]$outBuffer)) {
+ $PSBoundParameters['OutBuffer'] = 1
+ }
+ $parameterSet = $PSCmdlet.ParameterSetName
+
+ if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
+ [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $Host.Version.ToString()
+ }
+ $preTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ if ($preTelemetryId -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId =(New-Guid).ToString()
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Create', $MyInvocation, $parameterSet, $PSCmdlet)
+ } else {
+ $internalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ if ($internalCalledCmdlets -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $MyInvocation.MyCommand.Name
+ } else {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets += ',' + $MyInvocation.MyCommand.Name
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = 'internal'
+ }
+
+ $mapping = @{
+ Get = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_Get';
+ GetViaIdentity = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_GetViaIdentity';
+ List = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_List';
+ }
+ $cmdInfo = Get-Command -Name $mapping[$parameterSet]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.MessageAttributeHelper]::ProcessCustomAttributesAtRuntime($cmdInfo, $MyInvocation, $parameterSet, $PSCmdlet)
+ $wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
+ $scriptCmd = {& $wrappedCmd @PSBoundParameters}
+ $steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
+ $steppablePipeline.Begin($PSCmdlet)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+
+process {
+ try {
+ $steppablePipeline.Process($_)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+
+ finally {
+ $backupTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ $backupInternalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+
+}
+end {
+ try {
+ $steppablePipeline.End()
+
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $backupTelemetryId
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $backupInternalCalledCmdlets
+ if ($preTelemetryId -eq '') {
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Send', $MyInvocation, $parameterSet, $PSCmdlet)
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $preTelemetryId
+
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+}
+
+<#
+.Synopsis
+Gets the scan results of a single rule in a scan record.
+.Description
+Gets the scan results of a single rule in a scan record.
+.Example
+{{ Add code here }}
+.Example
+{{ Add code here }}
+
+.Inputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+.Outputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IScanResult
+.Notes
+COMPLEX PARAMETER PROPERTIES
+
+To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
+
+INPUTOBJECT : Identity Parameter
+ [Id ]: Resource identity path
+ [ResourceId ]: The identifier of the resource.
+ [RuleId ]: The rule Id.
+ [ScanId ]: The scan Id. Type 'latest' to get the scan record for the latest scan.
+ [ScanResultId ]: The rule Id of the results.
+.Link
+https://learn.microsoft.com/powershell/module/az.securitycenter/get-azsecuritycentersqlvulnerabilityassessmentscanresult
+#>
+function Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult {
+[OutputType([Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IScanResult])]
+[CmdletBinding(DefaultParameterSetName='List', PositionalBinding=$false)]
+param(
+ [Parameter(ParameterSetName='Get', Mandatory)]
+ [Parameter(ParameterSetName='List', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The identifier of the resource.
+ ${ResourceId},
+
+ [Parameter(ParameterSetName='Get', Mandatory)]
+ [Parameter(ParameterSetName='List', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The scan Id.
+ # Type 'latest' to get the scan results for the latest scan.
+ ${ScanId},
+
+ [Parameter(ParameterSetName='Get', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The rule Id of the results.
+ ${ScanResultId},
+
+ [Parameter(ParameterSetName='GetViaIdentity', Mandatory, ValueFromPipeline)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity]
+ # Identity Parameter
+ # To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
+ ${InputObject},
+
+ [Parameter(Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Query')]
+ [System.String]
+ # The workspace Id.
+ ${WorkspaceId},
+
+ [Parameter()]
+ [Alias('AzureRMContext', 'AzureCredential')]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Azure')]
+ [System.Management.Automation.PSObject]
+ # The credentials, account, tenant, and subscription used for communication with Azure.
+ ${DefaultProfile},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Wait for .NET debugger to attach
+ ${Break},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be appended to the front of the pipeline
+ ${HttpPipelineAppend},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be prepended to the front of the pipeline
+ ${HttpPipelinePrepend},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Uri]
+ # The URI for the proxy server to use
+ ${Proxy},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.PSCredential]
+ # Credentials for a proxy server to use for the remote call
+ ${ProxyCredential},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Use the default credentials for the proxy
+ ${ProxyUseDefaultCredentials}
+)
+
+begin {
+ try {
+ $outBuffer = $null
+ if ($PSBoundParameters.TryGetValue('OutBuffer', [ref]$outBuffer)) {
+ $PSBoundParameters['OutBuffer'] = 1
+ }
+ $parameterSet = $PSCmdlet.ParameterSetName
+
+ if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
+ [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $Host.Version.ToString()
+ }
+ $preTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ if ($preTelemetryId -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId =(New-Guid).ToString()
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Create', $MyInvocation, $parameterSet, $PSCmdlet)
+ } else {
+ $internalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ if ($internalCalledCmdlets -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $MyInvocation.MyCommand.Name
+ } else {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets += ',' + $MyInvocation.MyCommand.Name
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = 'internal'
+ }
+
+ $mapping = @{
+ Get = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult_Get';
+ GetViaIdentity = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult_GetViaIdentity';
+ List = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentScanResult_List';
+ }
+ $cmdInfo = Get-Command -Name $mapping[$parameterSet]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.MessageAttributeHelper]::ProcessCustomAttributesAtRuntime($cmdInfo, $MyInvocation, $parameterSet, $PSCmdlet)
+ $wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
+ $scriptCmd = {& $wrappedCmd @PSBoundParameters}
+ $steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
+ $steppablePipeline.Begin($PSCmdlet)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+
+process {
+ try {
+ $steppablePipeline.Process($_)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+
+ finally {
+ $backupTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ $backupInternalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+
+}
+end {
+ try {
+ $steppablePipeline.End()
+
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $backupTelemetryId
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $backupInternalCalledCmdlets
+ if ($preTelemetryId -eq '') {
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Send', $MyInvocation, $parameterSet, $PSCmdlet)
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $preTelemetryId
+
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+}
+
+<#
+.Synopsis
+Gets the scan details of a single scan record.
+.Description
+Gets the scan details of a single scan record.
+.Example
+{{ Add code here }}
+.Example
+{{ Add code here }}
+
+.Inputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+.Outputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IScan
+.Notes
+COMPLEX PARAMETER PROPERTIES
+
+To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
+
+INPUTOBJECT : Identity Parameter
+ [Id ]: Resource identity path
+ [ResourceId ]: The identifier of the resource.
+ [RuleId ]: The rule Id.
+ [ScanId ]: The scan Id. Type 'latest' to get the scan record for the latest scan.
+ [ScanResultId ]: The rule Id of the results.
+.Link
+https://learn.microsoft.com/powershell/module/az.securitycenter/get-azsecuritycentersqlvulnerabilityassessmentscan
+#>
+function Get-AzSecurityCenterSqlVulnerabilityAssessmentScan {
+[OutputType([Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IScan])]
+[CmdletBinding(DefaultParameterSetName='List', PositionalBinding=$false)]
+param(
+ [Parameter(ParameterSetName='Get', Mandatory)]
+ [Parameter(ParameterSetName='List', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The identifier of the resource.
+ ${ResourceId},
+
+ [Parameter(ParameterSetName='Get', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The scan Id.
+ # Type 'latest' to get the scan record for the latest scan.
+ ${ScanId},
+
+ [Parameter(ParameterSetName='GetViaIdentity', Mandatory, ValueFromPipeline)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity]
+ # Identity Parameter
+ # To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
+ ${InputObject},
+
+ [Parameter(Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Query')]
+ [System.String]
+ # The workspace Id.
+ ${WorkspaceId},
+
+ [Parameter()]
+ [Alias('AzureRMContext', 'AzureCredential')]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Azure')]
+ [System.Management.Automation.PSObject]
+ # The credentials, account, tenant, and subscription used for communication with Azure.
+ ${DefaultProfile},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Wait for .NET debugger to attach
+ ${Break},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be appended to the front of the pipeline
+ ${HttpPipelineAppend},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be prepended to the front of the pipeline
+ ${HttpPipelinePrepend},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Uri]
+ # The URI for the proxy server to use
+ ${Proxy},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.PSCredential]
+ # Credentials for a proxy server to use for the remote call
+ ${ProxyCredential},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Use the default credentials for the proxy
+ ${ProxyUseDefaultCredentials}
+)
+
+begin {
+ try {
+ $outBuffer = $null
+ if ($PSBoundParameters.TryGetValue('OutBuffer', [ref]$outBuffer)) {
+ $PSBoundParameters['OutBuffer'] = 1
+ }
+ $parameterSet = $PSCmdlet.ParameterSetName
+
+ if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
+ [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $Host.Version.ToString()
+ }
+ $preTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ if ($preTelemetryId -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId =(New-Guid).ToString()
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Create', $MyInvocation, $parameterSet, $PSCmdlet)
+ } else {
+ $internalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ if ($internalCalledCmdlets -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $MyInvocation.MyCommand.Name
+ } else {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets += ',' + $MyInvocation.MyCommand.Name
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = 'internal'
+ }
+
+ $mapping = @{
+ Get = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentScan_Get';
+ GetViaIdentity = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentScan_GetViaIdentity';
+ List = 'Az.SecurityCenter.private\Get-AzSecurityCenterSqlVulnerabilityAssessmentScan_List';
+ }
+ $cmdInfo = Get-Command -Name $mapping[$parameterSet]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.MessageAttributeHelper]::ProcessCustomAttributesAtRuntime($cmdInfo, $MyInvocation, $parameterSet, $PSCmdlet)
+ $wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
+ $scriptCmd = {& $wrappedCmd @PSBoundParameters}
+ $steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
+ $steppablePipeline.Begin($PSCmdlet)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+
+process {
+ try {
+ $steppablePipeline.Process($_)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+
+ finally {
+ $backupTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ $backupInternalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+
+}
+end {
+ try {
+ $steppablePipeline.End()
+
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $backupTelemetryId
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $backupInternalCalledCmdlets
+ if ($preTelemetryId -eq '') {
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Send', $MyInvocation, $parameterSet, $PSCmdlet)
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $preTelemetryId
+
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+}
+
+<#
+.Synopsis
+Creates a Baseline for a rule in a database.
+Will overwrite any previously existing results.
+.Description
+Creates a Baseline for a rule in a database.
+Will overwrite any previously existing results.
+.Example
+{{ Add code here }}
+.Example
+{{ Add code here }}
+
+.Outputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRuleResults
+.Link
+https://learn.microsoft.com/powershell/module/az.securitycenter/new-azsecuritycentersqlvulnerabilityassessmentbaselinerule
+#>
+function New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule {
+[OutputType([Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IRuleResults])]
+[CmdletBinding(DefaultParameterSetName='CreateExpanded', PositionalBinding=$false, SupportsShouldProcess, ConfirmImpact='Medium')]
+param(
+ [Parameter(Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The identifier of the resource.
+ ${ResourceId},
+
+ [Parameter(Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The rule Id.
+ ${RuleId},
+
+ [Parameter(Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Query')]
+ [System.String]
+ # The workspace Id.
+ ${WorkspaceId},
+
+ [Parameter()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Body')]
+ [System.Management.Automation.SwitchParameter]
+ # Take results from latest scan.
+ ${LatestScan},
+
+ [Parameter()]
+ [AllowEmptyCollection()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Body')]
+ [System.String[][]]
+ # Expected results to be inserted into the baseline.Leave this field empty it LatestScan == true.
+ ${Result},
+
+ [Parameter()]
+ [Alias('AzureRMContext', 'AzureCredential')]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Azure')]
+ [System.Management.Automation.PSObject]
+ # The credentials, account, tenant, and subscription used for communication with Azure.
+ ${DefaultProfile},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Wait for .NET debugger to attach
+ ${Break},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be appended to the front of the pipeline
+ ${HttpPipelineAppend},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be prepended to the front of the pipeline
+ ${HttpPipelinePrepend},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Uri]
+ # The URI for the proxy server to use
+ ${Proxy},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.PSCredential]
+ # Credentials for a proxy server to use for the remote call
+ ${ProxyCredential},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Use the default credentials for the proxy
+ ${ProxyUseDefaultCredentials}
+)
+
+begin {
+ try {
+ $outBuffer = $null
+ if ($PSBoundParameters.TryGetValue('OutBuffer', [ref]$outBuffer)) {
+ $PSBoundParameters['OutBuffer'] = 1
+ }
+ $parameterSet = $PSCmdlet.ParameterSetName
+
+ if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
+ [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $Host.Version.ToString()
+ }
+ $preTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ if ($preTelemetryId -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId =(New-Guid).ToString()
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Create', $MyInvocation, $parameterSet, $PSCmdlet)
+ } else {
+ $internalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ if ($internalCalledCmdlets -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $MyInvocation.MyCommand.Name
+ } else {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets += ',' + $MyInvocation.MyCommand.Name
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = 'internal'
+ }
+
+ $mapping = @{
+ CreateExpanded = 'Az.SecurityCenter.private\New-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_CreateExpanded';
+ }
+ $cmdInfo = Get-Command -Name $mapping[$parameterSet]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.MessageAttributeHelper]::ProcessCustomAttributesAtRuntime($cmdInfo, $MyInvocation, $parameterSet, $PSCmdlet)
+ $wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
+ $scriptCmd = {& $wrappedCmd @PSBoundParameters}
+ $steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
+ $steppablePipeline.Begin($PSCmdlet)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+
+process {
+ try {
+ $steppablePipeline.Process($_)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+
+ finally {
+ $backupTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ $backupInternalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+
+}
+end {
+ try {
+ $steppablePipeline.End()
+
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $backupTelemetryId
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $backupInternalCalledCmdlets
+ if ($preTelemetryId -eq '') {
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Send', $MyInvocation, $parameterSet, $PSCmdlet)
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $preTelemetryId
+
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+}
+
+<#
+.Synopsis
+Deletes a rule from the Baseline of a given database.
+.Description
+Deletes a rule from the Baseline of a given database.
+.Example
+{{ Add code here }}
+.Example
+{{ Add code here }}
+
+.Inputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+.Outputs
+System.Boolean
+.Notes
+COMPLEX PARAMETER PROPERTIES
+
+To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
+
+INPUTOBJECT : Identity Parameter
+ [Id ]: Resource identity path
+ [ResourceId ]: The identifier of the resource.
+ [RuleId ]: The rule Id.
+ [ScanId ]: The scan Id. Type 'latest' to get the scan record for the latest scan.
+ [ScanResultId ]: The rule Id of the results.
+.Link
+https://learn.microsoft.com/powershell/module/az.securitycenter/remove-azsecuritycentersqlvulnerabilityassessmentbaselinerule
+#>
+function Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule {
+[OutputType([System.Boolean])]
+[CmdletBinding(DefaultParameterSetName='Delete', PositionalBinding=$false, SupportsShouldProcess, ConfirmImpact='Medium')]
+param(
+ [Parameter(ParameterSetName='Delete', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The identifier of the resource.
+ ${ResourceId},
+
+ [Parameter(ParameterSetName='Delete', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The rule Id.
+ ${RuleId},
+
+ [Parameter(ParameterSetName='DeleteViaIdentity', Mandatory, ValueFromPipeline)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity]
+ # Identity Parameter
+ # To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
+ ${InputObject},
+
+ [Parameter(Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Query')]
+ [System.String]
+ # The workspace Id.
+ ${WorkspaceId},
+
+ [Parameter()]
+ [Alias('AzureRMContext', 'AzureCredential')]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Azure')]
+ [System.Management.Automation.PSObject]
+ # The credentials, account, tenant, and subscription used for communication with Azure.
+ ${DefaultProfile},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Wait for .NET debugger to attach
+ ${Break},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be appended to the front of the pipeline
+ ${HttpPipelineAppend},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be prepended to the front of the pipeline
+ ${HttpPipelinePrepend},
+
+ [Parameter()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Returns true when the command succeeds
+ ${PassThru},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Uri]
+ # The URI for the proxy server to use
+ ${Proxy},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.PSCredential]
+ # Credentials for a proxy server to use for the remote call
+ ${ProxyCredential},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Use the default credentials for the proxy
+ ${ProxyUseDefaultCredentials}
+)
+
+begin {
+ try {
+ $outBuffer = $null
+ if ($PSBoundParameters.TryGetValue('OutBuffer', [ref]$outBuffer)) {
+ $PSBoundParameters['OutBuffer'] = 1
+ }
+ $parameterSet = $PSCmdlet.ParameterSetName
+
+ if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
+ [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $Host.Version.ToString()
+ }
+ $preTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ if ($preTelemetryId -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId =(New-Guid).ToString()
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Create', $MyInvocation, $parameterSet, $PSCmdlet)
+ } else {
+ $internalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ if ($internalCalledCmdlets -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $MyInvocation.MyCommand.Name
+ } else {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets += ',' + $MyInvocation.MyCommand.Name
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = 'internal'
+ }
+
+ $mapping = @{
+ Delete = 'Az.SecurityCenter.private\Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_Delete';
+ DeleteViaIdentity = 'Az.SecurityCenter.private\Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_DeleteViaIdentity';
+ }
+ $cmdInfo = Get-Command -Name $mapping[$parameterSet]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.MessageAttributeHelper]::ProcessCustomAttributesAtRuntime($cmdInfo, $MyInvocation, $parameterSet, $PSCmdlet)
+ $wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
+ $scriptCmd = {& $wrappedCmd @PSBoundParameters}
+ $steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
+ $steppablePipeline.Begin($PSCmdlet)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+
+process {
+ try {
+ $steppablePipeline.Process($_)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+
+ finally {
+ $backupTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ $backupInternalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+
+}
+end {
+ try {
+ $steppablePipeline.End()
+
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $backupTelemetryId
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $backupInternalCalledCmdlets
+ if ($preTelemetryId -eq '') {
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Send', $MyInvocation, $parameterSet, $PSCmdlet)
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $preTelemetryId
+
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+}
diff --git a/swaggerci/security/exports/README.md b/swaggerci/security/exports/README.md
new file mode 100644
index 000000000000..037b71105e21
--- /dev/null
+++ b/swaggerci/security/exports/README.md
@@ -0,0 +1,20 @@
+# Exports
+This directory contains the cmdlets *exported by* `Az.SecurityCenter`. No other cmdlets in this repository are directly exported. What that means is the `Az.SecurityCenter` module will run [Export-ModuleMember](https://learn.microsoft.com/powershell/module/microsoft.powershell.core/export-modulemember) on the cmldets in this directory. The cmdlets in this directory are generated at **build-time**. Do not put any custom code, files, cmdlets, etc. into this directory. Please use `../custom` for all custom implementation.
+
+## Info
+- Modifiable: no
+- Generated: all
+- Committed: no
+- Packaged: yes
+
+## Details
+The cmdlets generated here are created every time you run `build-module.ps1`. These cmdlets are a merge of all (excluding `InternalExport`) cmdlets from the private binary (`../bin/Az.SecurityCenter.private.dll`) and from the `../custom/Az.SecurityCenter.custom.psm1` module. Cmdlets that are *not merged* from those directories are decorated with the `InternalExport` attribute. This happens when you set the cmdlet to **hide** from configuration. For more information on hiding, see [cmdlet hiding](https://github.com/Azure/autorest/blob/master/docs/powershell/options.md#cmdlet-hiding-exportation-suppression) or the [README.md](../internal/README.md) in the `../internal` folder.
+
+## Purpose
+We generate script cmdlets out of the binary cmdlets and custom cmdlets. The format of script cmdlets are simplistic; thus, easier to generate at build time. Generating the cmdlets is required as to allow merging of generated binary, hand-written binary, and hand-written custom cmdlets. For Azure cmdlets, having script cmdlets simplifies the mechanism for exporting Azure profiles.
+
+## Structure
+The cmdlets generated here will flat in the directory (no sub-folders) as long as there are no Azure profiles specified for any cmdlets. Azure profiles (the `Profiles` attribute) is only applied when generating with the `--azure` attribute (or `azure: true` in the configuration). When Azure profiles are applied, the folder structure has a folder per profile. Each profile folder has only those cmdlets that apply to that profile.
+
+## Usage
+When `./Az.SecurityCenter.psm1` is loaded, it dynamically exports cmdlets here based on the folder structure and on the selected profile. If there are no sub-folders, it exports all cmdlets at the root of this folder. If there are sub-folders, it checks to see the selected profile. If no profile is selected, it exports the cmdlets in the last sub-folder (alphabetically). If a profile is selected, it exports the cmdlets in the sub-folder that matches the profile name. If there is no sub-folder that matches the profile name, it exports no cmdlets and writes a warning message.
\ No newline at end of file
diff --git a/swaggerci/security/exports/Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.ps1 b/swaggerci/security/exports/Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.ps1
new file mode 100644
index 000000000000..8d1f737ec766
--- /dev/null
+++ b/swaggerci/security/exports/Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule.ps1
@@ -0,0 +1,193 @@
+
+# ----------------------------------------------------------------------------------
+# Copyright (c) Microsoft Corporation. All rights reserved.
+# Licensed under the MIT License. See License.txt in the project root for license information.
+# Code generated by Microsoft (R) AutoRest Code Generator.
+# Changes may cause incorrect behavior and will be lost if the code is regenerated.
+# ----------------------------------------------------------------------------------
+
+<#
+.Synopsis
+Deletes a rule from the Baseline of a given database.
+.Description
+Deletes a rule from the Baseline of a given database.
+.Example
+{{ Add code here }}
+.Example
+{{ Add code here }}
+
+.Inputs
+Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity
+.Outputs
+System.Boolean
+.Notes
+COMPLEX PARAMETER PROPERTIES
+
+To create the parameters described below, construct a hash table containing the appropriate properties. For information on hash tables, run Get-Help about_Hash_Tables.
+
+INPUTOBJECT : Identity Parameter
+ [Id ]: Resource identity path
+ [ResourceId ]: The identifier of the resource.
+ [RuleId ]: The rule Id.
+ [ScanId ]: The scan Id. Type 'latest' to get the scan record for the latest scan.
+ [ScanResultId ]: The rule Id of the results.
+.Link
+https://learn.microsoft.com/powershell/module/az.securitycenter/remove-azsecuritycentersqlvulnerabilityassessmentbaselinerule
+#>
+function Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule {
+[OutputType([System.Boolean])]
+[CmdletBinding(DefaultParameterSetName='Delete', PositionalBinding=$false, SupportsShouldProcess, ConfirmImpact='Medium')]
+param(
+ [Parameter(ParameterSetName='Delete', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The identifier of the resource.
+ ${ResourceId},
+
+ [Parameter(ParameterSetName='Delete', Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [System.String]
+ # The rule Id.
+ ${RuleId},
+
+ [Parameter(ParameterSetName='DeleteViaIdentity', Mandatory, ValueFromPipeline)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Path')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.ISecurityCenterIdentity]
+ # Identity Parameter
+ # To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
+ ${InputObject},
+
+ [Parameter(Mandatory)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Query')]
+ [System.String]
+ # The workspace Id.
+ ${WorkspaceId},
+
+ [Parameter()]
+ [Alias('AzureRMContext', 'AzureCredential')]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Azure')]
+ [System.Management.Automation.PSObject]
+ # The credentials, account, tenant, and subscription used for communication with Azure.
+ ${DefaultProfile},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Wait for .NET debugger to attach
+ ${Break},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be appended to the front of the pipeline
+ ${HttpPipelineAppend},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SendAsyncStep[]]
+ # SendAsync Pipeline Steps to be prepended to the front of the pipeline
+ ${HttpPipelinePrepend},
+
+ [Parameter()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Returns true when the command succeeds
+ ${PassThru},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Uri]
+ # The URI for the proxy server to use
+ ${Proxy},
+
+ [Parameter(DontShow)]
+ [ValidateNotNull()]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.PSCredential]
+ # Credentials for a proxy server to use for the remote call
+ ${ProxyCredential},
+
+ [Parameter(DontShow)]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Category('Runtime')]
+ [System.Management.Automation.SwitchParameter]
+ # Use the default credentials for the proxy
+ ${ProxyUseDefaultCredentials}
+)
+
+begin {
+ try {
+ $outBuffer = $null
+ if ($PSBoundParameters.TryGetValue('OutBuffer', [ref]$outBuffer)) {
+ $PSBoundParameters['OutBuffer'] = 1
+ }
+ $parameterSet = $PSCmdlet.ParameterSetName
+
+ if ($null -eq [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion) {
+ [Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet]::PowerShellVersion = $Host.Version.ToString()
+ }
+ $preTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ if ($preTelemetryId -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId =(New-Guid).ToString()
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Create', $MyInvocation, $parameterSet, $PSCmdlet)
+ } else {
+ $internalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ if ($internalCalledCmdlets -eq '') {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $MyInvocation.MyCommand.Name
+ } else {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets += ',' + $MyInvocation.MyCommand.Name
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = 'internal'
+ }
+
+ $mapping = @{
+ Delete = 'Az.SecurityCenter.private\Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_Delete';
+ DeleteViaIdentity = 'Az.SecurityCenter.private\Remove-AzSecurityCenterSqlVulnerabilityAssessmentBaselineRule_DeleteViaIdentity';
+ }
+ $cmdInfo = Get-Command -Name $mapping[$parameterSet]
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.MessageAttributeHelper]::ProcessCustomAttributesAtRuntime($cmdInfo, $MyInvocation, $parameterSet, $PSCmdlet)
+ $wrappedCmd = $ExecutionContext.InvokeCommand.GetCommand(($mapping[$parameterSet]), [System.Management.Automation.CommandTypes]::Cmdlet)
+ $scriptCmd = {& $wrappedCmd @PSBoundParameters}
+ $steppablePipeline = $scriptCmd.GetSteppablePipeline($MyInvocation.CommandOrigin)
+ $steppablePipeline.Begin($PSCmdlet)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+
+process {
+ try {
+ $steppablePipeline.Process($_)
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+
+ finally {
+ $backupTelemetryId = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId
+ $backupInternalCalledCmdlets = [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+
+}
+end {
+ try {
+ $steppablePipeline.End()
+
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $backupTelemetryId
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::InternalCalledCmdlets = $backupInternalCalledCmdlets
+ if ($preTelemetryId -eq '') {
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.module]::Instance.Telemetry.Invoke('Send', $MyInvocation, $parameterSet, $PSCmdlet)
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ }
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::TelemetryId = $preTelemetryId
+
+ } catch {
+ [Microsoft.WindowsAzure.Commands.Common.MetricHelper]::ClearTelemetryContext()
+ throw
+ }
+}
+}
diff --git a/swaggerci/security/generate-help.ps1 b/swaggerci/security/generate-help.ps1
new file mode 100644
index 000000000000..6b40cd213d69
--- /dev/null
+++ b/swaggerci/security/generate-help.ps1
@@ -0,0 +1,66 @@
+# ----------------------------------------------------------------------------------
+# Copyright (c) Microsoft Corporation. All rights reserved.
+# Licensed under the MIT License. See License.txt in the project root for license information.
+# Code generated by Microsoft (R) AutoRest Code Generator.
+# Changes may cause incorrect behavior and will be lost if the code is regenerated.
+# ----------------------------------------------------------------------------------
+param([switch]$Isolated)
+$ErrorActionPreference = 'Stop'
+
+$pwsh = [System.Diagnostics.Process]::GetCurrentProcess().Path
+if(-not $Isolated) {
+ Write-Host -ForegroundColor Green 'Creating isolated process...'
+ & "$pwsh" -NonInteractive -NoLogo -NoProfile -File $MyInvocation.MyCommand.Path @PSBoundParameters -Isolated
+ return
+}
+
+$exportsFolder = Join-Path $PSScriptRoot 'exports'
+if(-not (Test-Path $exportsFolder)) {
+ Write-Error "Exports folder '$exportsFolder' was not found."
+}
+
+$directories = Get-ChildItem -Directory -Path $exportsFolder
+$hasProfiles = ($directories | Measure-Object).Count -gt 0
+if(-not $hasProfiles) {
+ $directories = Get-Item -Path $exportsFolder
+}
+
+$docsFolder = Join-Path $PSScriptRoot 'docs'
+if(Test-Path $docsFolder) {
+ $null = Get-ChildItem -Path $docsFolder -Recurse -Exclude 'README.md' | Remove-Item -Recurse -ErrorAction SilentlyContinue
+}
+$null = New-Item -ItemType Directory -Force -Path $docsFolder -ErrorAction SilentlyContinue
+$examplesFolder = Join-Path $PSScriptRoot 'examples'
+
+$modulePsd1 = Get-Item -Path (Join-Path $PSScriptRoot './Az.SecurityCenter.psd1')
+$modulePath = $modulePsd1.FullName
+$moduleName = $modulePsd1.BaseName
+
+# Load DLL to use build-time cmdlets
+Import-Module -Name $modulePath
+Import-Module -Name (Join-Path $PSScriptRoot './bin/Az.SecurityCenter.private.dll')
+$instance = [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Module]::Instance
+# Module info is shared per profile
+$moduleInfo = Get-Module -Name $moduleName
+
+foreach($directory in $directories)
+{
+ if($hasProfiles) {
+ Select-AzProfile -Name $directory.Name
+ }
+ # Reload module per profile
+ Import-Module -Name $modulePath -Force
+
+ $cmdletNames = Get-ScriptCmdlet -ScriptFolder $directory.FullName
+ $cmdletHelpInfo = $cmdletNames | ForEach-Object { Get-Help -Name $_ -Full }
+ $cmdletFunctionInfo = Get-ScriptCmdlet -ScriptFolder $directory.FullName -AsFunctionInfo
+
+ $docsPath = Join-Path $docsFolder $directory.Name
+ $null = New-Item -ItemType Directory -Force -Path $docsPath -ErrorAction SilentlyContinue
+ $examplesPath = Join-Path $examplesFolder $directory.Name
+
+ Export-HelpMarkdown -ModuleInfo $moduleInfo -FunctionInfo $cmdletFunctionInfo -HelpInfo $cmdletHelpInfo -DocsFolder $docsPath -ExamplesFolder $examplesPath
+ Write-Host -ForegroundColor Green "Created documentation in '$docsPath'"
+}
+
+Write-Host -ForegroundColor Green '-------------Done-------------'
\ No newline at end of file
diff --git a/swaggerci/security/generated/Module.cs b/swaggerci/security/generated/Module.cs
new file mode 100644
index 000000000000..2d4c6091763f
--- /dev/null
+++ b/swaggerci/security/generated/Module.cs
@@ -0,0 +1,181 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter
+{
+ using static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Extensions;
+ using SendAsyncStepDelegate = global::System.Func, global::System.Threading.Tasks.Task>, global::System.Func, global::System.Threading.Tasks.Task>, global::System.Threading.Tasks.Task>, global::System.Threading.Tasks.Task>;
+ using PipelineChangeDelegate = global::System.Action, global::System.Threading.Tasks.Task>, global::System.Func, global::System.Threading.Tasks.Task>, global::System.Threading.Tasks.Task>, global::System.Threading.Tasks.Task>>;
+ using GetParameterDelegate = global::System.Func;
+ using ModuleLoadPipelineDelegate = global::System.Action, global::System.Threading.Tasks.Task>, global::System.Func, global::System.Threading.Tasks.Task>, global::System.Threading.Tasks.Task>, global::System.Threading.Tasks.Task>>, global::System.Action, global::System.Threading.Tasks.Task>, global::System.Func, global::System.Threading.Tasks.Task>, global::System.Threading.Tasks.Task>, global::System.Threading.Tasks.Task>>>;
+ using ArgumentCompleterDelegate = global::System.Func;
+ using GetTelemetryIdDelegate = global::System.Func;
+ using TelemetryDelegate = global::System.Action;
+ using NewRequestPipelineDelegate = global::System.Action, global::System.Threading.Tasks.Task>, global::System.Func, global::System.Threading.Tasks.Task>, global::System.Threading.Tasks.Task>, global::System.Threading.Tasks.Task>>, global::System.Action, global::System.Threading.Tasks.Task>, global::System.Func, global::System.Threading.Tasks.Task>, global::System.Threading.Tasks.Task>, global::System.Threading.Tasks.Task>>>;
+ using SignalDelegate = global::System.Func, global::System.Threading.Tasks.Task>;
+ using EventListenerDelegate = global::System.Func, global::System.Func, global::System.Threading.Tasks.Task>, global::System.Management.Automation.InvocationInfo, string, string, string, global::System.Exception, global::System.Threading.Tasks.Task>;
+ using NextDelegate = global::System.Func, global::System.Threading.Tasks.Task>, global::System.Threading.Tasks.Task>;
+
+ /// A class that contains the module-common code and data.
+ public partial class Module
+ {
+ /// The currently selected profile.
+ public string Profile = global::System.String.Empty;
+
+ public global::System.Net.Http.HttpClientHandler _handler = new global::System.Net.Http.HttpClientHandler();
+
+ /// the ISendAsync pipeline instance
+ private Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.HttpPipeline _pipeline;
+
+ /// the ISendAsync pipeline instance (when proxy is enabled)
+ private Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.HttpPipeline _pipelineWithProxy;
+
+ public bool _useProxy = false;
+
+ public global::System.Net.WebProxy _webProxy = new global::System.Net.WebProxy();
+
+ /// Gets completion data for azure specific fields
+ public ArgumentCompleterDelegate ArgumentCompleter { get; set; }
+
+ /// The instance of the Client API
+ public Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.SecurityCenter ClientAPI { get; set; }
+
+ /// A delegate that gets called for each signalled event
+ public EventListenerDelegate EventListener { get; set; }
+
+ /// The delegate to call to get parameter data from a common module.
+ public GetParameterDelegate GetParameterValue { get; set; }
+
+ /// The delegate to get the telemetry Id.
+ public GetTelemetryIdDelegate GetTelemetryId { get; set; }
+
+ /// Backing field for property.
+ private static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Module _instance;
+
+ /// the singleton of this module class
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Module Instance => Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Module._instance?? (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Module._instance = new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Module());
+
+ /// The Name of this module
+ public string Name => @"Az.SecurityCenter";
+
+ /// The delegate to call when this module is loaded (supporting a commmon module).
+ public ModuleLoadPipelineDelegate OnModuleLoad { get; set; }
+
+ /// The delegate to call before each new request (supporting a commmon module).
+ public NewRequestPipelineDelegate OnNewRequest { get; set; }
+
+ /// The name of the currently selected Azure profile
+ public global::System.String ProfileName { get; set; }
+
+ /// The ResourceID for this module (azure arm).
+ public string ResourceId => @"Az.SecurityCenter";
+
+ /// The delegate for creating a telemetry.
+ public TelemetryDelegate Telemetry { get; set; }
+
+ /// The from the cmdlet
+ /// The HttpPipeline for the request
+
+ partial void AfterCreatePipeline(global::System.Management.Automation.InvocationInfo invocationInfo, ref Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.HttpPipeline pipeline);
+
+ /// The from the cmdlet
+ /// The HttpPipeline for the request
+
+ partial void BeforeCreatePipeline(global::System.Management.Automation.InvocationInfo invocationInfo, ref Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.HttpPipeline pipeline);
+
+ partial void CustomInit();
+
+ /// Creates an instance of the HttpPipeline for each call.
+ /// The from the cmdlet
+ /// the cmdlet's correlation id.
+ /// the cmdlet's process record correlation id.
+ /// the cmdlet's parameterset name.
+ /// a dict for extensible parameters
+ /// An instance of Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.HttpPipeline for the remote call.
+ public Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.HttpPipeline CreatePipeline(global::System.Management.Automation.InvocationInfo invocationInfo, string correlationId, string processRecordId, string parameterSetName = null, global::System.Collections.Generic.IDictionary extensibleParameters = null)
+ {
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.HttpPipeline pipeline = null;
+ BeforeCreatePipeline(invocationInfo, ref pipeline);
+ pipeline = (pipeline ?? (_useProxy ? _pipelineWithProxy : _pipeline)).Clone();
+ AfterCreatePipeline(invocationInfo, ref pipeline);
+ pipeline.Append(new Runtime.CmdInfoHandler(processRecordId, invocationInfo, parameterSetName).SendAsync);
+ OnNewRequest?.Invoke( invocationInfo, correlationId,processRecordId, (step)=> { pipeline.Prepend(step); } , (step)=> { pipeline.Append(step); } );
+ return pipeline;
+ }
+
+ /// Gets parameters from a common module.
+ /// The from the cmdlet
+ /// the cmdlet's correlation id.
+ /// The name of the parameter to get the value for.
+ ///
+ /// The parameter value from the common module. (Note: this should be type converted on the way back)
+ ///
+ public object GetParameter(global::System.Management.Automation.InvocationInfo invocationInfo, string correlationId, string parameterName) => GetParameterValue?.Invoke( ResourceId, Name, invocationInfo, correlationId,parameterName );
+
+ /// Initialization steps performed after the module is loaded.
+ public void Init()
+ {
+ OnModuleLoad?.Invoke( ResourceId, Name ,(step)=> { _pipeline.Prepend(step); } , (step)=> { _pipeline.Append(step); } );
+ OnModuleLoad?.Invoke( ResourceId, Name ,(step)=> { _pipelineWithProxy.Prepend(step); } , (step)=> { _pipelineWithProxy.Append(step); } );
+ CustomInit();
+ }
+
+ /// Creates the module instance.
+ private Module()
+ {
+ // constructor
+ ClientAPI = new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.SecurityCenter();
+ _handler.Proxy = _webProxy;
+ _pipeline = new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.HttpPipeline(new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.HttpClientFactory(new global::System.Net.Http.HttpClient()));
+ _pipelineWithProxy = new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.HttpPipeline(new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.HttpClientFactory(new global::System.Net.Http.HttpClient(_handler)));
+ }
+
+ /// The HTTP Proxy to use.
+ /// The HTTP Proxy Credentials
+ /// True if the proxy should use default credentials
+ public void SetProxyConfiguration(global::System.Uri proxy, global::System.Management.Automation.PSCredential proxyCredential, bool proxyUseDefaultCredentials)
+ {
+ _useProxy = proxy != null;
+ if (proxy == null)
+ {
+ return;
+ }
+ // set the proxy configuration
+ _webProxy.Address = proxy;
+ _webProxy.BypassProxyOnLocal = false;
+ if (proxyUseDefaultCredentials)
+ {
+ _webProxy.Credentials = null;
+ _webProxy.UseDefaultCredentials = true;
+ }
+ else
+ {
+ _webProxy.UseDefaultCredentials = false;
+ _webProxy.Credentials = proxyCredential ?.GetNetworkCredential();
+ }
+ }
+
+ /// Called to dispatch events to the common module listener
+ /// The ID of the event
+ /// The cancellation token for the event
+ /// A delegate to get the detailed event data
+ /// The callback for the event dispatcher
+ /// The from the cmdlet
+ /// the cmdlet's parameterset name.
+ /// the cmdlet's correlation id.
+ /// the cmdlet's process record correlation id.
+ /// the exception that is being thrown (if available)
+ ///
+ /// A that will be complete when handling of the event is completed.
+ ///
+ public async global::System.Threading.Tasks.Task Signal(string id, global::System.Threading.CancellationToken token, global::System.Func getEventData, SignalDelegate signal, global::System.Management.Automation.InvocationInfo invocationInfo, string parameterSetName, string correlationId, string processRecordId, global::System.Exception exception)
+ {
+ using( NoSynchronizationContext )
+ {
+ await EventListener?.Invoke(id,token,getEventData, signal, invocationInfo, parameterSetName, correlationId,processRecordId,exception);
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Any.PowerShell.cs b/swaggerci/security/generated/api/Models/Any.PowerShell.cs
new file mode 100644
index 000000000000..ada57ba7e251
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Any.PowerShell.cs
@@ -0,0 +1,136 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models
+{
+ using Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.PowerShell;
+
+ /// Any object
+ [System.ComponentModel.TypeConverter(typeof(AnyTypeConverter))]
+ public partial class Any
+ {
+
+ ///
+ /// AfterDeserializeDictionary will be called after the deserialization has finished, allowing customization of the
+ /// object before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+
+ partial void AfterDeserializeDictionary(global::System.Collections.IDictionary content);
+
+ ///
+ /// AfterDeserializePSObject will be called after the deserialization has finished, allowing customization of the object
+ /// before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+
+ partial void AfterDeserializePSObject(global::System.Management.Automation.PSObject content);
+
+ ///
+ /// BeforeDeserializeDictionary will be called before the deserialization has commenced, allowing complete customization
+ /// of the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeDeserializeDictionary(global::System.Collections.IDictionary content, ref bool returnNow);
+
+ ///
+ /// BeforeDeserializePSObject will be called before the deserialization has commenced, allowing complete customization
+ /// of the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeDeserializePSObject(global::System.Management.Automation.PSObject content, ref bool returnNow);
+
+ ///
+ /// Deserializes a into a new instance of .
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ internal Any(global::System.Collections.IDictionary content)
+ {
+ bool returnNow = false;
+ BeforeDeserializeDictionary(content, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ // actually deserialize
+ AfterDeserializeDictionary(content);
+ }
+
+ ///
+ /// Deserializes a into a new instance of .
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ internal Any(global::System.Management.Automation.PSObject content)
+ {
+ bool returnNow = false;
+ BeforeDeserializePSObject(content, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ // actually deserialize
+ AfterDeserializePSObject(content);
+ }
+
+ ///
+ /// Deserializes a into an instance of .
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ ///
+ /// an instance of .
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny DeserializeFromDictionary(global::System.Collections.IDictionary content)
+ {
+ return new Any(content);
+ }
+
+ ///
+ /// Deserializes a into an instance of .
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ ///
+ /// an instance of .
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny DeserializeFromPSObject(global::System.Management.Automation.PSObject content)
+ {
+ return new Any(content);
+ }
+
+ ///
+ /// Creates a new instance of , deserializing the content from a json string.
+ ///
+ /// a string containing a JSON serialized instance of this model.
+ /// an instance of the model class.
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny FromJsonString(string jsonText) => FromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode.Parse(jsonText));
+
+ /// Serializes this instance to a json string.
+
+ /// a containing this model serialized to JSON text.
+ public string ToJsonString() => ToJson(null, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode.IncludeAll)?.ToString();
+ }
+ /// Any object
+ [System.ComponentModel.TypeConverter(typeof(AnyTypeConverter))]
+ public partial interface IAny
+
+ {
+
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Any.TypeConverter.cs b/swaggerci/security/generated/api/Models/Any.TypeConverter.cs
new file mode 100644
index 000000000000..13433390992c
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Any.TypeConverter.cs
@@ -0,0 +1,146 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models
+{
+ using Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.PowerShell;
+
+ ///
+ /// A PowerShell PSTypeConverter to support converting to an instance of
+ ///
+ public partial class AnyTypeConverter : global::System.Management.Automation.PSTypeConverter
+ {
+
+ ///
+ /// Determines if the converter can convert the parameter to the parameter.
+ ///
+ /// the to convert from
+ /// the to convert to
+ ///
+ /// true if the converter can convert the parameter to the parameter, otherwise false.
+ ///
+ public override bool CanConvertFrom(object sourceValue, global::System.Type destinationType) => CanConvertFrom(sourceValue);
+
+ ///
+ /// Determines if the converter can convert the parameter to the type.
+ ///
+ /// the instance to check if it can be converted to the type.
+ ///
+ /// true if the instance could be converted to a type, otherwise false
+ ///
+ public static bool CanConvertFrom(dynamic sourceValue)
+ {
+ if (null == sourceValue)
+ {
+ return true;
+ }
+ global::System.Type type = sourceValue.GetType();
+ if (typeof(global::System.Management.Automation.PSObject).IsAssignableFrom(type))
+ {
+ // we say yest to PSObjects
+ return true;
+ }
+ if (typeof(global::System.Collections.IDictionary).IsAssignableFrom(type))
+ {
+ // we say yest to Hashtables/dictionaries
+ return true;
+ }
+ try
+ {
+ if (null != sourceValue.ToJsonString())
+ {
+ return true;
+ }
+ }
+ catch
+ {
+ // Not one of our objects
+ }
+ try
+ {
+ string text = sourceValue.ToString()?.Trim();
+ return true == text?.StartsWith("{") && true == text?.EndsWith("}") && Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode.Parse(text).Type == Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonType.Object;
+ }
+ catch
+ {
+ // Doesn't look like it can be treated as JSON
+ }
+ return false;
+ }
+
+ ///
+ /// Determines if the parameter can be converted to the
+ /// parameter
+ ///
+ /// the to convert from
+ /// the to convert to
+ ///
+ /// true if the converter can convert the parameter to the parameter, otherwise false
+ ///
+ public override bool CanConvertTo(object sourceValue, global::System.Type destinationType) => false;
+
+ ///
+ /// Converts the parameter to the parameter using and
+ ///
+ /// the to convert from
+ /// the to convert to
+ /// not used by this TypeConverter.
+ /// when set to true, will ignore the case when converting.
+ ///
+ /// an instance of , or null if there is no suitable conversion.
+ ///
+ public override object ConvertFrom(object sourceValue, global::System.Type destinationType, global::System.IFormatProvider formatProvider, bool ignoreCase) => ConvertFrom(sourceValue);
+
+ ///
+ /// Converts the parameter into an instance of
+ ///
+ /// the value to convert into an instance of .
+ ///
+ /// an instance of , or null if there is no suitable conversion.
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny ConvertFrom(dynamic sourceValue)
+ {
+ if (null == sourceValue)
+ {
+ return null;
+ }
+ global::System.Type type = sourceValue.GetType();
+ if (typeof(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny).IsAssignableFrom(type))
+ {
+ return sourceValue;
+ }
+ try
+ {
+ return Any.FromJsonString(typeof(string) == sourceValue.GetType() ? sourceValue : sourceValue.ToJsonString());;
+ }
+ catch
+ {
+ // Unable to use JSON pattern
+ }
+ if (typeof(global::System.Management.Automation.PSObject).IsAssignableFrom(type))
+ {
+ return Any.DeserializeFromPSObject(sourceValue);
+ }
+ if (typeof(global::System.Collections.IDictionary).IsAssignableFrom(type))
+ {
+ return Any.DeserializeFromDictionary(sourceValue);
+ }
+ return null;
+ }
+
+ /// NotImplemented -- this will return null
+ /// the to convert from
+ /// the to convert to
+ /// not used by this TypeConverter.
+ /// when set to true, will ignore the case when converting.
+ /// will always return null.
+ public override object ConvertTo(object sourceValue, global::System.Type destinationType, global::System.IFormatProvider formatProvider, bool ignoreCase) => null;
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Any.cs b/swaggerci/security/generated/api/Models/Any.cs
new file mode 100644
index 000000000000..352cfa93e272
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Any.cs
@@ -0,0 +1,34 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models
+{
+ using static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Extensions;
+
+ /// Any object
+ public partial class Any :
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny,
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAnyInternal
+ {
+
+ /// Creates an new instance.
+ public Any()
+ {
+
+ }
+ }
+ /// Any object
+ public partial interface IAny :
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.IJsonSerializable
+ {
+
+ }
+ /// Any object
+ internal partial interface IAnyInternal
+
+ {
+
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Any.json.cs b/swaggerci/security/generated/api/Models/Any.json.cs
new file mode 100644
index 000000000000..ceffaf388aa9
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Any.json.cs
@@ -0,0 +1,104 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models
+{
+ using static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Extensions;
+
+ /// Any object
+ public partial class Any
+ {
+
+ ///
+ /// AfterFromJson will be called after the json deserialization has finished, allowing customization of the object
+ /// before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The JsonNode that should be deserialized into this object.
+
+ partial void AfterFromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json);
+
+ ///
+ /// AfterToJson will be called after the json serialization has finished, allowing customization of the before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The JSON container that the serialization result will be placed in.
+
+ partial void AfterToJson(ref Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container);
+
+ ///
+ /// BeforeFromJson will be called before the json deserialization has commenced, allowing complete customization of
+ /// the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the
+ /// output parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The JsonNode that should be deserialized into this object.
+ /// Determines if the rest of the deserialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeFromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json, ref bool returnNow);
+
+ ///
+ /// BeforeToJson will be called before the json serialization has commenced, allowing complete customization of the
+ /// object before it is serialized.
+ /// If you wish to disable the default serialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The JSON container that the serialization result will be placed in.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeToJson(ref Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container, ref bool returnNow);
+
+ ///
+ /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject into a new instance of .
+ ///
+ /// A Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject instance to deserialize from.
+ internal Any(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json)
+ {
+ bool returnNow = false;
+ BeforeFromJson(json, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ AfterFromJson(json);
+ }
+
+ ///
+ /// Deserializes a into an instance of Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny.
+ ///
+ /// a to deserialize from.
+ /// an instance of Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny.
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny FromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode node)
+ {
+ return node is Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json ? new Any(json) : null;
+ }
+
+ ///
+ /// Serializes this instance of into a .
+ ///
+ /// The container to serialize this object into. If the caller
+ /// passes in null, a new instance will be created and returned to the caller.
+ /// Allows the caller to choose the depth of the serialization. See .
+ ///
+ /// a serialized instance of as a .
+ ///
+ public Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode ToJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode serializationMode)
+ {
+ container = container ?? new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject();
+
+ bool returnNow = false;
+ BeforeToJson(ref container, ref returnNow);
+ if (returnNow)
+ {
+ return container;
+ }
+ AfterToJson(ref container);
+ return container;
+ }
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api10/CloudError.PowerShell.cs b/swaggerci/security/generated/api/Models/Api10/CloudError.PowerShell.cs
new file mode 100644
index 000000000000..1194fea06053
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api10/CloudError.PowerShell.cs
@@ -0,0 +1,188 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10
+{
+ using Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.PowerShell;
+
+ ///
+ /// Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows
+ /// the OData error response format.).
+ ///
+ [System.ComponentModel.TypeConverter(typeof(CloudErrorTypeConverter))]
+ public partial class CloudError
+ {
+
+ ///
+ /// AfterDeserializeDictionary will be called after the deserialization has finished, allowing customization of the
+ /// object before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+
+ partial void AfterDeserializeDictionary(global::System.Collections.IDictionary content);
+
+ ///
+ /// AfterDeserializePSObject will be called after the deserialization has finished, allowing customization of the object
+ /// before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+
+ partial void AfterDeserializePSObject(global::System.Management.Automation.PSObject content);
+
+ ///
+ /// BeforeDeserializeDictionary will be called before the deserialization has commenced, allowing complete customization
+ /// of the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeDeserializeDictionary(global::System.Collections.IDictionary content, ref bool returnNow);
+
+ ///
+ /// BeforeDeserializePSObject will be called before the deserialization has commenced, allowing complete customization
+ /// of the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeDeserializePSObject(global::System.Management.Automation.PSObject content, ref bool returnNow);
+
+ ///
+ /// Deserializes a into a new instance of .
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ internal CloudError(global::System.Collections.IDictionary content)
+ {
+ bool returnNow = false;
+ BeforeDeserializeDictionary(content, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ // actually deserialize
+ if (content.Contains("Error"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Error = (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody) content.GetValueForProperty("Error",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Error, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.CloudErrorBodyTypeConverter.ConvertFrom);
+ }
+ if (content.Contains("Code"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Code = (string) content.GetValueForProperty("Code",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Code, global::System.Convert.ToString);
+ }
+ if (content.Contains("Message"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Message = (string) content.GetValueForProperty("Message",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Message, global::System.Convert.ToString);
+ }
+ if (content.Contains("Target"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Target = (string) content.GetValueForProperty("Target",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Target, global::System.Convert.ToString);
+ }
+ if (content.Contains("Detail"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Detail = (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody[]) content.GetValueForProperty("Detail",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Detail, __y => TypeConverterExtensions.SelectToArray(__y, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.CloudErrorBodyTypeConverter.ConvertFrom));
+ }
+ if (content.Contains("AdditionalInfo"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).AdditionalInfo = (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo[]) content.GetValueForProperty("AdditionalInfo",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).AdditionalInfo, __y => TypeConverterExtensions.SelectToArray(__y, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ErrorAdditionalInfoTypeConverter.ConvertFrom));
+ }
+ AfterDeserializeDictionary(content);
+ }
+
+ ///
+ /// Deserializes a into a new instance of .
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ internal CloudError(global::System.Management.Automation.PSObject content)
+ {
+ bool returnNow = false;
+ BeforeDeserializePSObject(content, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ // actually deserialize
+ if (content.Contains("Error"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Error = (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody) content.GetValueForProperty("Error",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Error, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.CloudErrorBodyTypeConverter.ConvertFrom);
+ }
+ if (content.Contains("Code"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Code = (string) content.GetValueForProperty("Code",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Code, global::System.Convert.ToString);
+ }
+ if (content.Contains("Message"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Message = (string) content.GetValueForProperty("Message",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Message, global::System.Convert.ToString);
+ }
+ if (content.Contains("Target"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Target = (string) content.GetValueForProperty("Target",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Target, global::System.Convert.ToString);
+ }
+ if (content.Contains("Detail"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Detail = (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody[]) content.GetValueForProperty("Detail",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).Detail, __y => TypeConverterExtensions.SelectToArray(__y, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.CloudErrorBodyTypeConverter.ConvertFrom));
+ }
+ if (content.Contains("AdditionalInfo"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).AdditionalInfo = (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo[]) content.GetValueForProperty("AdditionalInfo",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal)this).AdditionalInfo, __y => TypeConverterExtensions.SelectToArray(__y, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ErrorAdditionalInfoTypeConverter.ConvertFrom));
+ }
+ AfterDeserializePSObject(content);
+ }
+
+ ///
+ /// Deserializes a into an instance of .
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ ///
+ /// an instance of .
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudError DeserializeFromDictionary(global::System.Collections.IDictionary content)
+ {
+ return new CloudError(content);
+ }
+
+ ///
+ /// Deserializes a into an instance of .
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ ///
+ /// an instance of .
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudError DeserializeFromPSObject(global::System.Management.Automation.PSObject content)
+ {
+ return new CloudError(content);
+ }
+
+ ///
+ /// Creates a new instance of , deserializing the content from a json string.
+ ///
+ /// a string containing a JSON serialized instance of this model.
+ /// an instance of the model class.
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudError FromJsonString(string jsonText) => FromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode.Parse(jsonText));
+
+ /// Serializes this instance to a json string.
+
+ /// a containing this model serialized to JSON text.
+ public string ToJsonString() => ToJson(null, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode.IncludeAll)?.ToString();
+ }
+ /// Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows
+ /// the OData error response format.).
+ [System.ComponentModel.TypeConverter(typeof(CloudErrorTypeConverter))]
+ public partial interface ICloudError
+
+ {
+
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api10/CloudError.TypeConverter.cs b/swaggerci/security/generated/api/Models/Api10/CloudError.TypeConverter.cs
new file mode 100644
index 000000000000..2d13e5ba7770
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api10/CloudError.TypeConverter.cs
@@ -0,0 +1,146 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10
+{
+ using Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.PowerShell;
+
+ ///
+ /// A PowerShell PSTypeConverter to support converting to an instance of
+ ///
+ public partial class CloudErrorTypeConverter : global::System.Management.Automation.PSTypeConverter
+ {
+
+ ///
+ /// Determines if the converter can convert the parameter to the parameter.
+ ///
+ /// the to convert from
+ /// the to convert to
+ ///
+ /// true if the converter can convert the parameter to the parameter, otherwise false.
+ ///
+ public override bool CanConvertFrom(object sourceValue, global::System.Type destinationType) => CanConvertFrom(sourceValue);
+
+ ///
+ /// Determines if the converter can convert the parameter to the type.
+ ///
+ /// the instance to check if it can be converted to the type.
+ ///
+ /// true if the instance could be converted to a type, otherwise false
+ ///
+ public static bool CanConvertFrom(dynamic sourceValue)
+ {
+ if (null == sourceValue)
+ {
+ return true;
+ }
+ global::System.Type type = sourceValue.GetType();
+ if (typeof(global::System.Management.Automation.PSObject).IsAssignableFrom(type))
+ {
+ // we say yest to PSObjects
+ return true;
+ }
+ if (typeof(global::System.Collections.IDictionary).IsAssignableFrom(type))
+ {
+ // we say yest to Hashtables/dictionaries
+ return true;
+ }
+ try
+ {
+ if (null != sourceValue.ToJsonString())
+ {
+ return true;
+ }
+ }
+ catch
+ {
+ // Not one of our objects
+ }
+ try
+ {
+ string text = sourceValue.ToString()?.Trim();
+ return true == text?.StartsWith("{") && true == text?.EndsWith("}") && Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode.Parse(text).Type == Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonType.Object;
+ }
+ catch
+ {
+ // Doesn't look like it can be treated as JSON
+ }
+ return false;
+ }
+
+ ///
+ /// Determines if the parameter can be converted to the
+ /// parameter
+ ///
+ /// the to convert from
+ /// the to convert to
+ ///
+ /// true if the converter can convert the parameter to the parameter, otherwise false
+ ///
+ public override bool CanConvertTo(object sourceValue, global::System.Type destinationType) => false;
+
+ ///
+ /// Converts the parameter to the parameter using and
+ ///
+ /// the to convert from
+ /// the to convert to
+ /// not used by this TypeConverter.
+ /// when set to true, will ignore the case when converting.
+ ///
+ /// an instance of , or null if there is no suitable conversion.
+ ///
+ public override object ConvertFrom(object sourceValue, global::System.Type destinationType, global::System.IFormatProvider formatProvider, bool ignoreCase) => ConvertFrom(sourceValue);
+
+ ///
+ /// Converts the parameter into an instance of
+ ///
+ /// the value to convert into an instance of .
+ ///
+ /// an instance of , or null if there is no suitable conversion.
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudError ConvertFrom(dynamic sourceValue)
+ {
+ if (null == sourceValue)
+ {
+ return null;
+ }
+ global::System.Type type = sourceValue.GetType();
+ if (typeof(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudError).IsAssignableFrom(type))
+ {
+ return sourceValue;
+ }
+ try
+ {
+ return CloudError.FromJsonString(typeof(string) == sourceValue.GetType() ? sourceValue : sourceValue.ToJsonString());;
+ }
+ catch
+ {
+ // Unable to use JSON pattern
+ }
+ if (typeof(global::System.Management.Automation.PSObject).IsAssignableFrom(type))
+ {
+ return CloudError.DeserializeFromPSObject(sourceValue);
+ }
+ if (typeof(global::System.Collections.IDictionary).IsAssignableFrom(type))
+ {
+ return CloudError.DeserializeFromDictionary(sourceValue);
+ }
+ return null;
+ }
+
+ /// NotImplemented -- this will return null
+ /// the to convert from
+ /// the to convert to
+ /// not used by this TypeConverter.
+ /// when set to true, will ignore the case when converting.
+ /// will always return null.
+ public override object ConvertTo(object sourceValue, global::System.Type destinationType, global::System.IFormatProvider formatProvider, bool ignoreCase) => null;
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api10/CloudError.cs b/swaggerci/security/generated/api/Models/Api10/CloudError.cs
new file mode 100644
index 000000000000..e78bbcfd8a3d
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api10/CloudError.cs
@@ -0,0 +1,136 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10
+{
+ using static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Extensions;
+
+ ///
+ /// Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows
+ /// the OData error response format.).
+ ///
+ public partial class CloudError :
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudError,
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal
+ {
+
+ /// The error additional info.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Inlined)]
+ public Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo[] AdditionalInfo { get => ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)Error).AdditionalInfo; }
+
+ /// The error code.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Inlined)]
+ public string Code { get => ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)Error).Code; }
+
+ /// The error details.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Inlined)]
+ public Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody[] Detail { get => ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)Error).Detail; }
+
+ /// Backing field for property.
+ private Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody _error;
+
+ /// The error object.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Owned)]
+ internal Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody Error { get => (this._error = this._error ?? new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.CloudErrorBody()); set => this._error = value; }
+
+ /// The error message.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Inlined)]
+ public string Message { get => ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)Error).Message; }
+
+ /// Internal Acessors for AdditionalInfo
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo[] Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal.AdditionalInfo { get => ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)Error).AdditionalInfo; set => ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)Error).AdditionalInfo = value; }
+
+ /// Internal Acessors for Code
+ string Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal.Code { get => ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)Error).Code; set => ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)Error).Code = value; }
+
+ /// Internal Acessors for Detail
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody[] Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal.Detail { get => ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)Error).Detail; set => ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)Error).Detail = value; }
+
+ /// Internal Acessors for Error
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal.Error { get => (this._error = this._error ?? new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.CloudErrorBody()); set { {_error = value;} } }
+
+ /// Internal Acessors for Message
+ string Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal.Message { get => ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)Error).Message; set => ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)Error).Message = value; }
+
+ /// Internal Acessors for Target
+ string Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorInternal.Target { get => ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)Error).Target; set => ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)Error).Target = value; }
+
+ /// The error target.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Inlined)]
+ public string Target { get => ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)Error).Target; }
+
+ /// Creates an new instance.
+ public CloudError()
+ {
+
+ }
+ }
+ /// Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows
+ /// the OData error response format.).
+ public partial interface ICloudError :
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.IJsonSerializable
+ {
+ /// The error additional info.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = true,
+ Description = @"The error additional info.",
+ SerializedName = @"additionalInfo",
+ PossibleTypes = new [] { typeof(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo) })]
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo[] AdditionalInfo { get; }
+ /// The error code.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = true,
+ Description = @"The error code.",
+ SerializedName = @"code",
+ PossibleTypes = new [] { typeof(string) })]
+ string Code { get; }
+ /// The error details.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = true,
+ Description = @"The error details.",
+ SerializedName = @"details",
+ PossibleTypes = new [] { typeof(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody) })]
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody[] Detail { get; }
+ /// The error message.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = true,
+ Description = @"The error message.",
+ SerializedName = @"message",
+ PossibleTypes = new [] { typeof(string) })]
+ string Message { get; }
+ /// The error target.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = true,
+ Description = @"The error target.",
+ SerializedName = @"target",
+ PossibleTypes = new [] { typeof(string) })]
+ string Target { get; }
+
+ }
+ /// Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows
+ /// the OData error response format.).
+ internal partial interface ICloudErrorInternal
+
+ {
+ /// The error additional info.
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo[] AdditionalInfo { get; set; }
+ /// The error code.
+ string Code { get; set; }
+ /// The error details.
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody[] Detail { get; set; }
+ /// The error object.
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody Error { get; set; }
+ /// The error message.
+ string Message { get; set; }
+ /// The error target.
+ string Target { get; set; }
+
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api10/CloudError.json.cs b/swaggerci/security/generated/api/Models/Api10/CloudError.json.cs
new file mode 100644
index 000000000000..649e3f8b8e89
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api10/CloudError.json.cs
@@ -0,0 +1,111 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10
+{
+ using static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Extensions;
+
+ ///
+ /// Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows
+ /// the OData error response format.).
+ ///
+ public partial class CloudError
+ {
+
+ ///
+ /// AfterFromJson will be called after the json deserialization has finished, allowing customization of the object
+ /// before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The JsonNode that should be deserialized into this object.
+
+ partial void AfterFromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json);
+
+ ///
+ /// AfterToJson will be called after the json serialization has finished, allowing customization of the before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The JSON container that the serialization result will be placed in.
+
+ partial void AfterToJson(ref Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container);
+
+ ///
+ /// BeforeFromJson will be called before the json deserialization has commenced, allowing complete customization of
+ /// the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the
+ /// output parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The JsonNode that should be deserialized into this object.
+ /// Determines if the rest of the deserialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeFromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json, ref bool returnNow);
+
+ ///
+ /// BeforeToJson will be called before the json serialization has commenced, allowing complete customization of the
+ /// object before it is serialized.
+ /// If you wish to disable the default serialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The JSON container that the serialization result will be placed in.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeToJson(ref Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container, ref bool returnNow);
+
+ ///
+ /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject into a new instance of .
+ ///
+ /// A Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject instance to deserialize from.
+ internal CloudError(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json)
+ {
+ bool returnNow = false;
+ BeforeFromJson(json, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ {_error = If( json?.PropertyT("error"), out var __jsonError) ? Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.CloudErrorBody.FromJson(__jsonError) : Error;}
+ AfterFromJson(json);
+ }
+
+ ///
+ /// Deserializes a into an instance of Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudError.
+ ///
+ /// a to deserialize from.
+ ///
+ /// an instance of Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudError.
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudError FromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode node)
+ {
+ return node is Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json ? new CloudError(json) : null;
+ }
+
+ ///
+ /// Serializes this instance of into a .
+ ///
+ /// The container to serialize this object into. If the caller
+ /// passes in null, a new instance will be created and returned to the caller.
+ /// Allows the caller to choose the depth of the serialization. See .
+ ///
+ /// a serialized instance of as a .
+ ///
+ public Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode ToJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode serializationMode)
+ {
+ container = container ?? new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject();
+
+ bool returnNow = false;
+ BeforeToJson(ref container, ref returnNow);
+ if (returnNow)
+ {
+ return container;
+ }
+ AddIf( null != this._error ? (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode) this._error.ToJson(null,serializationMode) : null, "error" ,container.Add );
+ AfterToJson(ref container);
+ return container;
+ }
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api10/CloudErrorBody.PowerShell.cs b/swaggerci/security/generated/api/Models/Api10/CloudErrorBody.PowerShell.cs
new file mode 100644
index 000000000000..011e2fcf96fd
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api10/CloudErrorBody.PowerShell.cs
@@ -0,0 +1,176 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10
+{
+ using Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.PowerShell;
+
+ /// The error detail.
+ [System.ComponentModel.TypeConverter(typeof(CloudErrorBodyTypeConverter))]
+ public partial class CloudErrorBody
+ {
+
+ ///
+ /// AfterDeserializeDictionary will be called after the deserialization has finished, allowing customization of the
+ /// object before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+
+ partial void AfterDeserializeDictionary(global::System.Collections.IDictionary content);
+
+ ///
+ /// AfterDeserializePSObject will be called after the deserialization has finished, allowing customization of the object
+ /// before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+
+ partial void AfterDeserializePSObject(global::System.Management.Automation.PSObject content);
+
+ ///
+ /// BeforeDeserializeDictionary will be called before the deserialization has commenced, allowing complete customization
+ /// of the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeDeserializeDictionary(global::System.Collections.IDictionary content, ref bool returnNow);
+
+ ///
+ /// BeforeDeserializePSObject will be called before the deserialization has commenced, allowing complete customization
+ /// of the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeDeserializePSObject(global::System.Management.Automation.PSObject content, ref bool returnNow);
+
+ ///
+ /// Deserializes a into a new instance of .
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ internal CloudErrorBody(global::System.Collections.IDictionary content)
+ {
+ bool returnNow = false;
+ BeforeDeserializeDictionary(content, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ // actually deserialize
+ if (content.Contains("Code"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).Code = (string) content.GetValueForProperty("Code",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).Code, global::System.Convert.ToString);
+ }
+ if (content.Contains("Message"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).Message = (string) content.GetValueForProperty("Message",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).Message, global::System.Convert.ToString);
+ }
+ if (content.Contains("Target"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).Target = (string) content.GetValueForProperty("Target",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).Target, global::System.Convert.ToString);
+ }
+ if (content.Contains("Detail"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).Detail = (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody[]) content.GetValueForProperty("Detail",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).Detail, __y => TypeConverterExtensions.SelectToArray(__y, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.CloudErrorBodyTypeConverter.ConvertFrom));
+ }
+ if (content.Contains("AdditionalInfo"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).AdditionalInfo = (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo[]) content.GetValueForProperty("AdditionalInfo",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).AdditionalInfo, __y => TypeConverterExtensions.SelectToArray(__y, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ErrorAdditionalInfoTypeConverter.ConvertFrom));
+ }
+ AfterDeserializeDictionary(content);
+ }
+
+ ///
+ /// Deserializes a into a new instance of .
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ internal CloudErrorBody(global::System.Management.Automation.PSObject content)
+ {
+ bool returnNow = false;
+ BeforeDeserializePSObject(content, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ // actually deserialize
+ if (content.Contains("Code"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).Code = (string) content.GetValueForProperty("Code",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).Code, global::System.Convert.ToString);
+ }
+ if (content.Contains("Message"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).Message = (string) content.GetValueForProperty("Message",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).Message, global::System.Convert.ToString);
+ }
+ if (content.Contains("Target"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).Target = (string) content.GetValueForProperty("Target",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).Target, global::System.Convert.ToString);
+ }
+ if (content.Contains("Detail"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).Detail = (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody[]) content.GetValueForProperty("Detail",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).Detail, __y => TypeConverterExtensions.SelectToArray(__y, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.CloudErrorBodyTypeConverter.ConvertFrom));
+ }
+ if (content.Contains("AdditionalInfo"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).AdditionalInfo = (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo[]) content.GetValueForProperty("AdditionalInfo",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal)this).AdditionalInfo, __y => TypeConverterExtensions.SelectToArray(__y, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ErrorAdditionalInfoTypeConverter.ConvertFrom));
+ }
+ AfterDeserializePSObject(content);
+ }
+
+ ///
+ /// Deserializes a into an instance of .
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ ///
+ /// an instance of .
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody DeserializeFromDictionary(global::System.Collections.IDictionary content)
+ {
+ return new CloudErrorBody(content);
+ }
+
+ ///
+ /// Deserializes a into an instance of .
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ ///
+ /// an instance of .
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody DeserializeFromPSObject(global::System.Management.Automation.PSObject content)
+ {
+ return new CloudErrorBody(content);
+ }
+
+ ///
+ /// Creates a new instance of , deserializing the content from a json string.
+ ///
+ /// a string containing a JSON serialized instance of this model.
+ /// an instance of the model class.
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody FromJsonString(string jsonText) => FromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode.Parse(jsonText));
+
+ /// Serializes this instance to a json string.
+
+ /// a containing this model serialized to JSON text.
+ public string ToJsonString() => ToJson(null, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode.IncludeAll)?.ToString();
+ }
+ /// The error detail.
+ [System.ComponentModel.TypeConverter(typeof(CloudErrorBodyTypeConverter))]
+ public partial interface ICloudErrorBody
+
+ {
+
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api10/CloudErrorBody.TypeConverter.cs b/swaggerci/security/generated/api/Models/Api10/CloudErrorBody.TypeConverter.cs
new file mode 100644
index 000000000000..46803e336f89
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api10/CloudErrorBody.TypeConverter.cs
@@ -0,0 +1,147 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10
+{
+ using Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.PowerShell;
+
+ ///
+ /// A PowerShell PSTypeConverter to support converting to an instance of
+ ///
+ public partial class CloudErrorBodyTypeConverter : global::System.Management.Automation.PSTypeConverter
+ {
+
+ ///
+ /// Determines if the converter can convert the parameter to the parameter.
+ ///
+ /// the to convert from
+ /// the to convert to
+ ///
+ /// true if the converter can convert the parameter to the parameter, otherwise false.
+ ///
+ public override bool CanConvertFrom(object sourceValue, global::System.Type destinationType) => CanConvertFrom(sourceValue);
+
+ ///
+ /// Determines if the converter can convert the parameter to the
+ /// type.
+ ///
+ /// the instance to check if it can be converted to the type.
+ ///
+ /// true if the instance could be converted to a type, otherwise false
+ ///
+ public static bool CanConvertFrom(dynamic sourceValue)
+ {
+ if (null == sourceValue)
+ {
+ return true;
+ }
+ global::System.Type type = sourceValue.GetType();
+ if (typeof(global::System.Management.Automation.PSObject).IsAssignableFrom(type))
+ {
+ // we say yest to PSObjects
+ return true;
+ }
+ if (typeof(global::System.Collections.IDictionary).IsAssignableFrom(type))
+ {
+ // we say yest to Hashtables/dictionaries
+ return true;
+ }
+ try
+ {
+ if (null != sourceValue.ToJsonString())
+ {
+ return true;
+ }
+ }
+ catch
+ {
+ // Not one of our objects
+ }
+ try
+ {
+ string text = sourceValue.ToString()?.Trim();
+ return true == text?.StartsWith("{") && true == text?.EndsWith("}") && Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode.Parse(text).Type == Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonType.Object;
+ }
+ catch
+ {
+ // Doesn't look like it can be treated as JSON
+ }
+ return false;
+ }
+
+ ///
+ /// Determines if the parameter can be converted to the
+ /// parameter
+ ///
+ /// the to convert from
+ /// the to convert to
+ ///
+ /// true if the converter can convert the parameter to the parameter, otherwise false
+ ///
+ public override bool CanConvertTo(object sourceValue, global::System.Type destinationType) => false;
+
+ ///
+ /// Converts the parameter to the parameter using and
+ ///
+ /// the to convert from
+ /// the to convert to
+ /// not used by this TypeConverter.
+ /// when set to true, will ignore the case when converting.
+ ///
+ /// an instance of , or null if there is no suitable conversion.
+ ///
+ public override object ConvertFrom(object sourceValue, global::System.Type destinationType, global::System.IFormatProvider formatProvider, bool ignoreCase) => ConvertFrom(sourceValue);
+
+ ///
+ /// Converts the parameter into an instance of
+ ///
+ /// the value to convert into an instance of .
+ ///
+ /// an instance of , or null if there is no suitable conversion.
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody ConvertFrom(dynamic sourceValue)
+ {
+ if (null == sourceValue)
+ {
+ return null;
+ }
+ global::System.Type type = sourceValue.GetType();
+ if (typeof(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody).IsAssignableFrom(type))
+ {
+ return sourceValue;
+ }
+ try
+ {
+ return CloudErrorBody.FromJsonString(typeof(string) == sourceValue.GetType() ? sourceValue : sourceValue.ToJsonString());;
+ }
+ catch
+ {
+ // Unable to use JSON pattern
+ }
+ if (typeof(global::System.Management.Automation.PSObject).IsAssignableFrom(type))
+ {
+ return CloudErrorBody.DeserializeFromPSObject(sourceValue);
+ }
+ if (typeof(global::System.Collections.IDictionary).IsAssignableFrom(type))
+ {
+ return CloudErrorBody.DeserializeFromDictionary(sourceValue);
+ }
+ return null;
+ }
+
+ /// NotImplemented -- this will return null
+ /// the to convert from
+ /// the to convert to
+ /// not used by this TypeConverter.
+ /// when set to true, will ignore the case when converting.
+ /// will always return null.
+ public override object ConvertTo(object sourceValue, global::System.Type destinationType, global::System.IFormatProvider formatProvider, bool ignoreCase) => null;
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api10/CloudErrorBody.cs b/swaggerci/security/generated/api/Models/Api10/CloudErrorBody.cs
new file mode 100644
index 000000000000..aa263f5b4ce2
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api10/CloudErrorBody.cs
@@ -0,0 +1,134 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10
+{
+ using static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Extensions;
+
+ /// The error detail.
+ public partial class CloudErrorBody :
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody,
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal
+ {
+
+ /// Backing field for property.
+ private Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo[] _additionalInfo;
+
+ /// The error additional info.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Owned)]
+ public Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo[] AdditionalInfo { get => this._additionalInfo; }
+
+ /// Backing field for property.
+ private string _code;
+
+ /// The error code.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Owned)]
+ public string Code { get => this._code; }
+
+ /// Backing field for property.
+ private Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody[] _detail;
+
+ /// The error details.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Owned)]
+ public Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody[] Detail { get => this._detail; }
+
+ /// Backing field for property.
+ private string _message;
+
+ /// The error message.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Owned)]
+ public string Message { get => this._message; }
+
+ /// Internal Acessors for AdditionalInfo
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo[] Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal.AdditionalInfo { get => this._additionalInfo; set { {_additionalInfo = value;} } }
+
+ /// Internal Acessors for Code
+ string Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal.Code { get => this._code; set { {_code = value;} } }
+
+ /// Internal Acessors for Detail
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody[] Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal.Detail { get => this._detail; set { {_detail = value;} } }
+
+ /// Internal Acessors for Message
+ string Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal.Message { get => this._message; set { {_message = value;} } }
+
+ /// Internal Acessors for Target
+ string Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBodyInternal.Target { get => this._target; set { {_target = value;} } }
+
+ /// Backing field for property.
+ private string _target;
+
+ /// The error target.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Owned)]
+ public string Target { get => this._target; }
+
+ /// Creates an new instance.
+ public CloudErrorBody()
+ {
+
+ }
+ }
+ /// The error detail.
+ public partial interface ICloudErrorBody :
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.IJsonSerializable
+ {
+ /// The error additional info.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = true,
+ Description = @"The error additional info.",
+ SerializedName = @"additionalInfo",
+ PossibleTypes = new [] { typeof(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo) })]
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo[] AdditionalInfo { get; }
+ /// The error code.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = true,
+ Description = @"The error code.",
+ SerializedName = @"code",
+ PossibleTypes = new [] { typeof(string) })]
+ string Code { get; }
+ /// The error details.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = true,
+ Description = @"The error details.",
+ SerializedName = @"details",
+ PossibleTypes = new [] { typeof(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody) })]
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody[] Detail { get; }
+ /// The error message.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = true,
+ Description = @"The error message.",
+ SerializedName = @"message",
+ PossibleTypes = new [] { typeof(string) })]
+ string Message { get; }
+ /// The error target.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = true,
+ Description = @"The error target.",
+ SerializedName = @"target",
+ PossibleTypes = new [] { typeof(string) })]
+ string Target { get; }
+
+ }
+ /// The error detail.
+ internal partial interface ICloudErrorBodyInternal
+
+ {
+ /// The error additional info.
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo[] AdditionalInfo { get; set; }
+ /// The error code.
+ string Code { get; set; }
+ /// The error details.
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody[] Detail { get; set; }
+ /// The error message.
+ string Message { get; set; }
+ /// The error target.
+ string Target { get; set; }
+
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api10/CloudErrorBody.json.cs b/swaggerci/security/generated/api/Models/Api10/CloudErrorBody.json.cs
new file mode 100644
index 000000000000..30b40b3f5f00
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api10/CloudErrorBody.json.cs
@@ -0,0 +1,147 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10
+{
+ using static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Extensions;
+
+ /// The error detail.
+ public partial class CloudErrorBody
+ {
+
+ ///
+ /// AfterFromJson will be called after the json deserialization has finished, allowing customization of the object
+ /// before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The JsonNode that should be deserialized into this object.
+
+ partial void AfterFromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json);
+
+ ///
+ /// AfterToJson will be called after the json serialization has finished, allowing customization of the before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The JSON container that the serialization result will be placed in.
+
+ partial void AfterToJson(ref Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container);
+
+ ///
+ /// BeforeFromJson will be called before the json deserialization has commenced, allowing complete customization of
+ /// the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the
+ /// output parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The JsonNode that should be deserialized into this object.
+ /// Determines if the rest of the deserialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeFromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json, ref bool returnNow);
+
+ ///
+ /// BeforeToJson will be called before the json serialization has commenced, allowing complete customization of the
+ /// object before it is serialized.
+ /// If you wish to disable the default serialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The JSON container that the serialization result will be placed in.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeToJson(ref Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container, ref bool returnNow);
+
+ ///
+ /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject into a new instance of .
+ ///
+ /// A Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject instance to deserialize from.
+ internal CloudErrorBody(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json)
+ {
+ bool returnNow = false;
+ BeforeFromJson(json, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ {_code = If( json?.PropertyT("code"), out var __jsonCode) ? (string)__jsonCode : (string)Code;}
+ {_message = If( json?.PropertyT("message"), out var __jsonMessage) ? (string)__jsonMessage : (string)Message;}
+ {_target = If( json?.PropertyT("target"), out var __jsonTarget) ? (string)__jsonTarget : (string)Target;}
+ {_detail = If( json?.PropertyT("details"), out var __jsonDetails) ? If( __jsonDetails as Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonArray, out var __v) ? new global::System.Func(()=> global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__v, (__u)=>(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody) (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.CloudErrorBody.FromJson(__u) )) ))() : null : Detail;}
+ {_additionalInfo = If( json?.PropertyT("additionalInfo"), out var __jsonAdditionalInfo) ? If( __jsonAdditionalInfo as Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonArray, out var __q) ? new global::System.Func(()=> global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__q, (__p)=>(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo) (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ErrorAdditionalInfo.FromJson(__p) )) ))() : null : AdditionalInfo;}
+ AfterFromJson(json);
+ }
+
+ ///
+ /// Deserializes a into an instance of Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody.
+ ///
+ /// a to deserialize from.
+ ///
+ /// an instance of Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody.
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.ICloudErrorBody FromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode node)
+ {
+ return node is Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json ? new CloudErrorBody(json) : null;
+ }
+
+ ///
+ /// Serializes this instance of into a .
+ ///
+ /// The container to serialize this object into. If the caller
+ /// passes in null, a new instance will be created and returned to the caller.
+ /// Allows the caller to choose the depth of the serialization. See .
+ ///
+ /// a serialized instance of as a .
+ ///
+ public Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode ToJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode serializationMode)
+ {
+ container = container ?? new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject();
+
+ bool returnNow = false;
+ BeforeToJson(ref container, ref returnNow);
+ if (returnNow)
+ {
+ return container;
+ }
+ if (serializationMode.HasFlag(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode.IncludeReadOnly))
+ {
+ AddIf( null != (((object)this._code)?.ToString()) ? (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode) new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonString(this._code.ToString()) : null, "code" ,container.Add );
+ }
+ if (serializationMode.HasFlag(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode.IncludeReadOnly))
+ {
+ AddIf( null != (((object)this._message)?.ToString()) ? (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode) new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonString(this._message.ToString()) : null, "message" ,container.Add );
+ }
+ if (serializationMode.HasFlag(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode.IncludeReadOnly))
+ {
+ AddIf( null != (((object)this._target)?.ToString()) ? (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode) new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonString(this._target.ToString()) : null, "target" ,container.Add );
+ }
+ if (serializationMode.HasFlag(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode.IncludeReadOnly))
+ {
+ if (null != this._detail)
+ {
+ var __w = new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.XNodeArray();
+ foreach( var __x in this._detail )
+ {
+ AddIf(__x?.ToJson(null, serializationMode) ,__w.Add);
+ }
+ container.Add("details",__w);
+ }
+ }
+ if (serializationMode.HasFlag(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode.IncludeReadOnly))
+ {
+ if (null != this._additionalInfo)
+ {
+ var __r = new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.XNodeArray();
+ foreach( var __s in this._additionalInfo )
+ {
+ AddIf(__s?.ToJson(null, serializationMode) ,__r.Add);
+ }
+ container.Add("additionalInfo",__r);
+ }
+ }
+ AfterToJson(ref container);
+ return container;
+ }
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api10/ErrorAdditionalInfo.PowerShell.cs b/swaggerci/security/generated/api/Models/Api10/ErrorAdditionalInfo.PowerShell.cs
new file mode 100644
index 000000000000..f32b1e6be0d5
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api10/ErrorAdditionalInfo.PowerShell.cs
@@ -0,0 +1,152 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10
+{
+ using Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.PowerShell;
+
+ /// The resource management error additional info.
+ [System.ComponentModel.TypeConverter(typeof(ErrorAdditionalInfoTypeConverter))]
+ public partial class ErrorAdditionalInfo
+ {
+
+ ///
+ /// AfterDeserializeDictionary will be called after the deserialization has finished, allowing customization of the
+ /// object before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+
+ partial void AfterDeserializeDictionary(global::System.Collections.IDictionary content);
+
+ ///
+ /// AfterDeserializePSObject will be called after the deserialization has finished, allowing customization of the object
+ /// before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+
+ partial void AfterDeserializePSObject(global::System.Management.Automation.PSObject content);
+
+ ///
+ /// BeforeDeserializeDictionary will be called before the deserialization has commenced, allowing complete customization
+ /// of the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeDeserializeDictionary(global::System.Collections.IDictionary content, ref bool returnNow);
+
+ ///
+ /// BeforeDeserializePSObject will be called before the deserialization has commenced, allowing complete customization
+ /// of the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeDeserializePSObject(global::System.Management.Automation.PSObject content, ref bool returnNow);
+
+ ///
+ /// Deserializes a into an instance of .
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ ///
+ /// an instance of .
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo DeserializeFromDictionary(global::System.Collections.IDictionary content)
+ {
+ return new ErrorAdditionalInfo(content);
+ }
+
+ ///
+ /// Deserializes a into an instance of .
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ ///
+ /// an instance of .
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo DeserializeFromPSObject(global::System.Management.Automation.PSObject content)
+ {
+ return new ErrorAdditionalInfo(content);
+ }
+
+ ///
+ /// Deserializes a into a new instance of .
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ internal ErrorAdditionalInfo(global::System.Collections.IDictionary content)
+ {
+ bool returnNow = false;
+ BeforeDeserializeDictionary(content, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ // actually deserialize
+ if (content.Contains("Type"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfoInternal)this).Type = (string) content.GetValueForProperty("Type",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfoInternal)this).Type, global::System.Convert.ToString);
+ }
+ if (content.Contains("Info"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfoInternal)this).Info = (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny) content.GetValueForProperty("Info",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfoInternal)this).Info, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.AnyTypeConverter.ConvertFrom);
+ }
+ AfterDeserializeDictionary(content);
+ }
+
+ ///
+ /// Deserializes a into a new instance of .
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ internal ErrorAdditionalInfo(global::System.Management.Automation.PSObject content)
+ {
+ bool returnNow = false;
+ BeforeDeserializePSObject(content, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ // actually deserialize
+ if (content.Contains("Type"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfoInternal)this).Type = (string) content.GetValueForProperty("Type",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfoInternal)this).Type, global::System.Convert.ToString);
+ }
+ if (content.Contains("Info"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfoInternal)this).Info = (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny) content.GetValueForProperty("Info",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfoInternal)this).Info, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.AnyTypeConverter.ConvertFrom);
+ }
+ AfterDeserializePSObject(content);
+ }
+
+ ///
+ /// Creates a new instance of , deserializing the content from a json string.
+ ///
+ /// a string containing a JSON serialized instance of this model.
+ /// an instance of the model class.
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo FromJsonString(string jsonText) => FromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode.Parse(jsonText));
+
+ /// Serializes this instance to a json string.
+
+ /// a containing this model serialized to JSON text.
+ public string ToJsonString() => ToJson(null, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode.IncludeAll)?.ToString();
+ }
+ /// The resource management error additional info.
+ [System.ComponentModel.TypeConverter(typeof(ErrorAdditionalInfoTypeConverter))]
+ public partial interface IErrorAdditionalInfo
+
+ {
+
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api10/ErrorAdditionalInfo.TypeConverter.cs b/swaggerci/security/generated/api/Models/Api10/ErrorAdditionalInfo.TypeConverter.cs
new file mode 100644
index 000000000000..e66bd5db2f8a
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api10/ErrorAdditionalInfo.TypeConverter.cs
@@ -0,0 +1,147 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10
+{
+ using Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.PowerShell;
+
+ ///
+ /// A PowerShell PSTypeConverter to support converting to an instance of
+ ///
+ public partial class ErrorAdditionalInfoTypeConverter : global::System.Management.Automation.PSTypeConverter
+ {
+
+ ///
+ /// Determines if the converter can convert the parameter to the parameter.
+ ///
+ /// the to convert from
+ /// the to convert to
+ ///
+ /// true if the converter can convert the parameter to the parameter, otherwise false.
+ ///
+ public override bool CanConvertFrom(object sourceValue, global::System.Type destinationType) => CanConvertFrom(sourceValue);
+
+ ///
+ /// Determines if the converter can convert the parameter to the
+ /// type.
+ ///
+ /// the instance to check if it can be converted to the type.
+ ///
+ /// true if the instance could be converted to a type, otherwise false
+ ///
+ public static bool CanConvertFrom(dynamic sourceValue)
+ {
+ if (null == sourceValue)
+ {
+ return true;
+ }
+ global::System.Type type = sourceValue.GetType();
+ if (typeof(global::System.Management.Automation.PSObject).IsAssignableFrom(type))
+ {
+ // we say yest to PSObjects
+ return true;
+ }
+ if (typeof(global::System.Collections.IDictionary).IsAssignableFrom(type))
+ {
+ // we say yest to Hashtables/dictionaries
+ return true;
+ }
+ try
+ {
+ if (null != sourceValue.ToJsonString())
+ {
+ return true;
+ }
+ }
+ catch
+ {
+ // Not one of our objects
+ }
+ try
+ {
+ string text = sourceValue.ToString()?.Trim();
+ return true == text?.StartsWith("{") && true == text?.EndsWith("}") && Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode.Parse(text).Type == Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonType.Object;
+ }
+ catch
+ {
+ // Doesn't look like it can be treated as JSON
+ }
+ return false;
+ }
+
+ ///
+ /// Determines if the parameter can be converted to the
+ /// parameter
+ ///
+ /// the to convert from
+ /// the to convert to
+ ///
+ /// true if the converter can convert the parameter to the parameter, otherwise false
+ ///
+ public override bool CanConvertTo(object sourceValue, global::System.Type destinationType) => false;
+
+ ///
+ /// Converts the parameter to the parameter using and
+ ///
+ /// the to convert from
+ /// the to convert to
+ /// not used by this TypeConverter.
+ /// when set to true, will ignore the case when converting.
+ ///
+ /// an instance of , or null if there is no suitable conversion.
+ ///
+ public override object ConvertFrom(object sourceValue, global::System.Type destinationType, global::System.IFormatProvider formatProvider, bool ignoreCase) => ConvertFrom(sourceValue);
+
+ ///
+ /// Converts the parameter into an instance of
+ ///
+ /// the value to convert into an instance of .
+ ///
+ /// an instance of , or null if there is no suitable conversion.
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo ConvertFrom(dynamic sourceValue)
+ {
+ if (null == sourceValue)
+ {
+ return null;
+ }
+ global::System.Type type = sourceValue.GetType();
+ if (typeof(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo).IsAssignableFrom(type))
+ {
+ return sourceValue;
+ }
+ try
+ {
+ return ErrorAdditionalInfo.FromJsonString(typeof(string) == sourceValue.GetType() ? sourceValue : sourceValue.ToJsonString());;
+ }
+ catch
+ {
+ // Unable to use JSON pattern
+ }
+ if (typeof(global::System.Management.Automation.PSObject).IsAssignableFrom(type))
+ {
+ return ErrorAdditionalInfo.DeserializeFromPSObject(sourceValue);
+ }
+ if (typeof(global::System.Collections.IDictionary).IsAssignableFrom(type))
+ {
+ return ErrorAdditionalInfo.DeserializeFromDictionary(sourceValue);
+ }
+ return null;
+ }
+
+ /// NotImplemented -- this will return null
+ /// the to convert from
+ /// the to convert to
+ /// not used by this TypeConverter.
+ /// when set to true, will ignore the case when converting.
+ /// will always return null.
+ public override object ConvertTo(object sourceValue, global::System.Type destinationType, global::System.IFormatProvider formatProvider, bool ignoreCase) => null;
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api10/ErrorAdditionalInfo.cs b/swaggerci/security/generated/api/Models/Api10/ErrorAdditionalInfo.cs
new file mode 100644
index 000000000000..7eec5176eaf5
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api10/ErrorAdditionalInfo.cs
@@ -0,0 +1,74 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10
+{
+ using static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Extensions;
+
+ /// The resource management error additional info.
+ public partial class ErrorAdditionalInfo :
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo,
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfoInternal
+ {
+
+ /// Backing field for property.
+ private Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny _info;
+
+ /// The additional info.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Owned)]
+ public Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny Info { get => (this._info = this._info ?? new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Any()); }
+
+ /// Internal Acessors for Info
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfoInternal.Info { get => (this._info = this._info ?? new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Any()); set { {_info = value;} } }
+
+ /// Internal Acessors for Type
+ string Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfoInternal.Type { get => this._type; set { {_type = value;} } }
+
+ /// Backing field for property.
+ private string _type;
+
+ /// The additional info type.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Owned)]
+ public string Type { get => this._type; }
+
+ /// Creates an new instance.
+ public ErrorAdditionalInfo()
+ {
+
+ }
+ }
+ /// The resource management error additional info.
+ public partial interface IErrorAdditionalInfo :
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.IJsonSerializable
+ {
+ /// The additional info.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = true,
+ Description = @"The additional info.",
+ SerializedName = @"info",
+ PossibleTypes = new [] { typeof(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny) })]
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny Info { get; }
+ /// The additional info type.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = true,
+ Description = @"The additional info type.",
+ SerializedName = @"type",
+ PossibleTypes = new [] { typeof(string) })]
+ string Type { get; }
+
+ }
+ /// The resource management error additional info.
+ internal partial interface IErrorAdditionalInfoInternal
+
+ {
+ /// The additional info.
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.IAny Info { get; set; }
+ /// The additional info type.
+ string Type { get; set; }
+
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api10/ErrorAdditionalInfo.json.cs b/swaggerci/security/generated/api/Models/Api10/ErrorAdditionalInfo.json.cs
new file mode 100644
index 000000000000..3096c9cc87fc
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api10/ErrorAdditionalInfo.json.cs
@@ -0,0 +1,116 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10
+{
+ using static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Extensions;
+
+ /// The resource management error additional info.
+ public partial class ErrorAdditionalInfo
+ {
+
+ ///
+ /// AfterFromJson will be called after the json deserialization has finished, allowing customization of the object
+ /// before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The JsonNode that should be deserialized into this object.
+
+ partial void AfterFromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json);
+
+ ///
+ /// AfterToJson will be called after the json serialization has finished, allowing customization of the before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The JSON container that the serialization result will be placed in.
+
+ partial void AfterToJson(ref Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container);
+
+ ///
+ /// BeforeFromJson will be called before the json deserialization has commenced, allowing complete customization of
+ /// the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the
+ /// output parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The JsonNode that should be deserialized into this object.
+ /// Determines if the rest of the deserialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeFromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json, ref bool returnNow);
+
+ ///
+ /// BeforeToJson will be called before the json serialization has commenced, allowing complete customization of the
+ /// object before it is serialized.
+ /// If you wish to disable the default serialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The JSON container that the serialization result will be placed in.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeToJson(ref Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container, ref bool returnNow);
+
+ ///
+ /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject into a new instance of .
+ ///
+ /// A Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject instance to deserialize from.
+ internal ErrorAdditionalInfo(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json)
+ {
+ bool returnNow = false;
+ BeforeFromJson(json, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ {_type = If( json?.PropertyT("type"), out var __jsonType) ? (string)__jsonType : (string)Type;}
+ {_info = If( json?.PropertyT("info"), out var __jsonInfo) ? Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Any.FromJson(__jsonInfo) : Info;}
+ AfterFromJson(json);
+ }
+
+ ///
+ /// Deserializes a into an instance of Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo.
+ ///
+ /// a to deserialize from.
+ ///
+ /// an instance of Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo.
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IErrorAdditionalInfo FromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode node)
+ {
+ return node is Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json ? new ErrorAdditionalInfo(json) : null;
+ }
+
+ ///
+ /// Serializes this instance of into a .
+ ///
+ /// The container to serialize this object into. If the caller
+ /// passes in null, a new instance will be created and returned to the caller.
+ /// Allows the caller to choose the depth of the serialization. See .
+ ///
+ /// a serialized instance of as a .
+ ///
+ public Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode ToJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode serializationMode)
+ {
+ container = container ?? new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject();
+
+ bool returnNow = false;
+ BeforeToJson(ref container, ref returnNow);
+ if (returnNow)
+ {
+ return container;
+ }
+ if (serializationMode.HasFlag(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode.IncludeReadOnly))
+ {
+ AddIf( null != (((object)this._type)?.ToString()) ? (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode) new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonString(this._type.ToString()) : null, "type" ,container.Add );
+ }
+ if (serializationMode.HasFlag(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode.IncludeReadOnly))
+ {
+ AddIf( null != this._info ? (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode) this._info.ToJson(null,serializationMode) : null, "info" ,container.Add );
+ }
+ AfterToJson(ref container);
+ return container;
+ }
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api10/Resource.PowerShell.cs b/swaggerci/security/generated/api/Models/Api10/Resource.PowerShell.cs
new file mode 100644
index 000000000000..ee5f2fc79cff
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api10/Resource.PowerShell.cs
@@ -0,0 +1,160 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10
+{
+ using Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.PowerShell;
+
+ /// Describes an Azure resource.
+ [System.ComponentModel.TypeConverter(typeof(ResourceTypeConverter))]
+ public partial class Resource
+ {
+
+ ///
+ /// AfterDeserializeDictionary will be called after the deserialization has finished, allowing customization of the
+ /// object before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+
+ partial void AfterDeserializeDictionary(global::System.Collections.IDictionary content);
+
+ ///
+ /// AfterDeserializePSObject will be called after the deserialization has finished, allowing customization of the object
+ /// before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+
+ partial void AfterDeserializePSObject(global::System.Management.Automation.PSObject content);
+
+ ///
+ /// BeforeDeserializeDictionary will be called before the deserialization has commenced, allowing complete customization
+ /// of the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeDeserializeDictionary(global::System.Collections.IDictionary content, ref bool returnNow);
+
+ ///
+ /// BeforeDeserializePSObject will be called before the deserialization has commenced, allowing complete customization
+ /// of the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeDeserializePSObject(global::System.Management.Automation.PSObject content, ref bool returnNow);
+
+ ///
+ /// Deserializes a into an instance of .
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ ///
+ /// an instance of .
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResource DeserializeFromDictionary(global::System.Collections.IDictionary content)
+ {
+ return new Resource(content);
+ }
+
+ ///
+ /// Deserializes a into an instance of .
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ ///
+ /// an instance of .
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResource DeserializeFromPSObject(global::System.Management.Automation.PSObject content)
+ {
+ return new Resource(content);
+ }
+
+ ///
+ /// Creates a new instance of , deserializing the content from a json string.
+ ///
+ /// a string containing a JSON serialized instance of this model.
+ /// an instance of the model class.
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResource FromJsonString(string jsonText) => FromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode.Parse(jsonText));
+
+ ///
+ /// Deserializes a into a new instance of .
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ internal Resource(global::System.Collections.IDictionary content)
+ {
+ bool returnNow = false;
+ BeforeDeserializeDictionary(content, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ // actually deserialize
+ if (content.Contains("Id"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResourceInternal)this).Id = (string) content.GetValueForProperty("Id",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResourceInternal)this).Id, global::System.Convert.ToString);
+ }
+ if (content.Contains("Name"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResourceInternal)this).Name = (string) content.GetValueForProperty("Name",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResourceInternal)this).Name, global::System.Convert.ToString);
+ }
+ if (content.Contains("Type"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResourceInternal)this).Type = (string) content.GetValueForProperty("Type",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResourceInternal)this).Type, global::System.Convert.ToString);
+ }
+ AfterDeserializeDictionary(content);
+ }
+
+ ///
+ /// Deserializes a into a new instance of .
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ internal Resource(global::System.Management.Automation.PSObject content)
+ {
+ bool returnNow = false;
+ BeforeDeserializePSObject(content, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ // actually deserialize
+ if (content.Contains("Id"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResourceInternal)this).Id = (string) content.GetValueForProperty("Id",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResourceInternal)this).Id, global::System.Convert.ToString);
+ }
+ if (content.Contains("Name"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResourceInternal)this).Name = (string) content.GetValueForProperty("Name",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResourceInternal)this).Name, global::System.Convert.ToString);
+ }
+ if (content.Contains("Type"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResourceInternal)this).Type = (string) content.GetValueForProperty("Type",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResourceInternal)this).Type, global::System.Convert.ToString);
+ }
+ AfterDeserializePSObject(content);
+ }
+
+ /// Serializes this instance to a json string.
+
+ /// a containing this model serialized to JSON text.
+ public string ToJsonString() => ToJson(null, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode.IncludeAll)?.ToString();
+ }
+ /// Describes an Azure resource.
+ [System.ComponentModel.TypeConverter(typeof(ResourceTypeConverter))]
+ public partial interface IResource
+
+ {
+
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api10/Resource.TypeConverter.cs b/swaggerci/security/generated/api/Models/Api10/Resource.TypeConverter.cs
new file mode 100644
index 000000000000..458a4188f91b
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api10/Resource.TypeConverter.cs
@@ -0,0 +1,146 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10
+{
+ using Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.PowerShell;
+
+ ///
+ /// A PowerShell PSTypeConverter to support converting to an instance of
+ ///
+ public partial class ResourceTypeConverter : global::System.Management.Automation.PSTypeConverter
+ {
+
+ ///
+ /// Determines if the converter can convert the parameter to the parameter.
+ ///
+ /// the to convert from
+ /// the to convert to
+ ///
+ /// true if the converter can convert the parameter to the parameter, otherwise false.
+ ///
+ public override bool CanConvertFrom(object sourceValue, global::System.Type destinationType) => CanConvertFrom(sourceValue);
+
+ ///
+ /// Determines if the converter can convert the parameter to the type.
+ ///
+ /// the instance to check if it can be converted to the type.
+ ///
+ /// true if the instance could be converted to a type, otherwise false
+ ///
+ public static bool CanConvertFrom(dynamic sourceValue)
+ {
+ if (null == sourceValue)
+ {
+ return true;
+ }
+ global::System.Type type = sourceValue.GetType();
+ if (typeof(global::System.Management.Automation.PSObject).IsAssignableFrom(type))
+ {
+ // we say yest to PSObjects
+ return true;
+ }
+ if (typeof(global::System.Collections.IDictionary).IsAssignableFrom(type))
+ {
+ // we say yest to Hashtables/dictionaries
+ return true;
+ }
+ try
+ {
+ if (null != sourceValue.ToJsonString())
+ {
+ return true;
+ }
+ }
+ catch
+ {
+ // Not one of our objects
+ }
+ try
+ {
+ string text = sourceValue.ToString()?.Trim();
+ return true == text?.StartsWith("{") && true == text?.EndsWith("}") && Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode.Parse(text).Type == Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonType.Object;
+ }
+ catch
+ {
+ // Doesn't look like it can be treated as JSON
+ }
+ return false;
+ }
+
+ ///
+ /// Determines if the parameter can be converted to the
+ /// parameter
+ ///
+ /// the to convert from
+ /// the to convert to
+ ///
+ /// true if the converter can convert the parameter to the parameter, otherwise false
+ ///
+ public override bool CanConvertTo(object sourceValue, global::System.Type destinationType) => false;
+
+ ///
+ /// Converts the parameter to the parameter using and
+ ///
+ /// the to convert from
+ /// the to convert to
+ /// not used by this TypeConverter.
+ /// when set to true, will ignore the case when converting.
+ ///
+ /// an instance of , or null if there is no suitable conversion.
+ ///
+ public override object ConvertFrom(object sourceValue, global::System.Type destinationType, global::System.IFormatProvider formatProvider, bool ignoreCase) => ConvertFrom(sourceValue);
+
+ ///
+ /// Converts the parameter into an instance of
+ ///
+ /// the value to convert into an instance of .
+ ///
+ /// an instance of , or null if there is no suitable conversion.
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResource ConvertFrom(dynamic sourceValue)
+ {
+ if (null == sourceValue)
+ {
+ return null;
+ }
+ global::System.Type type = sourceValue.GetType();
+ if (typeof(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResource).IsAssignableFrom(type))
+ {
+ return sourceValue;
+ }
+ try
+ {
+ return Resource.FromJsonString(typeof(string) == sourceValue.GetType() ? sourceValue : sourceValue.ToJsonString());;
+ }
+ catch
+ {
+ // Unable to use JSON pattern
+ }
+ if (typeof(global::System.Management.Automation.PSObject).IsAssignableFrom(type))
+ {
+ return Resource.DeserializeFromPSObject(sourceValue);
+ }
+ if (typeof(global::System.Collections.IDictionary).IsAssignableFrom(type))
+ {
+ return Resource.DeserializeFromDictionary(sourceValue);
+ }
+ return null;
+ }
+
+ /// NotImplemented -- this will return null
+ /// the to convert from
+ /// the to convert to
+ /// not used by this TypeConverter.
+ /// when set to true, will ignore the case when converting.
+ /// will always return null.
+ public override object ConvertTo(object sourceValue, global::System.Type destinationType, global::System.IFormatProvider formatProvider, bool ignoreCase) => null;
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api10/Resource.cs b/swaggerci/security/generated/api/Models/Api10/Resource.cs
new file mode 100644
index 000000000000..6369c15d1061
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api10/Resource.cs
@@ -0,0 +1,94 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10
+{
+ using static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Extensions;
+
+ /// Describes an Azure resource.
+ public partial class Resource :
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResource,
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResourceInternal
+ {
+
+ /// Backing field for property.
+ private string _id;
+
+ /// Resource Id
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Owned)]
+ public string Id { get => this._id; }
+
+ /// Internal Acessors for Id
+ string Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResourceInternal.Id { get => this._id; set { {_id = value;} } }
+
+ /// Internal Acessors for Name
+ string Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResourceInternal.Name { get => this._name; set { {_name = value;} } }
+
+ /// Internal Acessors for Type
+ string Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResourceInternal.Type { get => this._type; set { {_type = value;} } }
+
+ /// Backing field for property.
+ private string _name;
+
+ /// Resource name
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Owned)]
+ public string Name { get => this._name; }
+
+ /// Backing field for property.
+ private string _type;
+
+ /// Resource type
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Owned)]
+ public string Type { get => this._type; }
+
+ /// Creates an new instance.
+ public Resource()
+ {
+
+ }
+ }
+ /// Describes an Azure resource.
+ public partial interface IResource :
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.IJsonSerializable
+ {
+ /// Resource Id
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = true,
+ Description = @"Resource Id",
+ SerializedName = @"id",
+ PossibleTypes = new [] { typeof(string) })]
+ string Id { get; }
+ /// Resource name
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = true,
+ Description = @"Resource name",
+ SerializedName = @"name",
+ PossibleTypes = new [] { typeof(string) })]
+ string Name { get; }
+ /// Resource type
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = true,
+ Description = @"Resource type",
+ SerializedName = @"type",
+ PossibleTypes = new [] { typeof(string) })]
+ string Type { get; }
+
+ }
+ /// Describes an Azure resource.
+ internal partial interface IResourceInternal
+
+ {
+ /// Resource Id
+ string Id { get; set; }
+ /// Resource name
+ string Name { get; set; }
+ /// Resource type
+ string Type { get; set; }
+
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api10/Resource.json.cs b/swaggerci/security/generated/api/Models/Api10/Resource.json.cs
new file mode 100644
index 000000000000..f0216b5027a8
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api10/Resource.json.cs
@@ -0,0 +1,121 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10
+{
+ using static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Extensions;
+
+ /// Describes an Azure resource.
+ public partial class Resource
+ {
+
+ ///
+ /// AfterFromJson will be called after the json deserialization has finished, allowing customization of the object
+ /// before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The JsonNode that should be deserialized into this object.
+
+ partial void AfterFromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json);
+
+ ///
+ /// AfterToJson will be called after the json serialization has finished, allowing customization of the before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The JSON container that the serialization result will be placed in.
+
+ partial void AfterToJson(ref Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container);
+
+ ///
+ /// BeforeFromJson will be called before the json deserialization has commenced, allowing complete customization of
+ /// the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the
+ /// output parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The JsonNode that should be deserialized into this object.
+ /// Determines if the rest of the deserialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeFromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json, ref bool returnNow);
+
+ ///
+ /// BeforeToJson will be called before the json serialization has commenced, allowing complete customization of the
+ /// object before it is serialized.
+ /// If you wish to disable the default serialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The JSON container that the serialization result will be placed in.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeToJson(ref Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container, ref bool returnNow);
+
+ ///
+ /// Deserializes a into an instance of Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResource.
+ ///
+ /// a to deserialize from.
+ ///
+ /// an instance of Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResource.
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api10.IResource FromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode node)
+ {
+ return node is Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json ? new Resource(json) : null;
+ }
+
+ ///
+ /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject into a new instance of .
+ ///
+ /// A Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject instance to deserialize from.
+ internal Resource(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json)
+ {
+ bool returnNow = false;
+ BeforeFromJson(json, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ {_id = If( json?.PropertyT("id"), out var __jsonId) ? (string)__jsonId : (string)Id;}
+ {_name = If( json?.PropertyT("name"), out var __jsonName) ? (string)__jsonName : (string)Name;}
+ {_type = If( json?.PropertyT("type"), out var __jsonType) ? (string)__jsonType : (string)Type;}
+ AfterFromJson(json);
+ }
+
+ ///
+ /// Serializes this instance of into a .
+ ///
+ /// The container to serialize this object into. If the caller
+ /// passes in null, a new instance will be created and returned to the caller.
+ /// Allows the caller to choose the depth of the serialization. See .
+ ///
+ /// a serialized instance of as a .
+ ///
+ public Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode ToJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode serializationMode)
+ {
+ container = container ?? new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject();
+
+ bool returnNow = false;
+ BeforeToJson(ref container, ref returnNow);
+ if (returnNow)
+ {
+ return container;
+ }
+ if (serializationMode.HasFlag(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode.IncludeReadOnly))
+ {
+ AddIf( null != (((object)this._id)?.ToString()) ? (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode) new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonString(this._id.ToString()) : null, "id" ,container.Add );
+ }
+ if (serializationMode.HasFlag(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode.IncludeReadOnly))
+ {
+ AddIf( null != (((object)this._name)?.ToString()) ? (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode) new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonString(this._name.ToString()) : null, "name" ,container.Add );
+ }
+ if (serializationMode.HasFlag(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode.IncludeReadOnly))
+ {
+ AddIf( null != (((object)this._type)?.ToString()) ? (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode) new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonString(this._type.ToString()) : null, "type" ,container.Add );
+ }
+ AfterToJson(ref container);
+ return container;
+ }
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api20230201Preview/Baseline.PowerShell.cs b/swaggerci/security/generated/api/Models/Api20230201Preview/Baseline.PowerShell.cs
new file mode 100644
index 000000000000..aea1e5601217
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api20230201Preview/Baseline.PowerShell.cs
@@ -0,0 +1,152 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview
+{
+ using Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.PowerShell;
+
+ /// Baseline details.
+ [System.ComponentModel.TypeConverter(typeof(BaselineTypeConverter))]
+ public partial class Baseline
+ {
+
+ ///
+ /// AfterDeserializeDictionary will be called after the deserialization has finished, allowing customization of the
+ /// object before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+
+ partial void AfterDeserializeDictionary(global::System.Collections.IDictionary content);
+
+ ///
+ /// AfterDeserializePSObject will be called after the deserialization has finished, allowing customization of the object
+ /// before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+
+ partial void AfterDeserializePSObject(global::System.Management.Automation.PSObject content);
+
+ ///
+ /// BeforeDeserializeDictionary will be called before the deserialization has commenced, allowing complete customization
+ /// of the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeDeserializeDictionary(global::System.Collections.IDictionary content, ref bool returnNow);
+
+ ///
+ /// BeforeDeserializePSObject will be called before the deserialization has commenced, allowing complete customization
+ /// of the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeDeserializePSObject(global::System.Management.Automation.PSObject content, ref bool returnNow);
+
+ ///
+ /// Deserializes a into a new instance of .
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ internal Baseline(global::System.Collections.IDictionary content)
+ {
+ bool returnNow = false;
+ BeforeDeserializeDictionary(content, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ // actually deserialize
+ if (content.Contains("ExpectedResult"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineInternal)this).ExpectedResult = (string[][]) content.GetValueForProperty("ExpectedResult",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineInternal)this).ExpectedResult, __y => TypeConverterExtensions.SelectToArray(__y, __w => TypeConverterExtensions.SelectToArray(__w, global::System.Convert.ToString)));
+ }
+ if (content.Contains("UpdatedTime"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineInternal)this).UpdatedTime = (global::System.DateTime?) content.GetValueForProperty("UpdatedTime",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineInternal)this).UpdatedTime, (v) => v is global::System.DateTime _v ? _v : global::System.Xml.XmlConvert.ToDateTime( v.ToString() , global::System.Xml.XmlDateTimeSerializationMode.Unspecified));
+ }
+ AfterDeserializeDictionary(content);
+ }
+
+ ///
+ /// Deserializes a into a new instance of .
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ internal Baseline(global::System.Management.Automation.PSObject content)
+ {
+ bool returnNow = false;
+ BeforeDeserializePSObject(content, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ // actually deserialize
+ if (content.Contains("ExpectedResult"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineInternal)this).ExpectedResult = (string[][]) content.GetValueForProperty("ExpectedResult",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineInternal)this).ExpectedResult, __y => TypeConverterExtensions.SelectToArray(__y, __w => TypeConverterExtensions.SelectToArray(__w, global::System.Convert.ToString)));
+ }
+ if (content.Contains("UpdatedTime"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineInternal)this).UpdatedTime = (global::System.DateTime?) content.GetValueForProperty("UpdatedTime",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineInternal)this).UpdatedTime, (v) => v is global::System.DateTime _v ? _v : global::System.Xml.XmlConvert.ToDateTime( v.ToString() , global::System.Xml.XmlDateTimeSerializationMode.Unspecified));
+ }
+ AfterDeserializePSObject(content);
+ }
+
+ ///
+ /// Deserializes a into an instance of .
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ ///
+ /// an instance of .
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaseline DeserializeFromDictionary(global::System.Collections.IDictionary content)
+ {
+ return new Baseline(content);
+ }
+
+ ///
+ /// Deserializes a into an instance of .
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ ///
+ /// an instance of .
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaseline DeserializeFromPSObject(global::System.Management.Automation.PSObject content)
+ {
+ return new Baseline(content);
+ }
+
+ ///
+ /// Creates a new instance of , deserializing the content from a json string.
+ ///
+ /// a string containing a JSON serialized instance of this model.
+ /// an instance of the model class.
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaseline FromJsonString(string jsonText) => FromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode.Parse(jsonText));
+
+ /// Serializes this instance to a json string.
+
+ /// a containing this model serialized to JSON text.
+ public string ToJsonString() => ToJson(null, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode.IncludeAll)?.ToString();
+ }
+ /// Baseline details.
+ [System.ComponentModel.TypeConverter(typeof(BaselineTypeConverter))]
+ public partial interface IBaseline
+
+ {
+
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api20230201Preview/Baseline.TypeConverter.cs b/swaggerci/security/generated/api/Models/Api20230201Preview/Baseline.TypeConverter.cs
new file mode 100644
index 000000000000..2009caf55d22
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api20230201Preview/Baseline.TypeConverter.cs
@@ -0,0 +1,146 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview
+{
+ using Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.PowerShell;
+
+ ///
+ /// A PowerShell PSTypeConverter to support converting to an instance of
+ ///
+ public partial class BaselineTypeConverter : global::System.Management.Automation.PSTypeConverter
+ {
+
+ ///
+ /// Determines if the converter can convert the parameter to the parameter.
+ ///
+ /// the to convert from
+ /// the to convert to
+ ///
+ /// true if the converter can convert the parameter to the parameter, otherwise false.
+ ///
+ public override bool CanConvertFrom(object sourceValue, global::System.Type destinationType) => CanConvertFrom(sourceValue);
+
+ ///
+ /// Determines if the converter can convert the parameter to the type.
+ ///
+ /// the instance to check if it can be converted to the type.
+ ///
+ /// true if the instance could be converted to a type, otherwise false
+ ///
+ public static bool CanConvertFrom(dynamic sourceValue)
+ {
+ if (null == sourceValue)
+ {
+ return true;
+ }
+ global::System.Type type = sourceValue.GetType();
+ if (typeof(global::System.Management.Automation.PSObject).IsAssignableFrom(type))
+ {
+ // we say yest to PSObjects
+ return true;
+ }
+ if (typeof(global::System.Collections.IDictionary).IsAssignableFrom(type))
+ {
+ // we say yest to Hashtables/dictionaries
+ return true;
+ }
+ try
+ {
+ if (null != sourceValue.ToJsonString())
+ {
+ return true;
+ }
+ }
+ catch
+ {
+ // Not one of our objects
+ }
+ try
+ {
+ string text = sourceValue.ToString()?.Trim();
+ return true == text?.StartsWith("{") && true == text?.EndsWith("}") && Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode.Parse(text).Type == Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonType.Object;
+ }
+ catch
+ {
+ // Doesn't look like it can be treated as JSON
+ }
+ return false;
+ }
+
+ ///
+ /// Determines if the parameter can be converted to the
+ /// parameter
+ ///
+ /// the to convert from
+ /// the to convert to
+ ///
+ /// true if the converter can convert the parameter to the parameter, otherwise false
+ ///
+ public override bool CanConvertTo(object sourceValue, global::System.Type destinationType) => false;
+
+ ///
+ /// Converts the parameter to the parameter using and
+ ///
+ /// the to convert from
+ /// the to convert to
+ /// not used by this TypeConverter.
+ /// when set to true, will ignore the case when converting.
+ ///
+ /// an instance of , or null if there is no suitable conversion.
+ ///
+ public override object ConvertFrom(object sourceValue, global::System.Type destinationType, global::System.IFormatProvider formatProvider, bool ignoreCase) => ConvertFrom(sourceValue);
+
+ ///
+ /// Converts the parameter into an instance of
+ ///
+ /// the value to convert into an instance of .
+ ///
+ /// an instance of , or null if there is no suitable conversion.
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaseline ConvertFrom(dynamic sourceValue)
+ {
+ if (null == sourceValue)
+ {
+ return null;
+ }
+ global::System.Type type = sourceValue.GetType();
+ if (typeof(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaseline).IsAssignableFrom(type))
+ {
+ return sourceValue;
+ }
+ try
+ {
+ return Baseline.FromJsonString(typeof(string) == sourceValue.GetType() ? sourceValue : sourceValue.ToJsonString());;
+ }
+ catch
+ {
+ // Unable to use JSON pattern
+ }
+ if (typeof(global::System.Management.Automation.PSObject).IsAssignableFrom(type))
+ {
+ return Baseline.DeserializeFromPSObject(sourceValue);
+ }
+ if (typeof(global::System.Collections.IDictionary).IsAssignableFrom(type))
+ {
+ return Baseline.DeserializeFromDictionary(sourceValue);
+ }
+ return null;
+ }
+
+ /// NotImplemented -- this will return null
+ /// the to convert from
+ /// the to convert to
+ /// not used by this TypeConverter.
+ /// when set to true, will ignore the case when converting.
+ /// will always return null.
+ public override object ConvertTo(object sourceValue, global::System.Type destinationType, global::System.IFormatProvider formatProvider, bool ignoreCase) => null;
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api20230201Preview/Baseline.cs b/swaggerci/security/generated/api/Models/Api20230201Preview/Baseline.cs
new file mode 100644
index 000000000000..dc73ed8612d3
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api20230201Preview/Baseline.cs
@@ -0,0 +1,68 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview
+{
+ using static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Extensions;
+
+ /// Baseline details.
+ public partial class Baseline :
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaseline,
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineInternal
+ {
+
+ /// Backing field for property.
+ private string[][] _expectedResult;
+
+ /// Expected results.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Owned)]
+ public string[][] ExpectedResult { get => this._expectedResult; set => this._expectedResult = value; }
+
+ /// Backing field for property.
+ private global::System.DateTime? _updatedTime;
+
+ /// Baseline update time (UTC).
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Origin(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.PropertyOrigin.Owned)]
+ public global::System.DateTime? UpdatedTime { get => this._updatedTime; set => this._updatedTime = value; }
+
+ /// Creates an new instance.
+ public Baseline()
+ {
+
+ }
+ }
+ /// Baseline details.
+ public partial interface IBaseline :
+ Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.IJsonSerializable
+ {
+ /// Expected results.
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = false,
+ Description = @"Expected results.",
+ SerializedName = @"expectedResults",
+ PossibleTypes = new [] { typeof(string) })]
+ string[][] ExpectedResult { get; set; }
+ /// Baseline update time (UTC).
+ [Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Info(
+ Required = false,
+ ReadOnly = false,
+ Description = @"Baseline update time (UTC).",
+ SerializedName = @"updatedTime",
+ PossibleTypes = new [] { typeof(global::System.DateTime) })]
+ global::System.DateTime? UpdatedTime { get; set; }
+
+ }
+ /// Baseline details.
+ internal partial interface IBaselineInternal
+
+ {
+ /// Expected results.
+ string[][] ExpectedResult { get; set; }
+ /// Baseline update time (UTC).
+ global::System.DateTime? UpdatedTime { get; set; }
+
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api20230201Preview/Baseline.json.cs b/swaggerci/security/generated/api/Models/Api20230201Preview/Baseline.json.cs
new file mode 100644
index 000000000000..466df74fa57b
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api20230201Preview/Baseline.json.cs
@@ -0,0 +1,118 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview
+{
+ using static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Extensions;
+
+ /// Baseline details.
+ public partial class Baseline
+ {
+
+ ///
+ /// AfterFromJson will be called after the json deserialization has finished, allowing customization of the object
+ /// before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The JsonNode that should be deserialized into this object.
+
+ partial void AfterFromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json);
+
+ ///
+ /// AfterToJson will be called after the json serialization has finished, allowing customization of the before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The JSON container that the serialization result will be placed in.
+
+ partial void AfterToJson(ref Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container);
+
+ ///
+ /// BeforeFromJson will be called before the json deserialization has commenced, allowing complete customization of
+ /// the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the
+ /// output parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The JsonNode that should be deserialized into this object.
+ /// Determines if the rest of the deserialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeFromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json, ref bool returnNow);
+
+ ///
+ /// BeforeToJson will be called before the json serialization has commenced, allowing complete customization of the
+ /// object before it is serialized.
+ /// If you wish to disable the default serialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The JSON container that the serialization result will be placed in.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeToJson(ref Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container, ref bool returnNow);
+
+ ///
+ /// Deserializes a Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject into a new instance of .
+ ///
+ /// A Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject instance to deserialize from.
+ internal Baseline(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json)
+ {
+ bool returnNow = false;
+ BeforeFromJson(json, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ {_expectedResult = If( json?.PropertyT("expectedResults"), out var __jsonExpectedResults) ? If( __jsonExpectedResults as Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonArray, out var __u) ? new global::System.Func(()=> global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__u, (__t)=>(string[]) (If( __t as Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonArray, out var __s) ? new global::System.Func(()=> global::System.Linq.Enumerable.ToArray(global::System.Linq.Enumerable.Select(__s, (__r)=>(string) (__r is Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonString __q ? (string)(__q.ToString()) : null)) ))() : null /* arrayOf */)) ))() : null : ExpectedResult;}
+ {_updatedTime = If( json?.PropertyT("updatedTime"), out var __jsonUpdatedTime) ? global::System.DateTime.TryParse((string)__jsonUpdatedTime, global::System.Globalization.CultureInfo.InvariantCulture, global::System.Globalization.DateTimeStyles.AdjustToUniversal, out var __jsonUpdatedTimeValue) ? __jsonUpdatedTimeValue : UpdatedTime : UpdatedTime;}
+ AfterFromJson(json);
+ }
+
+ ///
+ /// Deserializes a into an instance of Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaseline.
+ ///
+ /// a to deserialize from.
+ ///
+ /// an instance of Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaseline.
+ ///
+ public static Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaseline FromJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode node)
+ {
+ return node is Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject json ? new Baseline(json) : null;
+ }
+
+ ///
+ /// Serializes this instance of into a .
+ ///
+ /// The container to serialize this object into. If the caller
+ /// passes in null, a new instance will be created and returned to the caller.
+ /// Allows the caller to choose the depth of the serialization. See .
+ ///
+ /// a serialized instance of as a .
+ ///
+ public Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode ToJson(Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject container, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.SerializationMode serializationMode)
+ {
+ container = container ?? new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonObject();
+
+ bool returnNow = false;
+ BeforeToJson(ref container, ref returnNow);
+ if (returnNow)
+ {
+ return container;
+ }
+ if (null != this._expectedResult)
+ {
+ var __w = new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.XNodeArray();
+ foreach( var __x in this._expectedResult )
+ {
+ AddIf(null != __x ? new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.XNodeArray(global::System.Linq.Enumerable.ToArray(System.Linq.Enumerable.Select(__x, (__v) => null != (((object)__v)?.ToString()) ? (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode) new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonString(__v.ToString()) : null))) : null ,__w.Add);
+ }
+ container.Add("expectedResults",__w);
+ }
+ AddIf( null != this._updatedTime ? (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonNode) new Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.Json.JsonString(this._updatedTime?.ToString(@"yyyy'-'MM'-'dd'T'HH':'mm':'ss.fffffffK",global::System.Globalization.CultureInfo.InvariantCulture)) : null, "updatedTime" ,container.Add );
+ AfterToJson(ref container);
+ return container;
+ }
+ }
+}
\ No newline at end of file
diff --git a/swaggerci/security/generated/api/Models/Api20230201Preview/BaselineAdjustedResult.PowerShell.cs b/swaggerci/security/generated/api/Models/Api20230201Preview/BaselineAdjustedResult.PowerShell.cs
new file mode 100644
index 000000000000..3caaf237435a
--- /dev/null
+++ b/swaggerci/security/generated/api/Models/Api20230201Preview/BaselineAdjustedResult.PowerShell.cs
@@ -0,0 +1,186 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License. See License.txt in the project root for license information.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+// Changes may cause incorrect behavior and will be lost if the code is regenerated.
+
+namespace Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview
+{
+ using Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Runtime.PowerShell;
+
+ /// The rule result adjusted with baseline.
+ [System.ComponentModel.TypeConverter(typeof(BaselineAdjustedResultTypeConverter))]
+ public partial class BaselineAdjustedResult
+ {
+
+ ///
+ /// AfterDeserializeDictionary will be called after the deserialization has finished, allowing customization of the
+ /// object before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+
+ partial void AfterDeserializeDictionary(global::System.Collections.IDictionary content);
+
+ ///
+ /// AfterDeserializePSObject will be called after the deserialization has finished, allowing customization of the object
+ /// before it is returned. Implement this method in a partial class to enable this behavior
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+
+ partial void AfterDeserializePSObject(global::System.Management.Automation.PSObject content);
+
+ ///
+ /// BeforeDeserializeDictionary will be called before the deserialization has commenced, allowing complete customization
+ /// of the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeDeserializeDictionary(global::System.Collections.IDictionary content, ref bool returnNow);
+
+ ///
+ /// BeforeDeserializePSObject will be called before the deserialization has commenced, allowing complete customization
+ /// of the object before it is deserialized.
+ /// If you wish to disable the default deserialization entirely, return true in the output
+ /// parameter.
+ /// Implement this method in a partial class to enable this behavior.
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ /// Determines if the rest of the serialization should be processed, or if the method should return
+ /// instantly.
+
+ partial void BeforeDeserializePSObject(global::System.Management.Automation.PSObject content, ref bool returnNow);
+
+ ///
+ /// Deserializes a into a new instance of .
+ ///
+ /// The global::System.Collections.IDictionary content that should be used.
+ internal BaselineAdjustedResult(global::System.Collections.IDictionary content)
+ {
+ bool returnNow = false;
+ BeforeDeserializeDictionary(content, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ // actually deserialize
+ if (content.Contains("Baseline"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).Baseline = (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaseline) content.GetValueForProperty("Baseline",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).Baseline, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.BaselineTypeConverter.ConvertFrom);
+ }
+ if (content.Contains("Status"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).Status = (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Support.RuleStatus?) content.GetValueForProperty("Status",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).Status, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Support.RuleStatus.CreateFrom);
+ }
+ if (content.Contains("ResultsNotInBaseline"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).ResultsNotInBaseline = (string[][]) content.GetValueForProperty("ResultsNotInBaseline",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).ResultsNotInBaseline, __y => TypeConverterExtensions.SelectToArray(__y, __w => TypeConverterExtensions.SelectToArray(__w, global::System.Convert.ToString)));
+ }
+ if (content.Contains("ResultsOnlyInBaseline"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).ResultsOnlyInBaseline = (string[][]) content.GetValueForProperty("ResultsOnlyInBaseline",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).ResultsOnlyInBaseline, __y => TypeConverterExtensions.SelectToArray(__y, __w => TypeConverterExtensions.SelectToArray(__w, global::System.Convert.ToString)));
+ }
+ if (content.Contains("BaselineExpectedResult"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).BaselineExpectedResult = (string[][]) content.GetValueForProperty("BaselineExpectedResult",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).BaselineExpectedResult, __y => TypeConverterExtensions.SelectToArray(__y, __w => TypeConverterExtensions.SelectToArray(__w, global::System.Convert.ToString)));
+ }
+ if (content.Contains("BaselineUpdatedTime"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).BaselineUpdatedTime = (global::System.DateTime?) content.GetValueForProperty("BaselineUpdatedTime",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).BaselineUpdatedTime, (v) => v is global::System.DateTime _v ? _v : global::System.Xml.XmlConvert.ToDateTime( v.ToString() , global::System.Xml.XmlDateTimeSerializationMode.Unspecified));
+ }
+ AfterDeserializeDictionary(content);
+ }
+
+ ///
+ /// Deserializes a into a new instance of .
+ ///
+ /// The global::System.Management.Automation.PSObject content that should be used.
+ internal BaselineAdjustedResult(global::System.Management.Automation.PSObject content)
+ {
+ bool returnNow = false;
+ BeforeDeserializePSObject(content, ref returnNow);
+ if (returnNow)
+ {
+ return;
+ }
+ // actually deserialize
+ if (content.Contains("Baseline"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).Baseline = (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaseline) content.GetValueForProperty("Baseline",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).Baseline, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.BaselineTypeConverter.ConvertFrom);
+ }
+ if (content.Contains("Status"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).Status = (Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Support.RuleStatus?) content.GetValueForProperty("Status",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).Status, Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Support.RuleStatus.CreateFrom);
+ }
+ if (content.Contains("ResultsNotInBaseline"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).ResultsNotInBaseline = (string[][]) content.GetValueForProperty("ResultsNotInBaseline",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).ResultsNotInBaseline, __y => TypeConverterExtensions.SelectToArray(__y, __w => TypeConverterExtensions.SelectToArray(__w, global::System.Convert.ToString)));
+ }
+ if (content.Contains("ResultsOnlyInBaseline"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).ResultsOnlyInBaseline = (string[][]) content.GetValueForProperty("ResultsOnlyInBaseline",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).ResultsOnlyInBaseline, __y => TypeConverterExtensions.SelectToArray(__y, __w => TypeConverterExtensions.SelectToArray(__w, global::System.Convert.ToString)));
+ }
+ if (content.Contains("BaselineExpectedResult"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).BaselineExpectedResult = (string[][]) content.GetValueForProperty("BaselineExpectedResult",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).BaselineExpectedResult, __y => TypeConverterExtensions.SelectToArray(__y, __w => TypeConverterExtensions.SelectToArray(__w, global::System.Convert.ToString)));
+ }
+ if (content.Contains("BaselineUpdatedTime"))
+ {
+ ((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).BaselineUpdatedTime = (global::System.DateTime?) content.GetValueForProperty("BaselineUpdatedTime",((Microsoft.Azure.PowerShell.Cmdlets.SecurityCenter.Models.Api20230201Preview.IBaselineAdjustedResultInternal)this).BaselineUpdatedTime, (v) => v is global::System.DateTime _v ? _v : global::System.Xml.XmlConvert.ToDateTime( v.ToString() , global::System.Xml.XmlDateTimeSerializationMode.Unspecified));
+ }
+ AfterDeserializePSObject(content);
+ }
+
+ ///