move all lsof to formmated output (-F)

This commit is contained in:
Jeremy W. Chalfant 2016-01-06 13:14:36 -06:00 committed by Christoph Hartmann
parent 515cb5a3a7
commit a2ea1da6e3
2 changed files with 1 additions and 7 deletions

View file

@ -137,10 +137,8 @@ class MockLoader
'/sbin/sysctl -q -n net.ipv4.conf.all.forwarding' => cmd.call('sbin_sysctl'),
# ports on windows
'Get-NetTCPConnection | Select-Object -Property State, Caption, Description, LocalAddress, LocalPort, RemoteAddress, RemotePort, DisplayName, Status | ConvertTo-Json' => cmd.call('get-net-tcpconnection'),
# lsof formatted list of ports (should quite cross platform)
# lsof formatted list of ports (should be quite cross platform)
'lsof -nP -i -FpctPn' => cmd.call('lsof-nP-i-FpctPn'),
# ports on mac
'lsof -nP -iTCP -iUDP -sTCP:LISTEN' => cmd.call('lsof-np-itcp'),
# ports on linux
'netstat -tulpen' => cmd.call('netstat-tulpen'),
# ports on freebsd

View file

@ -1,4 +0,0 @@
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
UserEvent 697 chartmann 4u IPv4 0xf0f511b94b566c77 0t0 UDP *:*
VBoxHeadl 6835 chartmann 21u IPv4 0xf0f511b96bd8db37 0t0 TCP 127.0.0.1:2022 (LISTEN)
VBoxHeadl 6835 chartmann 23u IPv4 0xf0f511b94cc8c5d7 0t0 UDP *:61197