Skip to content

Commit d38f327

Browse files
author
Maddie Clayton
committed
Merge branch 'preview' of https://github.com/Azure/azure-powershell into exceptions-refactor
2 parents 0b6950f + e9dbc00 commit d38f327

File tree

21 files changed

+5955
-361
lines changed

21 files changed

+5955
-361
lines changed

ChangeLog.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,12 @@
1-
## 6.1.0 - May 2018
1+
## 6.1.1 - May 2018
2+
#### AzureRM.Resources
3+
* Revert change to `New-AzureRmADServicePrincipal` that gave service principals `Contributor` permissions over the current subscription if no values were provided for the `Role` or `Scope` parameters
4+
- If no values are provided for `Role` or `Scope`, the service principal is created with no permissions
5+
- If a `Role` is provided, but no `Scope`, the service principal is created with the specified `Role` permissions over the current subscription
6+
- If a `Scope` is provided, but no `Role`, the service principal is created with `Contributor` permissions over the specified `Scope`
7+
- If both `Role` and `Scope` are provided, the service principal is created with the specified `Role` permissions over the specified `Scope`
8+
9+
## 6.1.0 - May 2018
210
#### AzureRM.Profile
311
* Fix issue where running 'Clear-AzureRmContext' would keep an empty context with the name of the previous default context, which prevented the user from creating a new context with the old name
412

src/Common/Commands.Common/AzurePowerShell.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@ public class AzurePowerShell
2626

2727
public const string AssemblyCopyright = "Copyright © Microsoft";
2828

29-
public const string AssemblyVersion = "6.0.0";
29+
public const string AssemblyVersion = "6.1.1";
3030

31-
public const string AssemblyFileVersion = "6.0.0";
31+
public const string AssemblyFileVersion = "6.1.1";
3232

3333
public const string ProfileFile = "AzureProfile.json";
3434

src/ResourceManager/Profile/AzureRM.Profile.psd1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ RequiredAssemblies = '.\Microsoft.Azure.Commands.Common.Authentication.Abstracti
8080
'.\Microsoft.Threading.Tasks.Extensions.dll',
8181
'.\Microsoft.Threading.Tasks.Extensions.Desktop.dll',
8282
'.\Microsoft.WindowsAzure.Management.dll', '.\Newtonsoft.Json.dll',
83-
'.\NewAssemblies\Newtonsoft.Json.dll',
83+
'.\Newtonsoft.Json.10.dll',
8484
'.\System.Net.Http.Extensions.dll',
8585
'.\System.Net.Http.Primitives.dll'
8686

src/ResourceManager/Profile/ChangeLog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
- Additional information about change #1
1919
-->
2020
## Current Release
21+
* Fix issue where version 10.0.3 of Newtonsoft.Json wasn't being loaded on module import
2122

2223
## Version 5.1.0
2324
* Fix issue where running `Clear-AzureRmContext` would keep an empty context with the name of the previous default context, which prevented the user from creating a new context with the old name

src/ResourceManager/Profile/Commands.Profile/Commands.Profile.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,6 @@
205205
</ItemGroup>
206206
<Copy SourceFiles="@(OutFiles)" DestinationFiles="@(OutFiles->'..\..\..\Stack\$(Configuration)\ResourceManager\AzureResourceManager\AzureRM.Profile\%(RecursiveDir)%(Filename)%(Extension)')" />
207207
<Copy SourceFiles="@(MarkdownFiles)" DestinationFolder="$(OutputPath)\help\" ContinueOnError="false" />
208-
<Copy SourceFiles="@(NewtonsoftJson)" DestinationFolder="$(OutputPath)\NewAssemblies\" ContinueOnError="false" />
208+
<Copy SourceFiles="@(NewtonsoftJson)" DestinationFiles="$(OutputPath)\Newtonsoft.Json.10.dll" />
209209
</Target>
210210
</Project>

src/ResourceManager/Resources/AzureRM.Resources.psd1

Lines changed: 6 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
# RootModule = ''
1313

1414
# Version number of this module.
15-
ModuleVersion = '6.0.0'
15+
ModuleVersion = '6.0.1'
1616

