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

Enable MHSM Management via *-AzKeyVault #12575

Merged
merged 19 commits into from
Aug 7, 2020

Conversation

BethanyZhou
Copy link
Contributor

@BethanyZhou BethanyZhou commented Aug 5, 2020

Description

Design: https://github.com/Azure/azure-powershell-cmdlet-review-pr/issues/688

TODO: after spec PR Azure/azure-rest-api-specs#8996 is merged. Generate and publish new .NET SDK.

Checklist

  • I have read the Submitting Changes section of CONTRIBUTING.md
  • The title of the PR is clear and informative
  • The appropriate ChangeLog.md file(s) has been updated:
    • For any service, the ChangeLog.md file can be found at src/{{SERVICE}}/{{SERVICE}}/ChangeLog.md
    • A snippet outlining the change(s) made in the PR should be written under the ## Upcoming Release header -- no new version header should be added
  • The PR does not introduce breaking changes
  • If applicable, the changes made in the PR have proper test coverage
  • For public API changes to cmdlets:
    • a cmdlet design review was approved for the changes in this repository (Microsoft internal only)
    • the markdown help files have been regenerated using the commands listed here

@adxsdkps
Copy link
Collaborator

adxsdkps commented Aug 5, 2020

Can one of the admins verify this patch?

Copy link
Member

@isra-fel isra-fel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Except for the inline comments, please also write examples for Get-, New- and Set-.

Thanks

src/KeyVault/KeyVault/Commands/GetAzureKeyVault.cs Outdated Show resolved Hide resolved
src/KeyVault/KeyVault/Commands/GetAzureKeyVault.cs Outdated Show resolved Hide resolved
src/KeyVault/KeyVault/Models/PSKeyVault.cs Outdated Show resolved Hide resolved
src/KeyVault/KeyVault/Commands/NewAzureKeyVault.cs Outdated Show resolved Hide resolved
src/KeyVault/KeyVault/Commands/NewAzureKeyVault.cs Outdated Show resolved Hide resolved
src/KeyVault/KeyVault/Commands/NewAzureKeyVault.cs Outdated Show resolved Hide resolved
src/KeyVault/KeyVault/Commands/RemoveAzureKeyVault.cs Outdated Show resolved Hide resolved
src/KeyVault/KeyVault/Commands/UpdateAzureKeyVault.cs Outdated Show resolved Hide resolved
src/KeyVault/KeyVault/Commands/UpdateAzureKeyVault.cs Outdated Show resolved Hide resolved
src/KeyVault/KeyVault/help/Update-AzKeyVault.md Outdated Show resolved Hide resolved
@BethanyZhou BethanyZhou changed the base branch from master to enableMHSMManagement August 6, 2020 05:45
Copy link
Member

@isra-fel isra-fel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@BethanyZhou I'll just merge this PR. When recording the tests please also regenerate the help files. Thanks

