Skip to content

Commit

Permalink
sync with remote branch
Browse files Browse the repository at this point in the history
  • Loading branch information
Mansi Verma committed Jul 18, 2024
2 parents f0b6a48 + 3b6e3c7 commit af4cf68
Show file tree
Hide file tree
Showing 953 changed files with 222,852 additions and 73,919 deletions.
4 changes: 2 additions & 2 deletions .azure-pipelines/security-tools.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,8 @@ jobs:
New-Item $(Build.SourcesDirectory)/artifacts/FilesToScan.rsp -ItemType File -Force
(Get-ChildItem -Path .\artifacts\Debug -Include *.dll,*.exe -Exclude msalruntime.dll,msalruntime_arm64.dll,msalruntime_x86.dll -Recurse).FullName > $(Build.SourcesDirectory)/artifacts/FilesToScan.rsp
pwsh: true
- task: securedevelopmentteam.vss-secure-development-tools.build-task-binskim.BinSkim@3

- task: securedevelopmentteam.vss-secure-development-tools.build-task-binskim.BinSkim@4
displayName: Run BinSkim
inputs:
InputType: 'CommandLine'
Expand Down
12 changes: 5 additions & 7 deletions src/Accounts/Accounts/Az.Accounts.psd1
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#
# Generated by: Microsoft Corporation
#
# Generated on: 7/4/2024
# Generated on: 7/12/2024
#

