Skip to content

Attestation/WSS Release #16360

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

Merged
merged 4 commits into from
Nov 11, 2021
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
11 changes: 9 additions & 2 deletions src/StackHCI/Az.StackHCI.psd1
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,15 @@ RequiredModules = @(@{ModuleName = 'Az.Accounts'; ModuleVersion = '2.6.1'; })
# NestedModules = @()

# Functions to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no functions to export.
FunctionsToExport = 'Register-AzStackHCI', 'Unregister-AzStackHCI',
'Test-AzStackHCIConnection'
FunctionsToExport = 'Register-AzStackHCI',
'Unregister-AzStackHCI',
'Test-AzStackHCIConnection',
'Set-AzStackHCI',
'Enable-AzStackHCIAttestation',
'Disable-AzStackHCIAttestation',
'Add-AzStackHCIVMAttestation',
'Remove-AzStackHCIVMAttestation',
'Get-AzStackHCIVMAttestation'

# Cmdlets to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no cmdlets to export.
CmdletsToExport = @()
Expand Down
1,559 changes: 1,538 additions & 21 deletions src/StackHCI/Az.StackHCI.psm1

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions src/StackHCI/ChangeLog.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@
- Additional information about change #1
-->
## Upcoming Release
* Added Support for AzureStack HCI Attestation (Azure Benefits)
- New cmdlets: Enable-AzStackHCIAttestation, Disable-AzStackHCIAttestation, Add-AzStackHCIVMAttestation, Remove-AzStackHCIVMAttestation, Get-AzStackHCIVMAttestation
* Added Support for Windows Server Subscription
- New cmdlet: Set-AzStackHCI

## Version 0.9.1
* Added Support for AzureUSGovernment cloud
Expand Down
155 changes: 155 additions & 0 deletions src/StackHCI/help/Add-AzStackHCIVMAttestation.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,155 @@
---
external help file: Az.StackHCI-help.xml
Module Name: Az.StackHCI
online version: https://docs.microsoft.com/powershell/module/az.stackhci/add-AzStackHCIVMAttestation
schema: 2.0.0
---

# Add-AzStackHCIVMAttestation

## SYNOPSIS
Add-AzStackHCIVMAttestation configures guests for AzureStack HCI IMDS Attestation.

## SYNTAX

### VMName (Default)
```
Add-AzStackHCIVMAttestation [-VMName] <String[]> [-Force] [-WhatIf] [-Confirm] [<CommonParameters>]
```

### VMObject
```
Add-AzStackHCIVMAttestation [-VM] <Object[]> [-Force] [-WhatIf] [-Confirm] [<CommonParameters>]
```

### AddAll
```
Add-AzStackHCIVMAttestation [-AddAll] [-Force] [-WhatIf] [-Confirm] [<CommonParameters>]
```

## DESCRIPTION
Add-AzStackHCIVMAttestation configures guests for AzureStack HCI IMDS Attestation.

## EXAMPLES

### EXAMPLE 1
```powershell
C:\PS\>Add-AzStackHCIVMAttestation -AddAll
```

Adding all guests on current node

### EXAMPLE 2
```powershell
C:\PS\>Invoke-Command -ScriptBlock {Add-AzStackHCIVMAttestation -VMName "guest1", "guest2"} -ComputerName "node1"
```

Invoking from the management node/WAC

## PARAMETERS

### -AddAll
Specifies a switch that will add all current guest VMs on host to IMDS Attestation on the current node.

```yaml
Type: System.Management.Automation.SwitchParameter
Parameter Sets: AddAll
Aliases:

Required: True
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
```

### -Force
No Confirmation

```yaml
Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
```

### -VM
Specifies an array of VM objects from Get-VM.

```yaml
Type: System.Object[]
Parameter Sets: VMObject
Aliases:

Required: True
Position: 1
Default value: None
Accept pipeline input: True (ByValue)
Accept wildcard characters: False
```

### -VMName
Specifies an array of guest VMs to enable.

