mirror of
https://git.FreeBSD.org/ports.git
synced 2024-10-20 20:09:11 +00:00
Tcplist makes a list of tcp connections to and from the local machine,
displaying the user name associated with the local end, and making use of Ident services if available to determine the "user" at the other end. Tcplist uses LSOF to do its low level work on 4.4BSD machines.
This commit is contained in:
parent
69ac7b4b06
commit
07df187a7a
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=6284
26
sysutils/tcplist/Makefile
Normal file
26
sysutils/tcplist/Makefile
Normal file
@ -0,0 +1,26 @@
|
||||
# ex:ts=8
|
||||
# Ports collection makefile for: tcplist
|
||||
# Version required: 2.1
|
||||
# Date created: Mon Apr 14, 1997
|
||||
# Whom: David O'Brien (obrien@FreeBSD.org)
|
||||
#
|
||||
# $Id: Makefile,v 1.2 1997/01/25 18:08:40 obrien Exp $
|
||||
#
|
||||
|
||||
DISTNAME= tcplist-2.1
|
||||
CATEGORIES= sysutils net
|
||||
MASTER_SITES= ftp://ftp.cdf.toronto.edu/pub/tcplist/
|
||||
EXTRACT_SUFX= .shar.gz
|
||||
|
||||
MAINTAINER= obrien@NUXI.com
|
||||
|
||||
RUN_DEPENDS= lsof:${PORTSDIR}/sysutils/lsof
|
||||
|
||||
EXTRACT_CMD= zcat
|
||||
EXTRACT_BEFORE_ARGS=
|
||||
EXTRACT_AFTER_ARGS= |sh
|
||||
NO_WRKSUBDIR= yes
|
||||
INSTALL_TARGET= install install.man
|
||||
MAN1= tcplist.1
|
||||
|
||||
.include <bsd.port.mk>
|
1
sysutils/tcplist/distinfo
Normal file
1
sysutils/tcplist/distinfo
Normal file
@ -0,0 +1 @@
|
||||
MD5 (tcplist-2.1.shar.gz) = 1563b70141821d06bc17e5e3c2856b87
|
49
sysutils/tcplist/files/patch-01
Normal file
49
sysutils/tcplist/files/patch-01
Normal file
@ -0,0 +1,49 @@
|
||||
--- Makefile.orig Mon Apr 14 18:06:02 1997
|
||||
+++ Makefile Mon Apr 14 18:08:48 1997
|
||||
@@ -1,14 +1,16 @@
|
||||
# Compiler: eg. cc or gcc
|
||||
CC = cc
|
||||
|
||||
+#PREFIX= /local
|
||||
+
|
||||
# Directory to install tcplist executable
|
||||
-BINDIR = /local/bin
|
||||
+BINDIR = $(PREFIX)/bin
|
||||
|
||||
# Directory to install tcplist man page
|
||||
-MANDIR = /local/man/man1
|
||||
+MANDIR = $(PREFIX)/man/man1
|
||||
|
||||
# Location of NOIDENT file
|
||||
-NOIDENT = /etc/hosts.noident
|
||||
+NOIDENT = $(PREFIX)/etc/hosts.noident
|
||||
|
||||
# Owner of tcplist executable
|
||||
OWNER = root
|
||||
@@ -45,18 +47,18 @@
|
||||
#
|
||||
# Solaris 2.x (using LSOF):
|
||||
#
|
||||
-LIBRARIES = -lsocket -lnsl
|
||||
-DEFS = -DLSOF
|
||||
-MODE = 755
|
||||
-GROUP = staff
|
||||
+#LIBRARIES = -lsocket -lnsl
|
||||
+#DEFS = -DLSOF
|
||||
+#MODE = 755
|
||||
+#GROUP = staff
|
||||
|
||||
#
|
||||
# Generic LSOF:
|
||||
#
|
||||
-# LIBRARIES =
|
||||
-# DEFS = -DLSOF
|
||||
-# MODE = 755
|
||||
-# GROUP = staff
|
||||
+ LIBRARIES =
|
||||
+ DEFS = -DLSOF
|
||||
+ MODE = 755
|
||||
+ GROUP = staff
|
||||
#
|
||||
|
||||
# If you're using an old version of lsof, uncomment this:
|
28
sysutils/tcplist/files/patch-02
Normal file
28
sysutils/tcplist/files/patch-02
Normal file
@ -0,0 +1,28 @@
|
||||
--- tcplist.c.orig Tue Apr 15 00:28:29 1997
|
||||
+++ tcplist.c Tue Apr 15 00:31:40 1997
|
||||
@@ -37,6 +37,10 @@
|
||||
#include <arpa/inet.h>
|
||||
#include <netdb.h>
|
||||
|
||||
+#if ((defined(__unix__) || defined(unix)) && !defined(USG))
|
||||
+#include <sys/param.h>
|
||||
+#endif
|
||||
+
|
||||
#include "utils.h"
|
||||
#include "tcplist.h"
|
||||
|
||||
@@ -346,10 +350,14 @@
|
||||
|
||||
if(verbose) printf("Connecting to remote hosts.\n");
|
||||
|
||||
+#if (defined(BSD) && (BSD >= 199103))
|
||||
+ maxfd=getdtablesize(); /* could also use getrlimit(2) here... */
|
||||
+#else
|
||||
if(0>(maxfd=ulimit(4,0l))){
|
||||
perror("ulimit");
|
||||
exit(2);
|
||||
}
|
||||
+#endif
|
||||
|
||||
/* waltz through the connections in the hostlist, setting idents */
|
||||
/* to NULL */
|
1
sysutils/tcplist/pkg-comment
Normal file
1
sysutils/tcplist/pkg-comment
Normal file
@ -0,0 +1 @@
|
||||
lists tcp connections to/from the local machine (+username on both sides)
|
7
sysutils/tcplist/pkg-descr
Normal file
7
sysutils/tcplist/pkg-descr
Normal file
@ -0,0 +1,7 @@
|
||||
Tcplist makes a list of tcp connections to and from the local machine,
|
||||
displaying the user name associated with the local end, and making use of
|
||||
Ident services if available to determine the "user" at the other end.
|
||||
|
||||
Tcplist uses LSOF to do its low level work on 4.4BSD machines.
|
||||
|
||||
-- David (obrien@FreeBSD.org)
|
2
sysutils/tcplist/pkg-plist
Normal file
2
sysutils/tcplist/pkg-plist
Normal file
@ -0,0 +1,2 @@
|
||||
bin/tcplist
|
||||
man/man1/tcplist.1.gz
|
Loading…
Reference in New Issue
Block a user