lstf

The aggregated TCP connections printer in Linux

  • 所有者: yuuki/lstf
  • 平台:
  • 許可證: MIT License
  • 分類:
  • 主題:
  • 喜歡:
    0
      比較:

Github星跟蹤圖

lstf

Build Status
Latest Version
Go Report Card
License

lstf prints host flows (aggregated network connection flows to the same source or destination ports) by Linux netlink and enables you to simply grasp the network relationship between localhost and other hosts.

friend: yuuki/lsconntrack

Features

  • Distinction of active open and passive open
  • Print also the number of connections of each flows (the absolute values are meaningless)
  • Go portability
  • JSON support
  • TCP support only

Installation

Download binary from GitHub Releases

https://github.com/yuuki/lstf/releases

How to use

HTTP requests --> Web:80 --> MySQL:3306

$ lstf -n
Local Address:Port   <-->   Peer Address:Port     Connections
10.0.1.9:many        -->    10.0.1.10:3306        22
10.0.1.9:many        -->    10.0.1.11:3306        14
10.0.2.10:22         <--    192.168.10.10:many    1
10.0.1.9:80          <--    10.0.2.13:many        120
10.0.1.9:80          <--    10.0.2.14:many        202
  • --> indicates active open
  • <-- indicates passive open

Sort flows by the number of connection.

$ lstf -n, sort -nrk4

JSON format

$ lstf --json, jq -r -M '.'
[
  {
    "direction": "active",
    "local": {
      "name", "app01.local",
      "addr": "10.0.1.9",
      "port": "many"
    },
    "peer": {
      "name", "db01.local",
      "addr": "10.0.100.1",
      "port": "3306"
    },
    "connections": 20
  },
  {
    "direction": "passive",
    "local": {
      "name", "app01.local",
      "addr": "10.0.1.9",
      "port": "80"
    },
    "peer": {
      "name", "web01.local",
      "addr": "10.0.200.1",
      "port": "many"
    },
    "connections": 27
  },
  ...
]

License

[MIT][license]

Author

yuuki

主要指標

概覽
名稱與所有者yuuki/lstf
主編程語言Go
編程語言Makefile (語言數: 4)
平台
許可證MIT License
所有者活动
創建於2018-03-04 13:24:35
推送於2021-03-14 10:22:32
最后一次提交2021-03-14 19:22:24
發布數17
最新版本名稱v0.7.2 (發布於 )
第一版名稱v0.1.0 (發布於 )
用户参与
星數160
關注者數6
派生數11
提交數190
已啟用問題?
問題數1
打開的問題數0
拉請求數30
打開的拉請求數0
關閉的拉請求數0
项目设置
已啟用Wiki?
已存檔?
是復刻?
已鎖定?
是鏡像?
是私有?