PowerShell

The PowerShell forum accepts bug reports as well as feedback and suggestions. For more information, check out the PowerShell Homepage

The following is a list of the states we use to track items.

status meaning
survey We saw this and we are considering it. Please upvote if it’s important to you.
needs more information We don’t understand the issue and need additional details.
investigating We are looking at this internally to understand things like: scenario, reproduction of issue, costing, or other technical details.
in queue The issue is understood and in our unprioritized backlog. Your votes will be used to drive prioritization of this work.

Please feel free to provide feedback or file bugs here.

(thinking…)

Enter your idea and we'll search to see if someone has already suggested it.

If a similar idea already exists, you can support and comment on it.

If it doesn't exist, you can post your idea so others can support it.

Enter your idea and we'll search to see if someone has already suggested it.

  • Hot ideas
  • Top ideas
  • New ideas
  • My feedback
  1. Slow "." hash lookups

    Slow "." hash lookups (more than 100 times slower than []) from PowerShell Version 2 to Version 5.1

    This could be either a documentation problem or a bug. The documentation never says that the "." hash lookup can be much slower than the [] lookup. I hope it is a bug (one less thing to remember). They both worked at the same speed in PS Version 2.0 and diverged sometime after that.

    Two script files. The first calls the second forcing versions 1 thru 5 of PowerShell.

    The "." hash lookups in PS Version 2.0 take .028 seconds.
    The "."…

    1 vote
    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      I agree to the terms of service
      Signed in as (Sign out)

      We’ll send you updates on this idea

      0 comments  ·  PowerShell Engine  ·  Flag idea as inappropriate…  ·  Admin →
    • PowerShell Query returns nothing

      I am trying to do a query to obtain setting values of RSOP_SecuritySettingBoolean in PowerShell (and WMI) but it returned nothing. The following query I attempted:

      E:\>PS E:\> Get-WmiObject -Namespace "root\RSOP\Computer" -Query "SELECT setting FROM RSOP_SecuritySettingBoolean Where KeyName='ClearTextPassword' and precedence='1'"

      PS E:\>

      For your extra information:

      E:\>ver

      Microsoft Windows [Version 10.0.14393]

      PS E:\> $psversiontable

      Name Value
      ---- -----
      PSVersion 5.1.14393.1198
      PSEdition Desktop
      PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
      BuildVersion 10.0.14393.1198
      CLRVersion 4.0.30319.42000
      WSManStackVersion 3.0
      PSRemotingProtocolVersion 2.3
      SerializationVersion 1.1.0.1

      My Windows 10 OS is still fresh, installed about 2 months ago via ISO. Why is it not returning any results? Please help.…

      1 vote
      Sign in
      Check!
      (thinking…)
      Reset
      or sign in with
      • facebook
      • google
        Password icon
        I agree to the terms of service
        Signed in as (Sign out)

        We’ll send you updates on this idea

        0 comments  ·  WMI  ·  Flag idea as inappropriate…  ·  Admin →
      • BUG: PowerShell xml node assignment with where-method

        Doing this works:
        ($xmlDoc.unattend.settings.Where({$_.pass -eq "specialize"}).component.Where({$_.name -eq "Microsoft-Windows-Shell-Setup"}) | Where-Object {$true}).ComputerName = "Test02";
        But without "| Where-Object {$true}" it fails.

        https://social.technet.microsoft.com/Forums/en-US/6801cfda-4699-4c2b-8a84-7d12de76e51d/powershell-xml-node-assignment-bug?forum=ITCG

        1 vote
        Sign in
        Check!
        (thinking…)
        Reset
        or sign in with
        • facebook
        • google
          Password icon
          I agree to the terms of service
          Signed in as (Sign out)

          We’ll send you updates on this idea

          0 comments  ·  Other PowerShell  ·  Flag idea as inappropriate…  ·  Admin →
        • Add a PowerShell module to manage Windows Updates

          Add a PowerShell module to manage Windows Updates like you can now with the GUI. Like checking for updates, installing all updates, or a selection of updates, creating a report of pending updates, etc. The Windows Update options in the Server Configuration Manager (sconfig) are very limited.

          32 votes
          Sign in
          Check!
          (thinking…)
          Reset
          or sign in with
          • facebook
          • google
            Password icon
            I agree to the terms of service
            Signed in as (Sign out)

            We’ll send you updates on this idea

            6 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →

            We don’t own the creation of modules for operating system features. I’ll mark this as Survey so we can provide this information to the WU team, but you might also want to consider filing this in the Windows 10 Feedback Hub. Also, see the community-created PSWindowsUpdate link below :)

          • DSC need to use full width of command processor in output

            DSC output is not respecting width of console and wraps text around despite full width is not utilized.
            Please see details here (https://github.com/PowerShell/PowerShell/issues/4030)

            1 vote
            Sign in
            Check!
            (thinking…)
            Reset
            or sign in with
            • facebook
            • google
              Password icon
              I agree to the terms of service
              Signed in as (Sign out)

              We’ll send you updates on this idea

              0 comments  ·  Desired State Configuration (DSC)  ·  Flag idea as inappropriate…  ·  Admin →
            • Enable WINRM certificate mapping for domain user

              Currently I need to manage Windows DNS server. I would like to use a client certificate to connect to WinRM to manage it, since I want to expose it in RESTful interface. But WINRM certificate mapping only allows non-domain account.

              1 vote
              Sign in
              Check!
              (thinking…)
              Reset
              or sign in with
              • facebook
              • google
                Password icon
                I agree to the terms of service
                Signed in as (Sign out)

                We’ll send you updates on this idea

                0 comments  ·  WinRM  ·  Flag idea as inappropriate…  ·  Admin →
              • Get-TargetResource should not use 'Required' parameters

                I'm not sure why this is, but for some reason Get-TargetResource requires not only the 'Key' parameters, but also the 'Required' parameters. My understanding is only 'Keys' should be necessary to find an existing resource and the 'Required' parameters are necessary when you want to create/update/delete something related to a resource.

                This really makes no sense and will hinder our ability to build higher level tech on top of DSC. If I have the key values for any piece of data in any system, I should be able to retrieve it without any additional information.

                In almost all of the…

                1 vote
                Sign in
                Check!
                (thinking…)
                Reset
                or sign in with
                • facebook
                • google
                  Password icon
                  I agree to the terms of service
                  Signed in as (Sign out)

                  We’ll send you updates on this idea

                  0 comments  ·  Desired State Configuration (DSC)  ·  Flag idea as inappropriate…  ·  Admin →
                • Start-Transcript does not capture user keyboard input when started from a script when ran under Powershell Version 5

                  I have found after upgrading Windows Powershell from Version 4 to Version 5 that the transcript log file created by the Start-Transcript commandlet does not capture the users keyboard input....where it does capture user input when running in Version 4.

                  Steps to replicate:

                  1. Create a ps1 script with Start-Transcript and a Write-Host/Read-Host response. (Feel free to use the "script code" below)

                  Start-Transcript C:\Temp\Test.log

                  Write-Host "Enter your name: " -NoNewline
                  $Name = Read-Host
                  Write-Host
                  Write-Host "You entered: $Name"

                  2. Run the script on a machine with Windows Powershell 4 installed, review the Transcript log.

                  3. Do the same on a…

                  4 votes
                  Sign in
                  Check!
                  (thinking…)
                  Reset
                  or sign in with
                  • facebook
                  • google
                    Password icon
                    I agree to the terms of service
                    Signed in as (Sign out)

                    We’ll send you updates on this idea

                    0 comments  ·  Other PowerShell  ·  Flag idea as inappropriate…  ·  Admin →
                  • Make PowerShell PKI module cross-platform with PS Core incl New-SelfSignedCertificate

                    PowerShell Core doesn't include the PKI module, which has the New-SelfSignedCertificate cmdlet. It would be great to have it available cross-platform.

                    Hence the feature request to make the PKI module cross-platform and compatible with PS Core to be distributed in the PowerShell Gallery: https://www.powershellgallery.com

                    Feature request with PS Core team and the reference to this UserVoice here:
                    https://github.com/PowerShell/PowerShell/issues/3715

                    3 votes
                    Sign in
                    Check!
                    (thinking…)
                    Reset
                    or sign in with
                    • facebook
                    • google
                      Password icon
                      I agree to the terms of service
                      Signed in as (Sign out)

                      We’ll send you updates on this idea

                      0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                    • Start-Process is behaving strange when -credential switch is used

                      When running Start-Process start-process "C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe" -cred $(Get-Credential) regardless if the credentials differ from the current consoles credentials or the same credentials are used, the new console window seems to be unresponsive, until you switch back to the console from which the new console was launched and start typing something in that console.

                      If the same thing is done in ISE, this issue does not occour.

                      I have testet this on PS 5.1.14393.206, 5.1.14393.953 and 5.1.14393.693. Windows Server 2012R2, Windows Server 2016 and Windows 10

                      Please see the issue in this video: https://goo.gl/8ZvdEV

                      3 votes
                      Sign in
                      Check!
                      (thinking…)
                      Reset
                      or sign in with
                      • facebook
                      • google
                        Password icon
                        I agree to the terms of service
                        Signed in as (Sign out)

                        We’ll send you updates on this idea

                        1 comment  ·  PowerShell Engine  ·  Flag idea as inappropriate…  ·  Admin →
                      • what works?

                        list what works?

                        1 vote
                        Sign in
                        Check!
                        (thinking…)
                        Reset
                        or sign in with
                        • facebook
                        • google
                          Password icon
                          I agree to the terms of service
                          Signed in as (Sign out)

                          We’ll send you updates on this idea

                          0 comments  ·  Other PowerShell  ·  Flag idea as inappropriate…  ·  Admin →
                        • Do not require starting brace to be on same line as cmdlet

                          It is very annoying and confusing that some cmdlets require the starting brace to be on the same line as the cmdlet, while others do not.

                          For example, this is valid:

                          ... | ForEach-Object {
                          $sourcefile = $_.Name
                          }

                          but this is not:

                          ... | ForEach-Object
                          {
                          $sourcefile = $_.Name
                          }

                          yet using this is valid:

                          foreach ($x in $y)
                          {
                          $sourcefile = $_.Name
                          }

                          I know that you can use the backtick to make it valid, like this:

                          ... | ForEach-Object `
                          {
                          $sourcefile = $_.Name
                          }

                          but that's still not intuitive and requires you to remember to do…

                          1 vote
                          Sign in
                          Check!
                          (thinking…)
                          Reset
                          or sign in with
                          • facebook
                          • google
                            Password icon
                            I agree to the terms of service
                            Signed in as (Sign out)

                            We’ll send you updates on this idea

                            0 comments  ·  PowerShell Engine  ·  Flag idea as inappropriate…  ·  Admin →
                          • Why can't Acrobat save these PowerShell articles?

                            I've tried several ways to capture the PowerShell documentation into a single PDF file which I find much more convenient instead of clicking around a Microsoft site. Acrobat just locks up. I've never seen it behave this way before.

                            It places PowerShell out of reach for those of us trying to learn new tools.

                            Please try it yourself. Acrobat XI Pro.
                            - Use the browser plugin "create PDF from webpage"
                            - Or start with Acrobat "create PDF"
                            - Or Browser / Save as html complete

                            Print to PDF is inadequate because webpage links are missing and on the PowerShell pages,…

                            1 vote
                            Sign in
                            Check!
                            (thinking…)
                            Reset
                            or sign in with
                            • facebook
                            • google
                              Password icon
                              I agree to the terms of service
                              Signed in as (Sign out)

                              We’ll send you updates on this idea

                              2 comments  ·  Documentation  ·  Flag idea as inappropriate…  ·  Admin →
                            • [bug] ConverttoDateTime

                              The ConvertToDateTime() ScriptMethod is incorrect / broken and does NOT take into account the current time zone as defined by System.Management.ManagementDateTimeConverter.ToDateTime() method. In fact, it's not applying any time zone at all. Full analysis and test scripts at my blog - https://goo.gl/b4ZTqf

                              1 vote
                              Sign in
                              Check!
                              (thinking…)
                              Reset
                              or sign in with
                              • facebook
                              • google
                                Password icon
                                I agree to the terms of service
                                Signed in as (Sign out)

                                We’ll send you updates on this idea

                                2 comments  ·  WMI  ·  Flag idea as inappropriate…  ·  Admin →
                              • Foreach Does Not Run If Statements For Array Elements

                                Copy and run with -Debug. You'll see...

                                function Get-ArrayDups([array]$ArrayCheck, $IOI) {
                                $indices = @()

                                For($i=0;$i -le $ArrayCheck.Length; $i++) {If ($IOI -eq $ArrayCheck[$i]) {$indices += $i}}
                                "Variable `$indices = " + $indices
                                "`$ArrayCheck[0] = " + $ArrayCheck[0]
                                "`$ArrayCheck[9] = " + $ArrayCheck[9]
                                }

                                Function Get-ArrayDups {
                                [cmdletbinding()]
                                Param(
                                [Parameter(ValueFromPipeline = $true)]
                                [Array]
                                $ArrayContent,

                                [int]
                                $IOI
                                )
                                BEGIN { [array]$indices = @()
                                $Len = $ArrayContent.Count
                                $i = 0
                                Write-Debug "Initial Value: `$Len = $Len"
                                Write-Debug "Initial Value: `$ArrayContent[`$Len] = $($ArrayContent[$Len-1])"
                                Write-Debug "Initial Value: IOI is $IOI"
                                Write-Debug "Initial Value: The full passed in array is $ArrayContent"
                                Write-Debug "Initial Value: Length of `$indices…

                                1 vote
                                Sign in
                                Check!
                                (thinking…)
                                Reset
                                or sign in with
                                • facebook
                                • google
                                  Password icon
                                  I agree to the terms of service
                                  Signed in as (Sign out)

                                  We’ll send you updates on this idea

                                  0 comments  ·  PowerShell Engine  ·  Flag idea as inappropriate…  ·  Admin →
                                • Bring the Azure Automation DSC MOF encryption into the on-premises DSC pull server

                                  In Azure Automation DSC the whole MOF file gets encrypted without the need to manually issue certificates for every node and then to collect the public keys.

                                  From Azure documentation:
                                  "Keeping credentials secure in node configurations (MOF configuration documents) requires encrypting the credentials in the node configuration MOF file. Azure Automation takes this one step further and encrypts the entire MOF file."

                                  This extremely useful feature sould also be implemented in the on-premises DSC pull server. Especially because the needed functionality must alread be in the WMF 5 as nothing more than WMF 5 is needed to use the Azure…

                                  6 votes
                                  Sign in
                                  Check!
                                  (thinking…)
                                  Reset
                                  or sign in with
                                  • facebook
                                  • google
                                    Password icon
                                    I agree to the terms of service
                                    Signed in as (Sign out)

                                    We’ll send you updates on this idea

                                    survey  ·  0 comments  ·  Desired State Configuration (DSC)  ·  Flag idea as inappropriate…  ·  Admin →
                                  • Select-String with pipe Bug

                                    Type : adb logcat | Select-String --Patern "xyz"

                                    Known : Pattern argument take only one "-"

                                    As adb logcat output data contniously which is piped with select string
                                    command if we use two "-" with patern argument then powershell stucks in endless loop with its error output

                                    Sugession : Please do proper error handling in arguments also

                                    1 vote
                                    Sign in
                                    Check!
                                    (thinking…)
                                    Reset
                                    or sign in with
                                    • facebook
                                    • google
                                      Password icon
                                      I agree to the terms of service
                                      Signed in as (Sign out)

                                      We’ll send you updates on this idea

                                      0 comments  ·  PowerShell Engine  ·  Flag idea as inappropriate…  ·  Admin →
                                    • Unregister-ScheduledJob -Name 'Name' -WhatIf does not honor WhatIf

                                      Steps to reproduce

                                      Import-Module PSScheduledJob
                                      Register-ScheduledJob -Name 'test' -ScriptBlock {echo 'hello world'}
                                      Unregister-ScheduledJob -Name test -WhatIf
                                      Get-ScheduledJob

                                      Expected behavior

                                      I expect the job to still be there.

                                      It does work with Unregister-ScheduledJob -Id 11 -WhatIf.

                                      Actual behavior

                                      The scheduled job is corrupted.

                                      Get-ScheduledJob : Cannot get the test scheduled job because it is corrupted or in an irresolvable state. Because
                                      it cannot run, Windows PowerShell has deleted test and its results from the computer. To recreate the scheduled
                                      job, use the Register-ScheduledJob cmdlet. For more information about corrupted scheduled jobs, see
                                      about_Scheduled_Jobs_Troubleshooting.

                                      Environment data

                                      > $PSVersionTable
                                      Name Value
                                      ---- ----- …

                                      1 vote
                                      Sign in
                                      Check!
                                      (thinking…)
                                      Reset
                                      or sign in with
                                      • facebook
                                      • google
                                        Password icon
                                        I agree to the terms of service
                                        Signed in as (Sign out)

                                        We’ll send you updates on this idea

                                        0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                                      • Disable-ScheduledTask -TaskName will fail with tasks including spaces in name.

                                        Steps to reproduce
                                        ------------------
                                        Disable-ScheduledTask -TaskName "Data Integrity Scan for Crash Recovery"
                                        Disable-ScheduledTask : The system cannot find the file specified.
                                        At line:1 char:1
                                        + Disable-ScheduledTask "Data Integrity Scan for Crash Recovery"
                                        + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                        + CategoryInfo : ObjectNotFound: (PS_ScheduledTask:Root/Microsoft/...S_ScheduledTask) [
                                        Disable-ScheduledTask], CimException
                                        + FullyQualifiedErrorId : HRESULT 0x80070002,Disable-ScheduledTask

                                        Expected behavior
                                        -----------------
                                        This should disable the scheduled task and not crash.

                                        You can workaround this by searching for the task object and disabling that way:

                                        $Name = "Data Integrity Scan for Crash Recovery"
                                        Get-ScheduledTask | where-object {($_.TaskName -eq $Name)} | Disable-ScheduledTask

                                        Actual behavior
                                        ---------------
                                        Crashes with the following exception:
                                        Disable-ScheduledTask : The…

                                        1 vote
                                        Sign in
                                        Check!
                                        (thinking…)
                                        Reset
                                        or sign in with
                                        • facebook
                                        • google
                                          Password icon
                                          I agree to the terms of service
                                          Signed in as (Sign out)

                                          We’ll send you updates on this idea

                                          0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                                        • get-command -module only shows aliases with verb-noun naming

                                          If a module exports aliases which don't follow the verb-noun convention (which most don't), they aren't shown with get-command -module <modulename>.

                                          Get-command -module <modulename> -commandType Alias does show them,
                                          as does
                                          Get-command -module <modulename> -all
                                          This is counter-intuitive, because -commandtype should narrow the results, and the description of the -all switch says it's for "revealing" commands hidden by naming collisions.

                                          2 votes
                                          Sign in
                                          Check!
                                          (thinking…)
                                          Reset
                                          or sign in with
                                          • facebook
                                          • google
                                            Password icon
                                            I agree to the terms of service
                                            Signed in as (Sign out)

                                            We’ll send you updates on this idea

                                            0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                                          • Don't see your idea?

                                          Feedback and Knowledge Base