1717
# Supported PSEditions
1818
# CompatiblePSEditions = @()
@@ -164,21 +164,11 @@ PrivateData = @{
164164
# IconUri = ''
165165

166166
# ReleaseNotes of this module
167-
ReleaseNotes = '* Set minimum dependency of module to PowerShell 5.0
168-
* Remove obsolete parameter -AtScopeAndBelow from Get-AzureRmRoledefinition call
169-
* Include assignments to deleted Users/Groups/ServicePrincipals in Get-AzureRmRoleAssignment result
170-
* Add convenience cmdlet for creating ServicePrincipals
171-
* Add Tab completers for Scope and ResourceType
172-
* Merge Get- and Find- functionality in Get-AzureRmResource
173-
* Add AD Cmdlets:
174-
- Remove-AzureRmADGroupMember
175-
- Get-AzureRmADGroup
176-
- New-AzureRmADGroup
177-
- Remove-AzureRmADGroup
178-
- Remove-AzureRmADUser
179-
- Update-AzureRmADApplication
180-
- Update-AzureRmADServicePrincipal
181-
- Update-AzureRmADUser'
167+
ReleaseNotes = '* Revert change to `New-AzureRmADServicePrincipal` that gave service principals `Contributor` permissions over the current subscription if no values were provided for the `Role` or `Scope` parameters
168+
- If no values are provided for `Role` or `Scope`, the service principal is created with no permissions
169+
- If a `Role` is provided, but no `Scope`, the service principal is created with the specified `Role` permissions over the current subscription
170+
- If a `Scope` is provided, but no `Role`, the service principal is created with `Contributor` permissions over the specified `Scope`
171+
- If both `Role` and `Scope` are provided, the service principal is created with the specified `Role` permissions over the specified `Scope`'
182172

183173
# Prerelease string of this module
184174
# Prerelease = ''

src/ResourceManager/Resources/ChangeLog.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,13 @@
2020
## Current Release
2121
* Fix issue with `Properties` property of `PSResource` object(s) returned from `Get-AzureRmResource`
2222

23+
## Version 6.0.1
24+
* Revert change to `New-AzureRmADServicePrincipal` that gave service principals `Contributor` permissions over the current subscription if no values were provided for the `Role` or `Scope` parameters
25+
- If no values are provided for `Role` or `Scope`, the service principal is created with no permissions
26+
- If a `Role` is provided, but no `Scope`, the service principal is created with the specified `Role` permissions over the current subscription
27+
- If a `Scope` is provided, but no `Role`, the service principal is created with `Contributor` permissions over the specified `Scope`
28+
- If both `Role` and `Scope` are provided, the service principal is created with the specified `Role` permissions over the specified `Scope`
29+
2330
## Version 6.0.0
2431
* Set minimum dependency of module to PowerShell 5.0
2532
* Remove obsolete parameter -AtScopeAndBelow from Get-AzureRmRoledefinition call

src/ResourceManager/Resources/Commands.ResourceManager/Cmdlets/Properties/AssemblyInfo.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@
2525
[assembly: ComVisible(false)]
2626
[assembly: CLSCompliant(false)]
2727
[assembly: Guid("e8f34267-c461-4eae-b156-5f3528553d10")]
28-
[assembly: AssemblyVersion("6.0.0")]
29-
[assembly: AssemblyFileVersion("6.0.0")]
28+
[assembly: AssemblyVersion("6.0.1")]
29+
[assembly: AssemblyFileVersion("6.0.1")]
3030
#if SIGN
3131
[assembly: InternalsVisibleTo("Microsoft.Azure.Commands.Resources.Test, PublicKey=0024000004800000940000000602000000240000525341310004000001000100b5fc90e7027f67871e773a8fde8938c81dd402ba65b9201d60593e96c492651e889cc13f1415ebb53fac1131ae0bd333c5ee6021672d9718ea31a8aebd0da0072f25d87dba6fc90ffd598ed4da35e44c398c454307e8e33b8426143daec9f596836f97c8f74750e5975c64e2189f45def46b2a2b1247adc3652bf5c308055da9")]
3232
[assembly: InternalsVisibleTo("Microsoft.Azure.Commands.MachineLearning.Test, PublicKey=0024000004800000940000000602000000240000525341310004000001000100b5fc90e7027f67871e773a8fde8938c81dd402ba65b9201d60593e96c492651e889cc13f1415ebb53fac1131ae0bd333c5ee6021672d9718ea31a8aebd0da0072f25d87dba6fc90ffd598ed4da35e44c398c454307e8e33b8426143daec9f596836f97c8f74750e5975c64e2189f45def46b2a2b1247adc3652bf5c308055da9")]

src/ResourceManager/Resources/Commands.Resources.Test/Commands.Resources.Test.csproj

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -363,9 +363,15 @@
363363
<None Include="SessionRecords\Microsoft.Azure.Commands.Resources.Test.ScenarioTests.ActiveDirectoryTests\TestGetADUserWithMail.json">
364364
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
365365
</None>
366+
<None Include="SessionRecords\Microsoft.Azure.Commands.Resources.Test.ScenarioTests.ActiveDirectoryTests\TestNewADServicePrincipalWithCustomScope.json">
367+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
368+
</None>
366369
<None Include="SessionRecords\Microsoft.Azure.Commands.Resources.Test.ScenarioTests.ActiveDirectoryTests\TestNewADServicePrincipalWithoutApp.json">
367370
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
368371
</None>
372+
<None Include="SessionRecords\Microsoft.Azure.Commands.Resources.Test.ScenarioTests.ActiveDirectoryTests\TestNewADServicePrincipalWithReaderRole.json">
373+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
374+
</None>
369375
<None Include="SessionRecords\Microsoft.Azure.Commands.Resources.Test.ScenarioTests.DeploymentTests\TestCrossResourceGroupDeploymentFromTemplateFile.json">
370376
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
371377
</None>

src/ResourceManager/Resources/Commands.Resources.Test/ScenarioTests/ActiveDirectoryTests.cs

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -599,13 +599,27 @@ public void TestNewADApplication()
599599
ResourcesController.NewInstance.RunPsTest("Test-NewADApplication");
600600
}
601601

602-
[Fact(Skip = "Need AD team to re-record test")]
602+
[Fact]
603603
[Trait(Category.AcceptanceType, Category.CheckIn)]
604604
public void TestNewADServicePrincipalWithoutApp()
605605
{
606606
ResourcesController.NewInstance.RunPsTest("Test-NewADServicePrincipalWithoutApp");
607607
}
608608

609+
[Fact]
610+
[Trait(Category.AcceptanceType, Category.CheckIn)]
611+
public void TestNewADServicePrincipalWithReaderRole()
612+
{
613+
ResourcesController.NewInstance.RunPsTest("Test-NewADServicePrincipalWithReaderRole");
614+
}
615+
616+
[Fact]
617+
[Trait(Category.AcceptanceType, Category.CheckIn)]
618+
public void TestNewADServicePrincipalWithCustomScope()
619+
{
620+
ResourcesController.NewInstance.RunPsTest("Test-NewADServicePrincipalWithCustomScope");
621+
}
622+
609623
[Fact(Skip = "Not working in playback.")]
610624
[Trait(Category.AcceptanceType, Category.CheckIn)]
611625
public void TestCreateDeleteAppPasswordCredentials()

0 commit comments

Comments
 (0)