@{
Expand All @@ -12,7 +12,7 @@
# RootModule = ''

# Version number of this module.
ModuleVersion = '3.0.1'
ModuleVersion = '3.0.2'

# Supported PSEditions
CompatiblePSEditions = 'Core', 'Desktop'
Expand Down Expand Up @@ -147,11 +147,9 @@ PrivateData = @{
# IconUri = ''

# ReleaseNotes of this module
ReleaseNotes = '* Disable WAM when the customers login with device code flow or username password (ROPC) flow to prevent a potential issue with token cache.
* Fixed [CVE-2024-35255](https://github.com/advisories/GHSA-m5vv-6r4h-3vj9)
* Updated ''Microsoft.Identity.Client.NativeInterop'' to fix the WAM pop window issue in elevated mode [#24967]
* Updated the reference of Azure PowerShell Common to 1.3.98-preview.
* Limited promotional message to interactive scenarios only'
ReleaseNotes = '* Fixed bug handling GUID type subscription Id.
* Added a warning message in ''Connect-AzAccount'' to discourage the use of the username/password (a.k.a ROPC) login flow.
* Preannounced a breaking change in ''Get-AzAccessToken'' to change ''Token'' property from ''String'' to ''SecureString''.'

# Prerelease string of this module
# Prerelease = ''
Expand Down
3 changes: 3 additions & 0 deletions src/Accounts/Accounts/ChangeLog.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@
-->

## Upcoming Release

## Version 3.0.2
* Fixed bug handling GUID type subscription Id.
* Added a warning message in `Connect-AzAccount` to discourage the use of the username/password (a.k.a ROPC) login flow.
* Preannounced a breaking change in `Get-AzAccessToken` to change `Token` property from `String` to `SecureString`.

Expand Down
4 changes: 2 additions & 2 deletions src/Accounts/Accounts/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:

[assembly: AssemblyVersion("3.0.1")]
[assembly: AssemblyFileVersion("3.0.1")]
[assembly: AssemblyVersion("3.0.2")]
[assembly: AssemblyFileVersion("3.0.2")]
#if !SIGN
[assembly: InternalsVisibleTo("Microsoft.Azure.PowerShell.Cmdlets.Accounts.Test")]
#endif
Expand Down
2 changes: 1 addition & 1 deletion src/Accounts/Accounts/help/Connect-AzAccount.md
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ This example connects to an Azure account using certificate-based service princi
The certificate file, which is specified by `CertficatePath`, should contains both certificate and private key as the input.

```powershell
$SecurePassword = ConvertTo-SecureString -String "Password123!" -AsPlainText -Force
$SecurePassword = ConvertTo-SecureString -String "******" -AsPlainText -Force
$TenantId = 'yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyy'
$ApplicationId = 'zzzzzzzz-zzzz-zzzz-zzzz-zzzzzzzz'
Connect-AzAccount -ServicePrincipal -ApplicationId $ApplicationId -TenantId $TenantId -CertificatePath './certificatefortest.pfx' -CertificatePassword $securePassword
Expand Down
4 changes: 2 additions & 2 deletions src/Accounts/AssemblyLoading/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -42,5 +42,5 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("3.0.1")]
[assembly: AssemblyFileVersion("3.0.1")]
[assembly: AssemblyVersion("3.0.2")]
[assembly: AssemblyFileVersion("3.0.2")]
9 changes: 8 additions & 1 deletion src/Accounts/Authentication/Factories/ClientFactory.cs
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,14 @@ public virtual TClient CreateArmClient<TClient>(IAzureContext context, string en
var subscriptionId = typeof(TClient).GetProperty("SubscriptionId");
if (subscriptionId != null && context.Subscription != null)
{
subscriptionId.SetValue(client, context.Subscription.Id.ToString());
if (subscriptionId.PropertyType == typeof(Guid))
{
subscriptionId.SetValue(client, Guid.Parse(context.Subscription.Id));
}
else
{
subscriptionId.SetValue(client, context.Subscription.Id);
}
}

return client;
Expand Down
4 changes: 2 additions & 2 deletions src/Accounts/Authentication/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("3.0.1")]
[assembly: AssemblyFileVersion("3.0.1")]
[assembly: AssemblyVersion("3.0.2")]
[assembly: AssemblyFileVersion("3.0.2")]
#if !SIGN
[assembly: InternalsVisibleTo("Microsoft.Azure.PowerShell.Authentication.Test")]
#endif
Original file line number Diff line number Diff line change
Expand Up @@ -42,5 +42,5 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("3.0.1")]
[assembly: AssemblyFileVersion("3.0.1")]
[assembly: AssemblyVersion("3.0.2")]
[assembly: AssemblyFileVersion("3.0.2")]
4 changes: 2 additions & 2 deletions src/Accounts/Authenticators/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -48,5 +48,5 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("3.0.1")]
[assembly: AssemblyFileVersion("3.0.1")]
[assembly: AssemblyVersion("3.0.2")]
[assembly: AssemblyFileVersion("3.0.2")]
46 changes: 23 additions & 23 deletions src/Aks/Aks.Test/LiveTests/TestLiveScenarios.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Invoke-LiveTestScenario -Name "Test_AKS_CURD" -Description "Test AKS Cluster CRU
Assert-NotNull $cluster.NodeResourceGroup
Assert-AreEqual "Succeeded" $cluster.ProvisioningState
Assert-AreEqual 100 $cluster.MaxAgentPools
Assert-AreEqual $cluster.CurrentKubernetesVersion $cluster.KubernetesVersion
#Assert-AreEqual $cluster.CurrentKubernetesVersion $cluster.KubernetesVersion
Assert-AreEqual "default" $cluster.AgentPoolProfiles.Name
Assert-AreEqual 1 $cluster.AgentPoolProfiles.Length
Assert-AreEqual 3 $cluster.AgentPoolProfiles[0].Count
Expand Down Expand Up @@ -83,7 +83,7 @@ Invoke-LiveTestScenario -Name "Test_AKS_CURD" -Description "Test AKS Cluster CRU
Assert-Null $pools.GpuInstanceProfile
Assert-Null $pools.CreationData
Assert-Null $pools.HostGroupID
Assert-False {$pools.EnableFIPS}
Assert-False { $pools.EnableFIPS }

# step 2: update the aks cluster
Write-Host "##[section]Start to update Aks cluster : Set-AzAksCluster"
Expand All @@ -107,14 +107,14 @@ Invoke-LiveTestScenario -Name "Test_AKS_CURD" -Description "Test AKS Cluster CRU
Write-Host "##[section]Finished retrieving Aks node pool : Get-AzAksNodePool"

Assert-AreEqual 2 $pools.Count
Assert-AreEqualArray "Linux" ($pools | where {$_.Name -eq $pool1Name}).OsType
Assert-AreEqualArray "Ubuntu" ($pools | where {$_.Name -eq $pool1Name}).OsSKU
Assert-AreEqualArray "Windows" ($pools | where {$_.Name -eq $pool2Name}).OsType
Assert-AreEqualArray "Windows2022" ($pools | where {$_.Name -eq $pool2Name}).OsSKU
Assert-AreEqualArray "Linux" ($pools | where { $_.Name -eq $pool1Name }).OsType
Assert-AreEqualArray "Ubuntu" ($pools | where { $_.Name -eq $pool1Name }).OsSKU
Assert-AreEqualArray "Windows" ($pools | where { $_.Name -eq $pool2Name }).OsType
Assert-AreEqualArray "Windows2022" ($pools | where { $_.Name -eq $pool2Name }).OsSKU

# step4: update the second node pool
$labels = @{"someId" = 127; "tier" = "frontend"; "environment" = "qa" }
$tags = @{"dept"="MM"; "costcenter"=7777; "Admin"="Cindy"}
$tags = @{"dept" = "MM"; "costcenter" = 7777; "Admin" = "Cindy" }

Write-Host "##[section]Start to update Aks node pool : Update-AzAksNodePool"
Update-AzAksNodePool -ResourceGroupName $resourceGroupName -ClusterName $kubeClusterName -Name $pool2Name -NodeLabel $labels -Tag $tags
Expand All @@ -125,28 +125,28 @@ Invoke-LiveTestScenario -Name "Test_AKS_CURD" -Description "Test AKS Cluster CRU
Write-Host "##[section]Finished retrieving Aks cluster : Get-AzAksCluster"

Assert-AreEqual 2 $cluster.AgentPoolProfiles.Count
Assert-AreEqual 0 ($cluster.AgentPoolProfiles | where {$_.Name -eq $pool1Name}).NodeLabels.Count
Assert-AreEqual 0 ($cluster.AgentPoolProfiles | where {$_.Name -eq $pool1Name}).Tags.Count
Assert-AreEqual 127 ($cluster.AgentPoolProfiles | where {$_.Name -eq $pool2Name}).NodeLabels.someId
Assert-AreEqual frontend ($cluster.AgentPoolProfiles | where {$_.Name -eq $pool2Name}).NodeLabels.tier
Assert-AreEqual qa ($cluster.AgentPoolProfiles | where {$_.Name -eq $pool2Name}).NodeLabels.environment
Assert-AreEqual MM ($cluster.AgentPoolProfiles | where {$_.Name -eq $pool2Name}).Tags.dept
Assert-AreEqual 7777 ($cluster.AgentPoolProfiles | where {$_.Name -eq $pool2Name}).Tags.costcenter
Assert-AreEqual Cindy ($cluster.AgentPoolProfiles | where {$_.Name -eq $pool2Name}).Tags.Admin
Assert-AreEqual 0 ($cluster.AgentPoolProfiles | where { $_.Name -eq $pool1Name }).NodeLabels.Count
Assert-AreEqual 0 ($cluster.AgentPoolProfiles | where { $_.Name -eq $pool1Name }).Tags.Count
Assert-AreEqual 127 ($cluster.AgentPoolProfiles | where { $_.Name -eq $pool2Name }).NodeLabels.someId
Assert-AreEqual frontend ($cluster.AgentPoolProfiles | where { $_.Name -eq $pool2Name }).NodeLabels.tier
Assert-AreEqual qa ($cluster.AgentPoolProfiles | where { $_.Name -eq $pool2Name }).NodeLabels.environment
Assert-AreEqual MM ($cluster.AgentPoolProfiles | where { $_.Name -eq $pool2Name }).Tags.dept
Assert-AreEqual 7777 ($cluster.AgentPoolProfiles | where { $_.Name -eq $pool2Name }).Tags.costcenter
Assert-AreEqual Cindy ($cluster.AgentPoolProfiles | where { $_.Name -eq $pool2Name }).Tags.Admin

Write-Host "##[section]Start to retrieve Aks node pool : Get-AzAksNodePool"
$pools = Get-AzAksNodePool -ResourceGroupName $resourceGroupName -ClusterName $kubeClusterName
Write-Host "##[section]Finished retrieving Aks node pool : Get-AzAksNodePool"

Assert-AreEqual 2 $pools.Count
Assert-AreEqual 0 ($pools | where {$_.Name -eq $pool1Name}).NodeLabels.Count
Assert-AreEqual 0 ($pools | where {$_.Name -eq $pool1Name}).Tags.Count
Assert-AreEqual 127 ($pools | where {$_.Name -eq $pool2Name}).NodeLabels.someId
Assert-AreEqual frontend ($pools | where {$_.Name -eq $pool2Name}).NodeLabels.tier
Assert-AreEqual qa ($pools | where {$_.Name -eq $pool2Name}).NodeLabels.environment
Assert-AreEqual MM ($pools | where {$_.Name -eq $pool2Name}).Tags.dept
Assert-AreEqual 7777 ($pools | where {$_.Name -eq $pool2Name}).Tags.costcenter
Assert-AreEqual Cindy ($pools | where {$_.Name -eq $pool2Name}).Tags.Admin
Assert-AreEqual 0 ($pools | where { $_.Name -eq $pool1Name }).NodeLabels.Count
Assert-AreEqual 0 ($pools | where { $_.Name -eq $pool1Name }).Tags.Count
Assert-AreEqual 127 ($pools | where { $_.Name -eq $pool2Name }).NodeLabels.someId
Assert-AreEqual frontend ($pools | where { $_.Name -eq $pool2Name }).NodeLabels.tier
Assert-AreEqual qa ($pools | where { $_.Name -eq $pool2Name }).NodeLabels.environment
Assert-AreEqual MM ($pools | where { $_.Name -eq $pool2Name }).Tags.dept
Assert-AreEqual 7777 ($pools | where { $_.Name -eq $pool2Name }).Tags.costcenter
Assert-AreEqual Cindy ($pools | where { $_.Name -eq $pool2Name }).Tags.Admin

Write-Host "##[section]Start to remove Aks cluster : Remove-AzAksCluster"
$cluster | Remove-AzAksCluster -Force
Expand Down
1 change: 1 addition & 0 deletions src/Compute/Compute/ChangeLog.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
-->
## Upcoming Release
* Renamed parameter `-VmId` to `-SourceId` and added `-VmId` as an alias to `New-AzRestorePointCollection` cmdlet.

## Version 8.1.0
* Added parameter `-SourceResourceId` to cmdlet `Add-AzVMDataDisk`.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ public class NewAzureRestorePointCollection : ComputeAutomationBaseCmdlet
Mandatory = false,
ValueFromPipeline = true,
ParameterSetName = "RestorePointCollectionId")]
public string VmId { get; set; }
[Alias("VmId")]
public string SourceId { get; set; }

[Parameter(
Position = 3,
Expand Down Expand Up @@ -99,7 +100,7 @@ public override void ExecuteCmdlet()
{
string resourceGroup = this.ResourceGroupName;
string restorePointCollectionName = this.Name;
string vmId = this.VmId;
string vmId = this.SourceId;
RestorePointCollection restorePointCollection;
if (this.IsParameterBound(c => c.Location))
{
Expand Down
2 changes: 1 addition & 1 deletion src/Compute/Compute/help/Get-AzRemoteDesktopFile.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ Accept wildcard characters: False
```
### -Name
Specifies the name of the availability set that this cmdlet gets.
Specifies the name of the virtual machine to gets.
```yaml
Type: System.String
Expand Down
14 changes: 7 additions & 7 deletions src/Compute/Compute/help/New-AzRestorePointCollection.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,16 @@ Creates a New Restore Point Collection

### DefaultParameter (Default)
```
New-AzRestorePointCollection [-ResourceGroupName] <String> [-Name] <String> [-VmId] <String>
New-AzRestorePointCollection [-ResourceGroupName] <String> [-Name] <String> [-SourceId] <String>
[-Location <String>] [-DefaultProfile <IAzureContextContainer>] [-WhatIf]
[-Confirm] [<CommonParameters>]
```

### RestorePointCollectionId
```
New-AzRestorePointCollection [-ResourceGroupName] <String> [-Name] <String> [[-VmId] <String>]
New-AzRestorePointCollection [-ResourceGroupName] <String> [-Name] <String> [[-SourceId] <String>]
[-RestorePointCollectionId] <String> -Location <String> [-DefaultProfile <IAzureContextContainer>]
[-WhatIf] [-Confirm] [<CommonParameters>]
[-WhatIf] [-Confirm] [<CommonParameters>]
```

## DESCRIPTION
Expand Down Expand Up @@ -127,13 +127,13 @@ Accept pipeline input: True (ByValue)
Accept wildcard characters: False
```
### -VmId
resource Id of the source resource used to create this restore point Collection
### -SourceId
Resource ID of the source resource used to create this restore point collection.
```yaml
Type: System.String
Parameter Sets: DefaultParameter
Aliases:
Aliases: VmId

Required: True
Position: 2
Expand All @@ -145,7 +145,7 @@ Accept wildcard characters: False
```yaml
Type: System.String
Parameter Sets: RestorePointCollectionId
Aliases:
Aliases: VmId

Required: False
Position: 2
Expand Down
10 changes: 10 additions & 0 deletions src/Informatica/Informatica.Autorest/Az.Informatica.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<PsModuleName>Informatica</PsModuleName>
<PsRootModuleName>Informatica</PsRootModuleName>
<PsModuleFolder>Informatica.Autorest</PsModuleFolder>
</PropertyGroup>

<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory).., build.proj))\src\Az.autorest.props" />
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory).., build.proj))\src\Az.Post.props" />
</Project>
Loading

0 comments on commit af4cf68

Please sign in to comment.