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. Import-json

    json is becoming the new standard (if not already)
    It would be nice to have an import-json and a export-json as we have in xml/csv instead of the two steps process with get-content and convertfrom-json and convertto-json.

    8 votes
    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      Signed in as (Sign out)

      We’ll send you updates on this idea

      0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
    • Missing newer computer account in Get-LocalUser on a DC

      in PowerShell 5.1.14393.2608 when I run Get-LocalUser * on a Windows Server 2016 Domain Controller I should get a list of all domain user and computer. But the newest Domain joined computer is missing.
      Please fix this.
      Also when I run Get-LocalUser MyComputer$ and MyComputer is the last domain joined computer I get ObjectNotFound

      2 votes
      Sign in
      Check!
      (thinking…)
      Reset
      or sign in with
      • facebook
      • google
        Password icon
        Signed in as (Sign out)

        We’ll send you updates on this idea

        0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
      • How to create external trust relationships between two domains?

        How to create external trust relationships between two domains, such as aaa.com and bbb.com. I haven't seen a similar demo for two days.
        Looking forward to your reply.

        1 vote
        Sign in
        Check!
        (thinking…)
        Reset
        or sign in with
        • facebook
        • google
          Password icon
          Signed in as (Sign out)

          We’ll send you updates on this idea

          1 comment  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
        • BUG: Get-Help <word> doesn't search content of about_* files unless -Category HelpFiles parameter is specified

          The help text for the -Name parameter of Get-Help says:
          "...If you enter a word that does not match any help topic titles, Get-Help displays a list of topics that include that word in their contents."

          Example:
          PS> Get-Help exit

          Only returned two cmdlets that have the word 'exit' in their name.

          PS> Get-Help exit -Category HelpFile

          Returns about_* topics where the word 'exit' is found.

          1 vote
          Sign in
          Check!
          (thinking…)
          Reset
          or sign in with
          • facebook
          • google
            Password icon
            Signed in as (Sign out)

            We’ll send you updates on this idea

            0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
          • BUG: Get-RDSessionCollection always generates exception on Windows Server 2019

            Get-RDSessionCollection of the RemoteDesktop module always throws an exception:
            --

            PS C:\windows\system32> Get-RDSessionCollection
            New-Object : Exception calling ".ctor" with "1" argument(s): "Invalid parameter "
            At C:\windows\system32\WindowsPowerShell\v1.0\Modules\RemoteDesktop\SessionDesktopCollection.psm1:520 char:14
            + ... $scope = New-Object System.Management.ManagementScope("\\" + $Conn ...
            + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
            + CategoryInfo : InvalidOperation: (:) [New-Object], MethodInvocationException
            + FullyQualifiedErrorId : ConstructorInvokedThrowException,Microsoft.PowerShell.Commands.NewObjectCommand

            CollectionName Size ResourceType CollectionType CollectionDescription
            -------------- ---- ------------ -------------- ---------------------
            mycollection 0 RemoteApp programs PooledUnmanaged My first collection

            PS C:\windows\system32>

            --

            Changing C:\Windows\System32\WindowsPowerShell\v1.0\Modules\RemoteDesktop\SessionDesktopCollection.psm1 line 520

            $scope = New-Object System.Management.ManagementScope("\\" + $ConnectionBroker + "\" + $wmiNamespace, $connectionOptions)

            into

            $msuri = "\\" + $ConnectionBroker + "\" + $wmiNamespace
            $scope = New-Object System.Management.ManagementScope($msuri, $connectionOptions)

            1 vote
            Sign in
            Check!
            (thinking…)
            Reset
            or sign in with
            • facebook
            • google
              Password icon
              Signed in as (Sign out)

              We’ll send you updates on this idea

              0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
            • Bug in Import-StartLayout cmdlet

              The documentation states to import a .xml to a mounted Windows image, you can use the powershell command:
              PS C:\ Import-StartLayout -LayoutPath "Layout.xml" -MountPath "E:\MountedImage"

              This will generate an error. You cannot end -MountPath with a '' character, if you do, PowerShell throws the error:
              Import-StartLayout : The path B:\WIMs\Test\ did not resolve to a file.

              If you format the command:
              PS C:\ Import-StartLayout -LayoutPath "Layout.xml" -MountPath "E:\MountedImage"
              You will receive the following error:
              Import-StartLayout : Could not find a part of the path
              'E:\MountedImageUsers\Default\AppData\Local\Microsoft\Windows\Shell\LayoutModification.xml'.
              Note the missing '\' character between "MountedImage" and "Users"
              This appears to be an error…

              1 vote
              Sign in
              Check!
              (thinking…)
              Reset
              or sign in with
              • facebook
              • google
                Password icon
                Signed in as (Sign out)

                We’ll send you updates on this idea

                0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
              • [Bug]: using module that import a script that import classes have unexpected behavior within a class

                ClassA.psm1
                ------------------
                class ClassA
                {
                [string]Execute()
                {
                return "this is from ClassA"
                }
                }

                ClassB.psm1
                ------------------
                class ClassB
                {
                [string]Execute()
                {
                return "this is from ClassB"
                }
                }

                ImportClasses.ps1
                -------------------------
                using module 'D:\Exemple\Atelier\ClassImportProblem\ClassA.psm1'
                using module 'D:\Exemple\Atelier\ClassImportProblem\ClassB.psm1'

                process_Classes.ps1
                ----------------------------
                using module 'D:\Exemple\Atelier\ClassImportProblem\ImportClasses.ps1'

                $a = [ClassA]::new()
                $b = [ClassB]::new()

                class HustonweHaveAProblem
                {
                [void]HereWeGo(){
                $a = [ClassA]::new()
                $b = [ClassB]::new()
                }
                }

                Observation:

                From that point, instances of ClassA and ClassB are working fine in the process_Classes script. But instances of ClassA and ClassB within the class HustonWeHaveAProblem{} throw errors.

                Actual result:

                At D:\Exemple\Atelier\ClassImportProblem\process_Classes.ps1:9 char:15
                + $a = [ClassA]::new()
                + ~~~~~~
                Unable to…

                1 vote
                Sign in
                Check!
                (thinking…)
                Reset
                or sign in with
                • facebook
                • google
                  Password icon
                  Signed in as (Sign out)

                  We’ll send you updates on this idea

                  0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                • "Test-NetConnection" add timeout

                  please add timeout to "Test-NetConnection" see https://superuser.com/q/805621/216033

                  1 vote
                  Sign in
                  Check!
                  (thinking…)
                  Reset
                  or sign in with
                  • facebook
                  • google
                    Password icon
                    Signed in as (Sign out)

                    We’ll send you updates on this idea

                    0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                  • How to create external trust relationships between two domains?

                    How to create external trust relationships between two domains, such as aaa.com and bbb.com. I haven't seen a similar demo for two days.
                    Looking forward to your reply.

                    1 vote
                    Sign in
                    Check!
                    (thinking…)
                    Reset
                    or sign in with
                    • facebook
                    • google
                      Password icon
                      Signed in as (Sign out)

                      We’ll send you updates on this idea

                      0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                    • Get-DnsServerZone does not cater for secondary zones that allow zone transfers

                      If you have a secondary zone which in turn is configured to allow a zone transfer to another DNS server hosting the zone as a secondary, the Get-DnsServerZone cmdlet does not display that information.

                      Run: Get-DnsServerZone -Name zone.name | where-object {$_.zonetype -eq "secondary"} | select-object ZoneName, SecondaryServers
                      Result: Display zone name and secondary servers.
                      Actual Result: Displays just the zone name, no secondary servers are displayed even though they are setup.

                      The data is however available via WMI.

                      Get-WmiObject -Namespace root/microsoftdns -Class microsoftdns_zone | where-object {$_.containername -eq "zone.name"} | select-object containername, secondaryservers

                      1 vote
                      Sign in
                      Check!
                      (thinking…)
                      Reset
                      or sign in with
                      • facebook
                      • google
                        Password icon
                        Signed in as (Sign out)

                        We’ll send you updates on this idea

                        0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                      • Make Add-Type support .EXE assemblies (works on rename to .DLL)

                        Running Add-Type with a .EXE assembly gives, 'Cannot add type. The ".EXE" extension is not supported'. But it works if I rename the assembly to .DLL. I think this limitation is artificial and should be removed.

                        1 vote
                        Sign in
                        Check!
                        (thinking…)
                        Reset
                        or sign in with
                        • facebook
                        • google
                          Password icon
                          Signed in as (Sign out)

                          We’ll send you updates on this idea

                          0 comments  ·  Microsoft.PowerShell.* Modules  ·  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.

                          39 votes
                          Sign in
                          Check!
                          (thinking…)
                          Reset
                          or sign in with
                          • facebook
                          • google
                            Password icon
                            Signed in as (Sign out)

                            We’ll send you updates on this idea

                            7 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 :)

                          • Bug: Integrated Modules are not loaded if you have a Network Path in $env:PSModulePath which is not reachable

                            Integrated Modules are not loaded if you have a Network Path in $env:PSModulePath which is not reachable.

                            ##############
                            I have customized the PSModulePath:

                            PS C:\Users\username> ($env:PSModulePath).split(';')
                            C:\Users\username\Documents\WindowsPowerShell\Modules
                            C:\Program Files\WindowsPowerShell\Modules
                            C:\Windows\system32\WindowsPowerShell\v1.0\Modules\
                            c:\Program Files\Microsoft Security Client\MpProvider\
                            C:\Program Files\Microsoft Monitoring Agent\Agent\PowerShell\
                            \\my.domain\share\Modules\

                            ##############
                            If i try to execute e.g. Invoke-RestMethod

                            PS C:\Users\username> Invoke-RestMethod
                            Invoke-RestMethod : The 'Invoke-RestMethod' command was found in the module 'Microsoft.PowerShell.Utility', but the
                            module could not be loaded. For more information, run 'Import-Module Microsoft.PowerShell.Utility'.
                            At line:1 char:1
                            + Invoke-RestMethod
                            + ~~~~~~~~~~~~~~~~~
                            + CategoryInfo : ObjectNotFound: (Invoke-RestMethod:String) [], CommandNotFoundException
                            + FullyQualifiedErrorId : CouldNotAutoloadMatchingModule


                            PS C:\Users\username> Get-Command Invoke-RestMethod
                            Get-Command : The term…

                            5 votes
                            Sign in
                            Check!
                            (thinking…)
                            Reset
                            or sign in with
                            • facebook
                            • google
                              Password icon
                              Signed in as (Sign out)

                              We’ll send you updates on this idea

                              1 comment  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                            • Compress-Archive throws "OutOfMemory" on large folders

                              When using Compress-Archive on a very large folder, I am getting a "OutOfMemory Exception" error. This also happens when I pipe the folder from Get-ChildItem.

                              PS E:\> Compress-Archive -Path \\servername\downloads\foldername -DestinationPath e:\Foldername_bef
                              ore-12-01-2016.zip -CompressionLevel Optimal
                              Exception calling "Write" with "3" argument(s): "Exception of type 'System.OutOfMemoryException' was thrown."
                              At
                              C:\windows\system32\windowspowershell\v1.0\Modules\Microsoft.PowerShell.Archive\Microsoft.PowerShell.Archive.psm1:809
                              char:29
                              + ... $destStream.Write($buffer, 0, $numberOfBytesRead)
                              + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                              + CategoryInfo : NotSpecified: (:) [], MethodInvocationException
                              + FullyQualifiedErrorId : OutOfMemoryException

                              PS E:\> $Psversiontable

                              Name Value
                              ---- -----
                              PSVersion 5.0.10586.117
                              PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
                              BuildVersion 10.0.10586.117
                              CLRVersion 4.0.30319.34209
                              WSManStackVersion 3.0
                              PSRemotingProtocolVersion 2.3
                              SerializationVersion 1.1.0.1

                              PS E:\>

                              10 votes
                              Sign in
                              Check!
                              (thinking…)
                              Reset
                              or sign in with
                              • facebook
                              • google
                                Password icon
                                Signed in as (Sign out)

                                We’ll send you updates on this idea

                                3 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                              • Add support for TLS 1.2 (Invoke-WebRequest, Invoke-RestMethod)

                                Invoke-WebRequest and Invoke-RestMethod commands only support TLS 1.0 protocol. We need to have a native support for newer TLS (1.2) versions for modern web interfaces.

                                41 votes
                                Sign in
                                Check!
                                (thinking…)
                                Reset
                                or sign in with
                                • facebook
                                • google
                                  Password icon
                                  Signed in as (Sign out)

                                  We’ll send you updates on this idea

                                  6 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
                                    Signed in as (Sign out)

                                    We’ll send you updates on this idea

                                    1 comment  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                                  • Get-AuthenticodeSignature TimeStamperCertificate broken

                                    Problem:

                                    Get-AuthenticodeSignature does not return a time stamper certificate for files which have been time stamped with a valid time stamp server.

                                    Steps to reproduce:

                                    Using signtool.exe (from Windows SDK), view the signature info for signtool.exe. Verify that it has been time stamped, and that you can see the time stamper certificate.

                                    Using Get-AuthenticodeSignature, view the signature of signtool.exe. Notice that the TimeStamperCertificate field is blank.

                                    Consequences:

                                    Powershell will report any signed file as valid as long as the signature is valid, regardless of whether or not the timestamp is valid.

                                    Powershell version:
                                    Major Minor Build Revision
                                    ----- ----- -----…

                                    2 votes
                                    Sign in
                                    Check!
                                    (thinking…)
                                    Reset
                                    or sign in with
                                    • facebook
                                    • google
                                      Password icon
                                      Signed in as (Sign out)

                                      We’ll send you updates on this idea

                                      0 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                                    • ConvertTo-Json doesn't serialize simple objects properly

                                      # Given a simple array which has been boxed in a PSObject
                                      [PSObject]$o = @(@(Foo,1),@(Bar,2))

                                      # Calling ConvertTo-Json returns a weird pointless wrapper around it:
                                      convertto-json $o
                                      {
                                      "value": [
                                      [
                                      "Foo",
                                      1
                                      ],
                                      [
                                      "Bar",
                                      2
                                      ]
                                      ],
                                      "Count": 2
                                      }

                                      # Which completely breaks round-trip support
                                      ConvertFrom-Json (Convertto-Json $o)

                                      value Count
                                      ----- -----
                                      {Foo 1, Bar 2} 2

                                      16 votes
                                      Sign in
                                      Check!
                                      (thinking…)
                                      Reset
                                      or sign in with
                                      • facebook
                                      • google
                                        Password icon
                                        Signed in as (Sign out)

                                        We’ll send you updates on this idea

                                        survey  ·  14 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                                      • -IgnoreCertificateCheck or -SkipSslVerification parameter for [Invoke-WebRequest & Invoke-RestMethod]

                                        Invoke-WebRequest & Invoke-RestMethod need a parameter to easily skip/ignore checking for a valid certificate of https uri's. This could be required for a number of reasons such as development site only using self signed certificate while testing.

                                        9 votes
                                        Sign in
                                        Check!
                                        (thinking…)
                                        Reset
                                        or sign in with
                                        • facebook
                                        • google
                                          Password icon
                                          Signed in as (Sign out)

                                          We’ll send you updates on this idea

                                          survey  ·  1 comment  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                                        • Invoke-RestMethod and Invoke-WebRequest Encoding bug

                                          Invoke-RestMethod and Invoke-WebRequest Encoding bug

                                          This is 4 years old bug,from Invoke-RestMethod and Invoke-WebRequest was born.

                                          【Cause of the bug】
                                          Utf8 web page incorrectly identified as iso8859-1.
                                          Mistakenly convert THE! utf8("false ISO-8859-1") source string to utf8.
                                          There may be more encoding incorrectly identified,encoding incorrectly conversion errors.

                                          【bug with powershell version】
                                          all version
                                          powershell 5.0 with windows10 10586 :yes tested.

                                          【test code】
                                          Invoke-WebRequest -Uri 'http://www.msn.com'; # return chinese messy code
                                          (Invoke-WebRequest -Uri 'http://www.msn.com').BaseResponse.CharacterSet # utf8 web page,but return ISO-8859-1

                                          Invoke-RestMethod -Uri 'http://www.msn.com';

                                          【how to fix】
                                          convert string encoding.
                                          from utf8 to THE! "false ISO-8859-1"

                                          $utf8 =…

                                          15 votes
                                          Sign in
                                          Check!
                                          (thinking…)
                                          Reset
                                          or sign in with
                                          • facebook
                                          • google
                                            Password icon
                                            Signed in as (Sign out)

                                            We’ll send you updates on this idea

                                            2 comments  ·  Microsoft.PowerShell.* Modules  ·  Flag idea as inappropriate…  ·  Admin →
                                          ← Previous 1 3 4 5 9 10
                                          • Don't see your idea?

                                          Feedback and Knowledge Base