win-netstat:Golang中的Windows netstat实现

时间:2021-05-02 11:31:41
【文件属性】:
文件名称:win-netstat:Golang中的Windows netstat实现
文件大小:8KB
文件格式:ZIP
更新时间:2021-05-02 11:31:41
windows golang netstat Go win-netstat Golang中的Windows netstat实现。 入门 package main import ( "fmt" "log" "github.com/pytimer/win-netstat" ) func tcp4 () { conns , err := winnetstat . Connections ( "tcp4" ) if err != nil { log . Fatal ( err ) } for _ , conn := range conns { fmt . Printf ( "%s:%d \t %d \t %s \n " , conn . LocalAddr , conn . LocalPort , conn . OwningPid , conn . State ) } } func tcp4WithPid ( pid in
【文件预览】:
win-netstat-master
----.gitignore(275B)
----netstat.go(2KB)
----LICENSE(1KB)
----tcp.go(5KB)
----examples()
--------main.go(2KB)
----README.md(922B)
----iphlpapi.go(2KB)
----types.go(3KB)
----udp.go(2KB)
----common.go(819B)

网友评论