strace/xlat/tcp_states.in
Dmitry V. Levin 8e9c9e4631 netlink: add a basic socket diag parser of AF_UNIX messages
* defs.h (socktypes): New xlat prototype.
* linux/unix_diag.h (UDIAG_SHOW_VFS, UDIAG_SHOW_ICONS, UDIAG_SHOW_RQLEN,
UDIAG_SHOW_MEMINFO): New macros.
* netlink_sock_diag.c: Include <sys/socket.h>, <linux/netlink.h>,
<linux/unix_diag.h>, "xlat/tcp_states.h", "xlat/tcp_state_flags.h",
and "xlat/unix_diag_show.h".
(decode_unix_diag_req, decode_unix_diag_msg): New functions.
(netlink_diag_decoder_t): New typedef.
(diag_decoders): New array.
(decode_netlink_sock_diag): Use it.
* xlat/tcp_state_flags.in: New file.
* xlat/tcp_states.in: Likewise.
* xlat/unix_diag_show.in: Likewise.

Co-authored-by: Fabien Siron <fabien.siron@epita.fr>
Co-authored-by: JingPiao Chen <chenjingpiao@gmail.com>
2017-06-15 00:30:47 +00:00

13 lines
200 B
Plaintext

TCP_ESTABLISHED 1
TCP_SYN_SENT 2
TCP_SYN_RECV 3
TCP_FIN_WAIT1 4
TCP_FIN_WAIT2 5
TCP_TIME_WAIT 6
TCP_CLOSE 7
TCP_CLOSE_WAIT 8
TCP_LAST_ACK 9
TCP_LISTEN 10
TCP_CLOSING 11
TCP_NEW_SYN_RECV 12