Will MS listen to user voice about PS ?

I hope MS powershell team to create a module about network tools , just like tcpdump and netcat in linux.

The first place I post my request is in the powershell core repo in github.
https://github.com/PowerShell/PowerShell/issues/8490

The send place I post this request is in MS Windows Server User voice web page:
https://windowsserver.uservoice.com/forums/301869-powershell/suggestions/37130554-add-tcpdump-equivalent-cmdlet-in-powershell

What I want to say is , does MS will care users’ voice ? Will it possible to reach MS PS team directly or how to reach them for my request ?
if my request get enough votes from users , will they do that?

Sorry , It is not a PS problem. maybe it should not appear here.

If I understand your request correct you just have to use WinDump. They say on their website:

WinDump is the Windows version of tcpdump ....

To answer your question, yes, the user voice is the best place to post features or enhancements you would like to see in the future releases of PowerShell. Like you said, if there are enough up votes or it is already in the pipeline, they are generally good at responding to your request and giving details. I believe Microsoft has a whole is moving in the user voice space and using GitHub for issues or bugs in the software.

Hope that helps answer your question.

pwshliquori

The PowerShell team are no longer accepting any kind of feature requests via UserVoice. UserVoice is only applicable to Windows PowerShell, which is completely feature-frozen.

Posting on the Github will reach the PowerShell team directly and is generally the best place to post, but don’t expect any new features to be brought back into Windows PowerShell – everything is going into PowerShell Core (6.0+) going forward, and only absolutely critical bugfixes are being backported, if any at all.

That said, the PowerShell team alone is pretty small and mightn’t be able to handle an entire networking module. In a lot of ways it can be more effective if a community member picks that up and maintains it as a separate module, but naturally that’s entirely up to whoever might choose to do that.

It’s great to have a ton of things built into PS itself, but currently the team is trying to move a little away from specialized functionality in PowerShell itself and split features out into modules that can be maintained and updated separately, to avoid the problem of lockstep-versioning the modules with PowerShell itself. Many of the core modules will still be maintained by the PS team, but historically there hasn’t been a great deal of in-depth networking built in to PS, so it might be a better ask to have it as a community module. It depends, I suppose. :slight_smile:

Also, if you’re wondering why Ilya closed out the issue so early: you framed the issue as a question, to which the answer was, “no, there isn’t.”

If you want to suggest that such a module / set of commands be added, you may want to be a bit more explicit as to:

  1. What commands you'd expect such a module to contain
  2. What functionality (not everyone is necessarily going to be intimately familiar with tcpdump, after all) it should cover
  3. The use cases for such a module in the administrative context the PS team generally tend to target.
And I'd also be sure to frame it as a suggestion rather than a question so that your intent is clear. If you want to file a new issue (referencing the old one might be a good idea) with that kind of idea, you're of course welcome to, I'm sure myself and several other folks would love to discuss it and figure out what's best to do with that going forward. :)

Tshark, or text only Wireshark, might be a way to go. There’s probably a Powershell module built around that, or the compiled windows version of tcpdump. https://www.wireshark.org/docs/man-pages/tshark.html

In fact, here’s a script that parses the output of tcpdump, to try to get the switch and port cdp info from a Cisco switch. It’s based on LDWin https://github.com/chall32/LDWin, which uses tcpdump and autoit.

$adapter = Get-WmiObject win32_networkadapter | where { $_.netconnectionid -and
  $_.netconnectionstatus -eq 2 } |
  select netconnectionid,productname,macaddress,guid,index
$guid = $adapter.guid

$result = .\tcpdump -i \Device\$guid -nn -v -s 1500 -c 1 '(ether[12:2]==0x88cc or ether[20:2]==0x2000)'
$result > .\tcpdump.out

$result | foreach {
  switch -regex ($_) {
    'Device-ID \(0x01\)'           { $switchname = ($_ -split "'")[1] }
    'Device-ID \(0x01\)'           { $switchname = ($_ -split "'")[1] }
    'Port-ID \(0x03\)'             { $switchport = ($_ -split "'")[1] }
    'VLAN ID \(0x0a\)'             { $vlan       = ($_ -split ':')[2].trim() }
    'port vlan id \(PVID\)'        { $vlan       = ($_ -split ':')[1].trim() }
    'System Name TLV \(5\)'        { $switchname = ($_ -split ':')[1].trim() }
    'Subtype Interface Name \(5\)' { $switchport = ($_ -split ':')[1].trim() }
    'Port Description TLV \(4\)'   { $switchport = ($_ -split ':')[1].trim() }
  }
}

[pscustomobject]@{
  MacAddress = $adapter.macaddress
  SwitchPort = $switchport
  VLAN = $vlan
  SwitchName = $switchname
}

Sometimes I just use the network button in sysinternals process monitor.

In regard to netcat there is Test-NetConnection already built-in (think it’s from version 4 of PS).
Maybe not all features like using it as a UDP connection tester (since it can act as a client and listener).
But covers most of the basic needs.

Do 5.1 bugs go to uservoice?

PS C:\Users\admin> write-output 'line one' | set-content file.txt  # ansi
PS C:\Users\admin> write-output 'line two' >> file.txt             # >> always writes unicode like out-file
PS C:\Users\admin> get-content file.txt                            # unicode line has extra nulls
line one
l i n e   t w o

Yes, but they aren’t doing any bugfixes for 5.1 anymore. That’s already fixed in PS Core, btw.

That issue is due to Windows PowerShell’s default encoding for Out-File, which is UTF16LE as you mention. Get-Content, on the other hand, uses UTF8 or ANSI depending on other settings I think.

If you’re using Windows PowerShell, the only thing you can do with minor bugs like that is work around them; I’ve spoken with the team on the Github a few times, and the firm word from Steve is that they are not doing anything further with 5.1 unless it’s extremely critical to security or something similarly serious.