-
Notifications
You must be signed in to change notification settings - Fork 622
Open
Labels
area-bitlockerIssues for bitlocker moduleIssues for bitlocker moduledoc-bugFor Upwork freelance team categories/reporting.For Upwork freelance team categories/reporting.
Description
When the -Pin parameter is used and the -EncryptionMethod parameter is omitted, the interpretation of the cmdlet fails with:
Enable-BitLocker : Parameter set cannot be resolved using the specified named parameters.
At line:1 char:1
+ enable-bitlocker -whatif:$true -MountPoint X: -TpmAndPinProtecctor
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidArgument: (:) [Enable-BitLocker], ParameterBindingException
+ FullyQualifiedErrorId : AmbiguousParameterSet,Enable-BitLocker
This is the parameter set:
Enable-BitLocker
[-MountPoint] <String[]>
-TpmAndPinProtector
[-Pin] <SecureString>[-EncryptionMethod <BitLockerVolumeEncryptionMethodOnEnable>]
[-HardwareEncryption][-SkipHardwareTest]
[-UsedSpaceOnly]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Is the rightmost "]" in the wrong place? Should the "-EncryptionMethod" parameter name be enclosed in "[" and "]" making both the <SecureString> and <BitLockerVolumeEncryptionMethodOnEnable> mandatory parameters? In the description of the -EncryptionMethod paramter says the parameter is "Named", not positional. That would seem to mean that if "-Pin" is used (even as a positional parameter) the -EncryptionMethod parameter name must be used.
Document Details
⚠ Do not edit this section. It is required for learn.microsoft.com ➟ GitHub issue linking.
- ID: 9a1effb3-f98f-ce90-f31d-0ac05f7a1b91
- Version Independent ID: 3428c627-8703-752e-fbdf-52526f281f57
- Content: Enable-BitLocker (BitLocker)
- Content Source: docset/winserver2022-ps/bitlocker/Enable-BitLocker.md
- Product: w10
- GitHub Login: @JasonGerend
- Microsoft Alias: jgerend
Metadata
Metadata
Assignees
Labels
area-bitlockerIssues for bitlocker moduleIssues for bitlocker moduledoc-bugFor Upwork freelance team categories/reporting.For Upwork freelance team categories/reporting.