AzureLocal.LocalIdentity.AdminSetup.psd1

#
# Module manifest for module 'AzureLocal.LocalIdentity.AdminSetup'
#
# Generated by: Microsoft Corporation
#
# Generated on: 5/11/2026
#

@{

# Script module or binary module file associated with this manifest.
RootModule = 'AzureLocal.LocalIdentity.AdminSetup.psm1'

# Version number of this module.
ModuleVersion = '1.0.5'

# Supported PSEditions
# CompatiblePSEditions = @()

# ID used to uniquely identify this module
GUID = 'db5a98a5-e8c3-44c8-ae73-ca2337b2e1f4'

# Author of this module
Author = 'Microsoft Corporation'

# Company or vendor of this module
CompanyName = 'Microsoft Corporation'

# Copyright statement for this module
Copyright = '(c) Microsoft Corporation. All rights reserved.'

# Description of the functionality provided by this module
Description = 'PowerShell module for managing local (AD-less) identity and PKU2U certificate-based
admin accounts on Azure Local (Azure Stack HCI) workgroup clusters.
 
This module enables full lifecycle management of local cluster administrators on
workgroup-joined Azure Local nodes that do not have access to Active Directory.
It configures the host for cross-machine local-account remoting (WinRM, CredSSP,
TrustedHosts, firewall, LocalAccountTokenFilterPolicy, and credential-delegation
group policy), enables PKU2U via registry, provisions PKU2U authority and user
certificates into the correct stores with private-key ACLs for required services,
and creates / removes local admin accounts either directly on the current node
or cluster-wide across an Azure Local deployment.
 
Exported functions:
 
  Set-AzureLocalRemotingConfiguration
      Configures the local machine for workgroup cluster remoting: WinRM,
      TrustedHosts, firewall rules, CredSSP (client + server), WSMan certificate
      auth, PKU2U registry settings, local group policy for credential delegation,
      and restarts the WinRM service.
 
  New-AzureLocalAdminWithCertificates
      Creates a local admin user on the current node and installs the supplied
      PKU2U authority (root CA) and user PFX certificate files into the correct
      certificate stores. Use this when you already have the PFX files on disk.
 
  New-AzureLocalAdminFromKeyVault
      Downloads the PKU2U authority and user certificates from an Azure Key Vault,
      re-exports them as password-protected PFX files on disk, then creates the
      local admin user and installs the certificates for PKU2U authentication.
 
  New-AzureLocalAdminFromKeyVaultInMemory
      Same as New-AzureLocalAdminFromKeyVault but never writes the
      certificate material to disk. Certificates are downloaded as raw bytes
      and imported directly into the certificate stores.
 
  New-AzureLocalLocalAdminAccount
      Cluster-wide creation of a local admin account on an Azure Local
      deployment. Provisions the account, certificates, and remoting
      configuration consistently on every node in the cluster. The PKU2U
      authority name is derived from the account name by appending "AU".
 
  Remove-AzureLocalLocalAdminAccount
      Cluster-wide removal of one or more local admin accounts from every node
      in an Azure Local deployment.
 
  Remove-AzureLocalExpiredLocalAdminAccounts
      Cluster-wide cleanup of expired local admin accounts from every node in
      an Azure Local deployment.
 
Usage examples:
 
  # 1. Prepare the local node for workgroup-cluster remoting (trust two nodes)
  Set-AzureLocalRemotingConfiguration -TrustedHosts ''node1,node2''
 
  # 2. Create a local cluster admin from PFX files already on disk
  $pwd = Read-Host -AsSecureString ''Local user password''
  New-AzureLocalAdminWithCertificates `
      -Username ''ClusterAdmin'' -UserPassword $pwd `
      -UserCertName ''C:\Certs\user.pfx'' `
      -AuthorityCertName ''C:\Certs\root.pfx'' `
      -CertPath ''C:\Certs'' -Nodes @(''node1'',''node2'')
 
  # 3. Create a local cluster admin from certificates in Azure Key Vault
  New-AzureLocalAdminFromKeyVault `
      -VaultName ''MyVault'' -Username ''ClusterAdmin'' -UserPassword $pwd `
      -UserCertName ''pku2u-user'' -AuthorityCertName ''pku2u-root'' `
      -CertPath ''C:\Certs'' -ClusterName ''MyCluster''
 
  # 4. Same as #3 but never write the PFX files to disk
  New-AzureLocalAdminFromKeyVaultInMemory `
      -VaultName ''MyVault'' -Username ''ClusterAdmin'' -UserPassword $pwd `
      -UserCertName ''pku2u-user'' -AuthorityCertName ''pku2u-root'' `
      -ClusterName ''MyCluster''
 
  # 5. Cluster-wide account lifecycle to be ran on an Azure Local node
  New-AzureLocalLocalAdminAccount -AccountName ''ops1''
  Remove-AzureLocalLocalAdminAccount -AccountNames @(''ops1'',''ops2'')
  Remove-AzureLocalExpiredLocalAdminAccounts'


# Minimum version of the Windows PowerShell engine required by this module
PowerShellVersion = '5.1'

# Name of the Windows PowerShell host required by this module
# PowerShellHostName = ''

# Minimum version of the Windows PowerShell host required by this module
# PowerShellHostVersion = ''

# Minimum version of Microsoft .NET Framework required by this module. This prerequisite is valid for the PowerShell Desktop edition only.
# DotNetFrameworkVersion = ''

# Minimum version of the common language runtime (CLR) required by this module. This prerequisite is valid for the PowerShell Desktop edition only.
# CLRVersion = ''

# Processor architecture (None, X86, Amd64) required by this module
# ProcessorArchitecture = ''

# Modules that must be imported into the global environment prior to importing this module
# RequiredModules = @()

# Assemblies that must be loaded prior to importing this module
# RequiredAssemblies = @()

# Script files (.ps1) that are run in the caller's environment prior to importing this module.
# ScriptsToProcess = @()

# Type files (.ps1xml) to be loaded when importing this module
# TypesToProcess = @()

# Format files (.ps1xml) to be loaded when importing this module
# FormatsToProcess = @()

# Modules to import as nested modules of the module specified in RootModule/ModuleToProcess
# 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 = 'Set-AzureLocalRemotingConfiguration', 
               'New-AzureLocalAdminWithCertificates', 
               'New-AzureLocalAdminFromKeyVault', 
               'New-AzureLocalAdminFromKeyVaultInMemory', 
               'New-AzureLocalLocalAdminAccount', 
               'Remove-AzureLocalLocalAdminAccount', 
               'Remove-AzureLocalExpiredLocalAdminAccounts'

# 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 = @()

# Variables to export from this module
# VariablesToExport = @()

# Aliases 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 aliases to export.
AliasesToExport = @()

# DSC resources to export from this module
# DscResourcesToExport = @()

# List of all modules packaged with this module
# ModuleList = @()

# List of all files packaged with this module
# FileList = @()

# Private data to pass to the module specified in RootModule/ModuleToProcess. This may also contain a PSData hashtable with additional module metadata used by PowerShell.
PrivateData = @{

    PSData = @{

        # Tags applied to this module. These help with module discovery in online galleries.
        Tags = 'AzureLocal','AzureStackHCI','PKU2U','LocalIdentity','WorkgroupCluster','ADLess','WinRM','CredSSP','Certificate','KeyVault','Windows'

        # A URL to the license for this module.
        LicenseUri = 'https://www.microsoft.com/en-us/legal/intellectualproperty/copyright'

        # A URL to the main website for this project.
        # ProjectUri = ''

        # A URL to an icon representing this module.
        # IconUri = ''

        # ReleaseNotes of this module
        ReleaseNotes = '1.0.0
- Initial release.
- Set-AzureLocalRemotingConfiguration: configure WinRM, CredSSP,
  TrustedHosts, firewall, PKU2U registry, and credential delegation policy.
- New-AzureLocalAdminWithCertificates: create local cluster admin
  using PFX files already on disk.
- New-AzureLocalAdminFromKeyVault: create local cluster admin using
  certificates downloaded from Azure Key Vault (PFX written to disk).
- New-AzureLocalAdminFromKeyVaultInMemory: create local cluster admin
  using certificates downloaded from Azure Key Vault without writing PFX files
  to disk.
- New-AzureLocalLocalAdminAccount, Remove-AzureLocalLocalAdminAccount,
  Remove-AzureLocalExpiredLocalAdminAccounts: cluster-wide local admin account
  lifecycle on an Azure Local deployment.'


        # Prerelease string of this module
        # Prerelease = ''

        # Flag to indicate whether the module requires explicit user acceptance for install/update/save
        # RequireLicenseAcceptance = $false

        # External dependent modules of this module
        # ExternalModuleDependencies = @()

    } # End of PSData hashtable

 } # End of PrivateData hashtable

# HelpInfo URI of this module
# HelpInfoURI = ''

# Default prefix for commands exported from this module. Override the default prefix using Import-Module -Prefix.
# DefaultCommandPrefix = ''

}