1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-02-01 10:59:55 +00:00

nsping 0.8 is a tool for 'pinging' DNS servers.

Obtained from:	OpenBSD
This commit is contained in:
Kris Kennaway 2000-03-05 09:38:56 +00:00
parent cf3d05cb92
commit 95ab1a6bba
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=26557
15 changed files with 161 additions and 0 deletions

23
dns/nsping/Makefile Normal file
View File

@ -0,0 +1,23 @@
# New ports collection makefile for: nsping
# Version required: 0.8
# Date created: 04 March 2000
# Whom: Kris Kennaway <kris@FreeBSD.org>
#
# $FreeBSD$
DISTNAME= nsping
PKGNAME= nsping-0.8
CATEGORIES= net
MASTER_SITES= http://www.enteract.com/~tqbf/
MAINTAINER= kris@FreeBSD.org
WRKSRC= ${WRKDIR}/${PKGNAME}
MAN8= nsping.8
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/nsping ${PREFIX}/sbin
${INSTALL_DATA} ${WRKSRC}/nsping.8 ${PREFIX}/man/man8
.include <bsd.port.mk>

3
dns/nsping/distinfo Normal file
View File

@ -0,0 +1,3 @@
MD5 (nsping.tar.gz) = 64785a50eb065a9b28ee33ec8c1ccab2
RMD160 (nsping.tar.gz) = 6f64f04a3b97c04ab978dcd170e0f9f590f2952a
SHA1 (nsping.tar.gz) = 3e85186a1db7566728426b13c5683afe5ed96752

17
dns/nsping/files/patch-aa Normal file
View File

@ -0,0 +1,17 @@
--- Makefile.orig Mon Nov 24 04:56:28 1997
+++ Makefile Fri Nov 12 15:53:26 1999
@@ -1,4 +1,4 @@
-CFLAGS= -g
+#CFLAGS= -g
#Solaris
#CFLAGS= -g -Dsys5
LDFLAGS=
@@ -10,6 +10,8 @@
OBJS= nsping.o dns-lib.o dns-rr.o
SRCS= nsping.c dns-lib.c dns-rr.c
HEADERS= nsping.h dns-lib.h dns-rr.h
+
+all: ${TARGET}
${TARGET} : ${OBJS}
${CC} ${CFLAGS} -o ${TARGET} ${OBJS} ${LDFLAGS} ${LIBS}

28
dns/nsping/files/patch-ab Normal file
View File