```yaml
Type: System.String[]
Parameter Sets: VMName
Aliases:

Required: True
Position: 1
Default value: None
Accept pipeline input: True (ByValue)
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

### PSCustomObject. Returns following Properties in PSCustomObject
### Name: Name of the VM.
### AttestationHost: Host that VM is currently connected.
### Status: Connection status.
## NOTES

## RELATED LINKS
18 changes: 18 additions & 0 deletions src/StackHCI/help/Az.StackHCI.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,27 @@ Locale: en-US
Microsoft Azure PowerShell: Azure Stack HCI registration cmdlets

## Az.StackHCI Cmdlets
### [Add-AzStackHCIVMAttestation](Add-AzStackHCIVMAttestation.md)
Add-AzStackHCIVMAttestation configures guests for AzureStack HCI IMDS Attestation.

### [Disable-AzStackHCIAttestation](Disable-AzStackHCIAttestation.md)
Disable-AzStackHCIAttestation disables IMDS Attestation on the host

### [Enable-AzStackHCIAttestation](Enable-AzStackHCIAttestation.md)
Enable-AzStackHCIAttestation configures the host and enables specified guests for IMDS attestation.

### [Get-AzStackHCIVMAttestation](Get-AzStackHCIVMAttestation.md)
Get-AzStackHCIVMAttestation shows a list of guests added to IMDS Attestation on a node.

### [Register-AzStackHCI](Register-AzStackHCI.md)
Register-AzStackHCI creates a Microsoft.AzureStackHCI cloud resource representing the on-premise cluster and registers the on-premise cluster with Azure.

### [Remove-AzStackHCIVMAttestation](Remove-AzStackHCIVMAttestation.md)
Remove-AzStackHCIVMAttestation removes guests from AzureStack HCI IMDS Attestation.

### [Set-AzStackHCI](Set-AzStackHCI.md)
Set-AzStackHCI modifies resource properties of the Microsoft.AzureStackHCI cloud resource representing the on-premises cluster to enable or disable features.

### [Test-AzStackHCIConnection](Test-AzStackHCIConnection.md)
Test-AzStackHCIConnection verifies connectivity from on-premises clustered nodes to the Azure services required by Azure Stack HCI.

Expand Down
144 changes: 144 additions & 0 deletions src/StackHCI/help/Disable-AzStackHCIAttestation.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,144 @@
---
external help file: Az.StackHCI-help.xml
Module Name: Az.StackHCI
online version: https://docs.microsoft.com/powershell/module/az.stackhci/disable-azstackhciattestation
schema: 2.0.0
---

# Disable-AzStackHCIAttestation

## SYNOPSIS
Disable-AzStackHCIAttestation disables IMDS Attestation on the host

## SYNTAX

```
Disable-AzStackHCIAttestation [[-ComputerName] <String>] [-Credential <PSCredential>] [-RemoveVM] [-Force]
[-WhatIf] [-Confirm] [<CommonParameters>]
```

## DESCRIPTION
Disable-AzStackHCIAttestation disables IMDS Attestation on the host

## EXAMPLES

### EXAMPLE 1
```powershell
C:\PS\>Disable-AzStackHCIAttestation -RemoveVM
```

Remove all guests from IMDS Attestation before disabling on cluster nodes.

### EXAMPLE 2
```powershell
C:\PS\>Disable-AzStackHCIAttestation -ComputerName "host1"
```

## PARAMETERS

### -ComputerName
Specifies the AzureStack HCI host to perform the operation on.

```yaml
Type: System.String
Parameter Sets: (All)
Aliases:

Required: False
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```

### -Credential
Specifies the credential for the ComputerName.
Default is the current user executing the Cmdlet.

```yaml
Type: System.Management.Automation.PSCredential
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: [System.Management.Automation.PSCredential]::Empty
Accept pipeline input: False
Accept wildcard characters: False
```

### -Force
No confirmation.

```yaml
Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
```

### -RemoveVM
Specifies the guests on each node should be removed from IMDS Attestation before disabling on cluster.
Disable cannot continue before guests are removed.

```yaml
Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
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

### PSCustomObject. Returns following Properties in PSCustomObject
### Cluster: Name of cluster
### Node: Name of the host.
### Attestation: IMDS Attestation status.
## NOTES

## RELATED LINKS
Loading