Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unify headers and values in tables containing TLS version. #82

Merged
merged 3 commits into from
Oct 10, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Extras/Advisory.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ If ($Task -eq 'Processing')
#'Score' = $data.extendedproperties.score;
'Problem' = $data.shortDescription.problem;
'Savings Currency' = $SavingsCurrency;
'Annual Savings' = $Savings;
'Annual Savings' = "=$Savings";
'Savings Region' = $data.extendedProperties.location;
'Current SKU' = $data.extendedProperties.currentSku;
'Target SKU' = $data.extendedProperties.targetSku
Expand Down Expand Up @@ -74,4 +74,4 @@ Else
'Target SKU' |
Export-Excel -Path $File -WorksheetName 'Advisory' -AutoSize -MaxAutoSizeRows 100 -TableName 'AzureAdvisory' -MoveToStart -TableStyle $tableStyle -Style $Style -ConditionalText $condtxtadv -KillExcel

}
}
6 changes: 3 additions & 3 deletions Modules/Data/MariaDB.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ If ($Task -eq 'Processing') {
'Public Network Access' = $data.publicNetworkAccess;
'Admin Login' = $data.administratorLogin;
'Infrastructure Encryption' = $data.InfrastructureEncryption;
'Minimal Tls Version' = $data.minimalTlsVersion;
'Minimum TLS Version' = "$($data.minimalTlsVersion -Replace '_', '.' -Replace 'tls', 'TLS')";
'State' = $data.userVisibleState;
'Replica Capacity' = $data.replicaCapacity;
'Replication Role' = $data.replicationRole;
Expand Down Expand Up @@ -111,7 +111,7 @@ Else {
$Exc.Add('Public Network Access')
$Exc.Add('Admin Login')
$Exc.Add('Infrastructure Encryption')
$Exc.Add('Minimal Tls Version')
$Exc.Add('Minimum TLS Version')
$Exc.Add('State')
$Exc.Add('Replica Capacity')
$Exc.Add('Replication Role')
Expand All @@ -131,4 +131,4 @@ Else {

}
<######## Insert Column comments and documentations here following this model #########>
}
}
8 changes: 4 additions & 4 deletions Modules/Data/MySQL.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ If ($Task -eq 'Processing') {
'SKU Family' = $sku.family;
'Tier' = $sku.tier;
'Capacity' = $sku.capacity;
'MySQL Version' = $data.version;
'MySQL Version' = "=$($data.version)";
'Private Endpoint' = $PVTENDP;
'Backup Retention Days' = $data.storageProfile.backupRetentionDays;
'Geo-Redundant Backup' = $data.storageProfile.geoRedundantBackup;
Expand All @@ -58,7 +58,7 @@ If ($Task -eq 'Processing') {
'Public Network Access' = $data.publicNetworkAccess;
'Admin Login' = $data.administratorLogin;
'Infrastructure Encryption' = $data.InfrastructureEncryption;
'Minimal Tls Version' = $data.minimalTlsVersion;
'Minimum TLS Version' = "$($data.minimalTlsVersion -Replace '_', '.' -Replace 'tls', 'TLS ')";
'State' = $data.userVisibleState;
'Replica Capacity' = $data.replicaCapacity;
'Replication Role' = $data.replicationRole;
Expand Down Expand Up @@ -111,7 +111,7 @@ Else {
$Exc.Add('Public Network Access')
$Exc.Add('Admin Login')
$Exc.Add('Infrastructure Encryption')
$Exc.Add('Minimal Tls Version')
$Exc.Add('Minimum TLS Version')
$Exc.Add('State')
$Exc.Add('Replica Capacity')
$Exc.Add('Replication Role')
Expand All @@ -131,4 +131,4 @@ Else {

}
<######## Insert Column comments and documentations here following this model #########>
}
}
8 changes: 4 additions & 4 deletions Modules/Data/POSTGRE.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -58,12 +58,12 @@ If ($Task -eq 'Processing') {
'Public Network Access' = $data.publicNetworkAccess;
'Admin Login' = $data.administratorLogin;
'Infrastructure Encryption' = $data.InfrastructureEncryption;
'Minimal Tls Version' = $data.minimalTlsVersion;
'Minimum TLS Version' = "$($data.minimalTlsVersion -Replace '_', '.' -Replace 'tls', 'TLS')";
'State' = $data.userVisibleState;
'Replica Capacity' = $data.replicaCapacity;
'Replication Role' = $data.replicationRole;
'BYOK Enforcement' = $data.byokEnforcement;
'ssl Enforcement' = $data.sslEnforcement;
'SSL Enforcement' = $data.sslEnforcement;
'Resource U' = $ResUCount;
'Tag Name' = [string]$Tag.Name;
'Tag Value' = [string]$Tag.Value
Expand Down Expand Up @@ -112,7 +112,7 @@ Else {
$Exc.Add('Public Network Access')
$Exc.Add('Admin Login')
$Exc.Add('Infrastructure Encryption')
$Exc.Add('Minimal Tls Version')
$Exc.Add('Minimum TLS Version')
$Exc.Add('State')
$Exc.Add('Replica Capacity')
$Exc.Add('Replication Role')
Expand All @@ -132,4 +132,4 @@ Else {

}
<######## Insert Column comments and documentations here following this model #########>
}
}
8 changes: 4 additions & 4 deletions Modules/Data/RedisCache.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ If ($Task -eq 'Processing') {
$data = $1.PROPERTIES
$PvtEndP = $data.privateEndpointConnections.properties.privateEndpoint.id.split('/')[8]
if ($1.ZONES) { $Zones = $1.ZONES }else { $Zones = 'Not Configured' }
if ([string]::IsNullOrEmpty($data.minimumTlsVersion)){$MinTLS = 'Default'}Else{$MinTLS = $data.minimumTlsVersion}
if ([string]::IsNullOrEmpty($data.minimumTlsVersion)){$MinTLS = 'Default'}Else{$MinTLS = "TLS $($data.minimumTlsVersion)"}
$Tags = if(![string]::IsNullOrEmpty($1.tags.psobject.properties)){$1.tags.psobject.properties}else{'0'}
foreach ($Tag in $Tags) {
$obj = @{
Expand All @@ -56,7 +56,7 @@ If ($Task -eq 'Processing') {
'FQDN' = $data.hostName;
'Port' = $data.port;
'Enable Non SSL Port' = $data.enableNonSslPort;
'Minimum Tls Version' = $MinTLS;
'Minimum TLS Version' = $MinTLS;
'SSL Port' = $data.sslPort;
'Private Endpoint' = $PvtEndP;
'Sku' = $data.sku.name;
Expand Down Expand Up @@ -109,7 +109,7 @@ Else {
$Exc.Add('FQDN')
$Exc.Add('Port')
$Exc.Add('Enable Non SSL Port')
$Exc.Add('Minimum Tls Version')
$Exc.Add('Minimum TLS Version')
$Exc.Add('SSL Port')
$Exc.Add('Private Endpoint')
$Exc.Add('Sku')
Expand All @@ -132,4 +132,4 @@ Else {
Export-Excel -Path $File -WorksheetName 'Redis Cache' -AutoSize -MaxAutoSizeRows 100 -TableName $TableName -TableStyle $tableStyle -ConditionalText $condtxt -Style $Style
}
<######## Insert Column comments and documentations here following this model #########>
}
}
6 changes: 3 additions & 3 deletions Modules/Infrastructure/AppGW.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ If ($Task -eq 'Processing') {
'Location' = $1.LOCATION;
'State' = $data.OperationalState;
'WAF Enabled' = $WAF;
'Minimum SSL Protocol' = $PROT;
'Minimum TLS Version' = "$($PROT -Replace '_', '.' -Replace 'v', ' ' -Replace 'tls', 'TLS')";
'Autoscale Min Capacity'= $MinCap;
'Autoscale Max Capacity'= $MaxCap;
'SKU Name' = $data.sku.tier;
Expand Down Expand Up @@ -88,7 +88,7 @@ Else {
$Exc.Add('Location')
$Exc.Add('State')
$Exc.Add('WAF Enabled')
$Exc.Add('Minimum SSL Protocol')
$Exc.Add('Minimum TLS Version')
$Exc.Add('Autoscale Min Capacity')
$Exc.Add('Autoscale Max Capacity')
$Exc.Add('SKU Name')
Expand All @@ -111,4 +111,4 @@ Else {
ForEach-Object { [PSCustomObject]$_ } | Select-Object -Unique $Exc |
Export-Excel -Path $File -WorksheetName 'App Gateway' -AutoSize -MaxAutoSizeRows 100 -TableName $TableName -TableStyle $tableStyle -ConditionalText $condtxt -Style $Style
}
}
}
6 changes: 3 additions & 3 deletions Modules/Storage/StorageAcc.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ If ($Task -eq 'Processing') {
'Tier' = $1.sku.tier;
'Supports HTTPs Traffic Only' = $data.supportsHttpsTrafficOnly;
'Allow Blob Public Access' = if ($data.allowBlobPublicAccess -eq $false) { $false }else { $true };
'TLS Version' = $TLSv;
'Minimum TLS Version' = $TLSv;
'Identity-based access for file shares' = if ($data.azureFilesIdentityBasedAuthentication.directoryServiceOptions -eq 'None') { $false }elseif ($null -eq $data.azureFilesIdentityBasedAuthentication.directoryServiceOptions) { $false }else { $true };
'Access Tier' = $data.accessTier;
'Primary Location' = $data.primaryLocation;
Expand Down Expand Up @@ -103,7 +103,7 @@ Else {
$Exc.Add('Tier')
$Exc.Add('Supports HTTPS Traffic Only')
$Exc.Add('Allow Blob Public Access')
$Exc.Add('TLS Version')
$Exc.Add('Minumum TLS Version')
$Exc.Add('Identity-based access for file shares')
$Exc.Add('Access Tier')
$Exc.Add('Primary Location')
Expand Down Expand Up @@ -142,4 +142,4 @@ Else {
Close-ExcelPackage $excel

}
}
}