@ -0,0 +1,28 @@
--- nsping.c.orig Fri Nov 12 15:30:42 1999
+++ nsping.c Fri Nov 12 15:44:06 1999
@@ -189,10 +189,14 @@
int guess_zone() {
char lhn[MAXDNAME];
+ struct hostent *hp;
char *cp;
if(gethostname(lhn, MAXDNAME) < 0)
return(0);
+ if((hp = gethostbyname(lhn)) == NULL)
+ return(0);
+ strlcpy(lhn, hp->h_name, sizeof(lhn));
cp = strchr(lhn, '.');
if(!cp || !(*(++cp)))
@@ -679,9 +683,7 @@
/* -------------------------------------------------------------------------- */
void usage() {
- fprintf(stderr, "nsping [ -z <zone> | -h <hostname> ] -p <port> -t <timeout>\n"
- "\t\t-a <local address> -P <local port>\n"
- "\t\t-T <type> <-r | -R, recurse?>\n");
+ fprintf(stderr, "Usage: nsping [-dR] [-c count] [-z zone | -h hostname] [-t timeout] [-p dport] [-P sport] [-a saddr] [-T querytype]\n");
return;
}

1
dns/nsping/pkg-comment Normal file
View File

@ -0,0 +1 @@
DNS "ping"

7
dns/nsping/pkg-descr Normal file
View File

@ -0,0 +1,7 @@
from nsping.8:
Nsping uses DNS queries to monitor reachability and operation of name-
servers, as well as the latency of DNS queries. It does this by sending
random recursive DNS queries to the nameserver (avoiding the effects of
DNS caching) and measuring the amount of time between the sending of the
query and the receipt of the response packet.

1
dns/nsping/pkg-plist Normal file
View File

@ -0,0 +1 @@
sbin/nsping

View File

@ -124,6 +124,7 @@
SUBDIR += nocol
SUBDIR += ns
SUBDIR += nslint
SUBDIR += nsping
SUBDIR += nstreams
SUBDIR += ntimelord
SUBDIR += ntop

23
net/nsping/Makefile Normal file
View File

@ -0,0 +1,23 @@
# New ports collection makefile for: nsping
# Version required: 0.8
# Date created: 04 March 2000
# Whom: Kris Kennaway <kris@FreeBSD.org>
#
# $FreeBSD$
DISTNAME= nsping
PKGNAME= nsping-0.8
CATEGORIES= net
MASTER_SITES= http://www.enteract.com/~tqbf/
MAINTAINER= kris@FreeBSD.org
WRKSRC= ${WRKDIR}/${PKGNAME}
MAN8= nsping.8
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/nsping ${PREFIX}/sbin
${INSTALL_DATA} ${WRKSRC}/nsping.8 ${PREFIX}/man/man8
.include <bsd.port.mk>

3
net/nsping/distinfo Normal file
View File

@ -0,0 +1,3 @@
MD5 (nsping.tar.gz) = 64785a50eb065a9b28ee33ec8c1ccab2
RMD160 (nsping.tar.gz) = 6f64f04a3b97c04ab978dcd170e0f9f590f2952a
SHA1 (nsping.tar.gz) = 3e85186a1db7566728426b13c5683afe5ed96752

17
net/nsping/files/patch-aa Normal file
View File

@ -0,0 +1,17 @@
--- Makefile.orig Mon Nov 24 04:56:28 1997
+++ Makefile Fri Nov 12 15:53:26 1999
@@ -1,4 +1,4 @@
-CFLAGS= -g
+#CFLAGS= -g
#Solaris
#CFLAGS= -g -Dsys5
LDFLAGS=
@@ -10,6 +10,8 @@
OBJS= nsping.o dns-lib.o dns-rr.o
SRCS= nsping.c dns-lib.c dns-rr.c
HEADERS= nsping.h dns-lib.h dns-rr.h
+
+all: ${TARGET}
${TARGET} : ${OBJS}
${CC} ${CFLAGS} -o ${TARGET} ${OBJS} ${LDFLAGS} ${LIBS}

28
net/nsping/files/patch-ab Normal file
View File

@ -0,0 +1,28 @@
--- nsping.c.orig Fri Nov 12 15:30:42 1999
+++ nsping.c Fri Nov 12 15:44:06 1999
@@ -189,10 +189,14 @@
int guess_zone() {
char lhn[MAXDNAME];
+ struct hostent *hp;
char *cp;
if(gethostname(lhn, MAXDNAME) < 0)
return(0);
+ if((hp = gethostbyname(lhn)) == NULL)
+ return(0);
+ strlcpy(lhn, hp->h_name, sizeof(lhn));
cp = strchr(lhn, '.');
if(!cp || !(*(++cp)))
@@ -679,9 +683,7 @@
/* -------------------------------------------------------------------------- */
void usage() {
- fprintf(stderr, "nsping [ -z <zone> | -h <hostname> ] -p <port> -t <timeout>\n"
- "\t\t-a <local address> -P <local port>\n"
- "\t\t-T <type> <-r | -R, recurse?>\n");
+ fprintf(stderr, "Usage: nsping [-dR] [-c count] [-z zone | -h hostname] [-t timeout] [-p dport] [-P sport] [-a saddr] [-T querytype]\n");
return;
}

1
net/nsping/pkg-comment Normal file
View File

@ -0,0 +1 @@
DNS "ping"

7
net/nsping/pkg-descr Normal file
View File

@ -0,0 +1,7 @@
from nsping.8:
Nsping uses DNS queries to monitor reachability and operation of name-
servers, as well as the latency of DNS queries. It does this by sending
random recursive DNS queries to the nameserver (avoiding the effects of
DNS caching) and measuring the amount of time between the sending of the
query and the receipt of the response packet.

1
net/nsping/pkg-plist Normal file
View File

@ -0,0 +1 @@
sbin/nsping