@@ -211,6 +258,21 @@ Accept pipeline input: False
Accept wildcard characters: False
```

### -Hsm
Specifies the type of this vault as MHSM.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The help files needs to be regenerated

@isra-fel isra-fel marked this pull request as ready for review August 7, 2020 03:14
@isra-fel isra-fel merged commit 08b2c9c into Azure:enableMHSMManagement Aug 7, 2020
@isra-fel isra-fel mentioned this pull request Oct 20, 2020
10 tasks
erich-wang pushed a commit that referenced this pull request Oct 20, 2020
* Enable MHSM Management via *-AzKeyVault (#12575)

* Support creating a MHSM pool.

* Supporting querying MHSM objects

* Support deleting MHSM

* Support updating mhsm

* Add test cases

* Hide unavailable services

* Add test cases

* expose EnablePurgeProtection for MHSM

* correct indent of ps1xml

* upload localfeed

* Hide enablePurgeProtection

* Update ChangeLog.md and help.md

* Modify codes according to comments

* Update help.md

* Update VaultCreationParameters.cs

* Update get-azkeyvault.md

* Update KeyVaultManagementTests.ps1

* Record scenario test for Managed Hsm (#12631)

* Record scenario tests for managed hsm

* add default parameter set for

* Re-record scenario tests.

* [KeyVault] Update to official SDK (#12767)

* local 3.1.0 sdk

* Use production key vault mgmt sdk

* remove security domain from format xml

* combine track 1&2 sdk (#13018)

* combine track 1&2 sdk

* update azure.core to 1.5.0

* add exception; revert addkeyvaultkey

* add dll to psd1

* fix exception

* Detach managed hsm from key vault command (#13187)

* get managed hsm

* new managed hsm

* remove managed hsm

* update help.md

* update managed hsm

* add online version for new help.md

* Convert mhsm test to liveonly

* add test record

* Support data plane of managed HSM (#13216)

* create managed hsm key

* get managed hsm key

* remove managed hsm key

* update managed hsm key

* undo managed hsm key removal

* back up and restore managed hsm key

* add help.md

* import/download managed hsm RSA key

* Update help.md

* Update changelog.md

* suppress signature issues

* Update all help markdowns

* add logger for track2sdk

* add metadata for oct-HSM

Co-authored-by: Yeming Liu <Yeming.Liu@microsoft.com>

* Limit KeyType to be required only when create managed HSM key (#13242)

* limit KeyType to be required only when create managed HSM key

* add pester test

* Security domain (#13226)

* wip

* wip

* wip

* wip

* wip

* wip

* support securestring

* wip

* wip

* wip

* generate docs

* docs & error handling

* move crypto alg inside security domain

* resource strings

* remove extra code

* write help markdown

* resolve relative path to absolute path

* suppress signature issues

Co-authored-by: Yeming Liu <yeliu@microsoft.com>
Co-authored-by: Beisi Zhou <zhoubeisi@gmail.com>
Co-authored-by: Beisi Zhou <zazbs@qq.com>

* remove pfx file

* full backup restore + rbac (#13261)

Co-authored-by: Yeming Liu <yeliu@microsoft.com>

* small fixes

changelog; azure.core; sdk version; online version; breaking change csv;
shared assembly conflict; failed tests;

* license of BouncyCastle.NetCore

* remove local feed

Co-authored-by: Yeming Liu <Yeming.Liu@microsoft.com>
Co-authored-by: Yeming Liu <yeliu@microsoft.com>
isra-fel added a commit that referenced this pull request Oct 21, 2020
* Enable MHSM Management via *-AzKeyVault (#12575)

* Support creating a MHSM pool.

* Supporting querying MHSM objects

* Support deleting MHSM

* Support updating mhsm

* Add test cases

* Hide unavailable services

* Add test cases

* expose EnablePurgeProtection for MHSM

* correct indent of ps1xml

* upload localfeed

* Hide enablePurgeProtection

* Update ChangeLog.md and help.md

* Modify codes according to comments

* Update help.md

* Update VaultCreationParameters.cs

* Update get-azkeyvault.md

* Update KeyVaultManagementTests.ps1

* Record scenario test for Managed Hsm (#12631)

* Record scenario tests for managed hsm

* add default parameter set for

* Re-record scenario tests.

* [KeyVault] Update to official SDK (#12767)

* local 3.1.0 sdk

* Use production key vault mgmt sdk

* remove security domain from format xml

* combine track 1&2 sdk (#13018)

* combine track 1&2 sdk

* update azure.core to 1.5.0

* add exception; revert addkeyvaultkey

* add dll to psd1

* fix exception

* Detach managed hsm from key vault command (#13187)

* get managed hsm

* new managed hsm

* remove managed hsm

* update help.md

* update managed hsm

* add online version for new help.md

* Convert mhsm test to liveonly

* add test record

* Support data plane of managed HSM (#13216)

* create managed hsm key

* get managed hsm key

* remove managed hsm key

* update managed hsm key

* undo managed hsm key removal

* back up and restore managed hsm key

* add help.md

* import/download managed hsm RSA key

* Update help.md

* Update changelog.md

* suppress signature issues

* Update all help markdowns

* add logger for track2sdk

* add metadata for oct-HSM

Co-authored-by: Yeming Liu <Yeming.Liu@microsoft.com>

* Limit KeyType to be required only when create managed HSM key (#13242)

* limit KeyType to be required only when create managed HSM key

* add pester test

* Security domain (#13226)

* wip

* wip

* wip

* wip

* wip

* wip

* support securestring

* wip

* wip

* wip

* generate docs

* docs & error handling

* move crypto alg inside security domain

* resource strings

* remove extra code

* write help markdown

* resolve relative path to absolute path

* suppress signature issues

Co-authored-by: Yeming Liu <yeliu@microsoft.com>
Co-authored-by: Beisi Zhou <zhoubeisi@gmail.com>
Co-authored-by: Beisi Zhou <zazbs@qq.com>

* remove pfx file

* full backup restore + rbac (#13261)

Co-authored-by: Yeming Liu <yeliu@microsoft.com>

* small fixes

changelog; azure.core; sdk version; online version; breaking change csv;
shared assembly conflict; failed tests;

* license of BouncyCastle.NetCore

* remove local feed

Co-authored-by: Yeming Liu <Yeming.Liu@microsoft.com>
Co-authored-by: Yeming Liu <yeliu@microsoft.com>
dingmeng-xue added a commit that referenced this pull request Oct 22, 2020
Force merge after CI passed

* [KeyVault] Managed HSM (#13259)

* Enable MHSM Management via *-AzKeyVault (#12575)

* Support creating a MHSM pool.

* Supporting querying MHSM objects

* Support deleting MHSM

* Support updating mhsm

* Add test cases

* Hide unavailable services

* Add test cases

* expose EnablePurgeProtection for MHSM

* correct indent of ps1xml

* upload localfeed

* Hide enablePurgeProtection

* Update ChangeLog.md and help.md

* Modify codes according to comments

* Update help.md

* Update VaultCreationParameters.cs

* Update get-azkeyvault.md

* Update KeyVaultManagementTests.ps1

* Record scenario test for Managed Hsm (#12631)

* Record scenario tests for managed hsm

* add default parameter set for

* Re-record scenario tests.

* [KeyVault] Update to official SDK (#12767)

* local 3.1.0 sdk

* Use production key vault mgmt sdk

* remove security domain from format xml

* combine track 1&2 sdk (#13018)

* combine track 1&2 sdk

* update azure.core to 1.5.0

* add exception; revert addkeyvaultkey

* add dll to psd1

* fix exception

* Detach managed hsm from key vault command (#13187)

* get managed hsm

* new managed hsm

* remove managed hsm

* update help.md

* update managed hsm

* add online version for new help.md

* Convert mhsm test to liveonly

* add test record

* Support data plane of managed HSM (#13216)

* create managed hsm key

* get managed hsm key

* remove managed hsm key

* update managed hsm key

* undo managed hsm key removal

* back up and restore managed hsm key

* add help.md

* import/download managed hsm RSA key

* Update help.md

* Update changelog.md

* suppress signature issues

* Update all help markdowns

* add logger for track2sdk

* add metadata for oct-HSM

Co-authored-by: Yeming Liu <Yeming.Liu@microsoft.com>

* Limit KeyType to be required only when create managed HSM key (#13242)

* limit KeyType to be required only when create managed HSM key

* add pester test

* Security domain (#13226)

* wip

* wip

* wip

* wip

* wip

* wip

* support securestring

* wip

* wip

* wip

* generate docs

* docs & error handling

* move crypto alg inside security domain

* resource strings

* remove extra code

* write help markdown

* resolve relative path to absolute path

* suppress signature issues

Co-authored-by: Yeming Liu <yeliu@microsoft.com>
Co-authored-by: Beisi Zhou <zhoubeisi@gmail.com>
Co-authored-by: Beisi Zhou <zazbs@qq.com>

* remove pfx file

* full backup restore + rbac (#13261)

Co-authored-by: Yeming Liu <yeliu@microsoft.com>

* small fixes

changelog; azure.core; sdk version; online version; breaking change csv;
shared assembly conflict; failed tests;

* license of BouncyCastle.NetCore

* remove local feed

Co-authored-by: Yeming Liu <Yeming.Liu@microsoft.com>
Co-authored-by: Yeming Liu <yeliu@microsoft.com>

* use portable.bouncycastle

* bug fix...

...replace bouncycastle lib;
fix security domain issue on windows powershell

* Add pester test for RBAC and full-backup managed HSM

* fix dll list

* support relative path when restoring SD

* update license (bouncycastle.netcore -> portable)

* remove dependency Microsoft.IdentityModel.Tokens

Co-authored-by: Beisi Zhou <zhoubeisi@gmail.com>
Co-authored-by: Yeming Liu <yeliu@microsoft.com>
Co-authored-by: Beisi Zhou <zazbs@qq.com>
Co-authored-by: Dingmeng Xue <dixue@microsoft.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants