missed the capitalized ones.

This commit is contained in:
christos 2020-06-15 02:29:44 +00:00
parent 2f0bfbf344
commit a51582d48a
12 changed files with 39 additions and 39 deletions

View File

@ -1,9 +1,9 @@
# $NetBSD: Makefile.inc,v 1.1.1.1 2020/06/15 01:52:52 christos Exp $
# $NetBSD: Makefile.inc,v 1.2 2020/06/15 02:29:44 christos Exp $
WARNS=6
.if !defined(LIB)
LDADD+= -lblocklist
DPADD+= ${LIBBLACKLIST}
DPADD+= ${LIBBLOCKLIST}
.endif
CPPFLAGS+= -I${.CURDIR}/../include
CPPFLAGS+=-DHAVE_STRUCT_SOCKADDR_SA_LEN -DHAVE_UTIL_H -DHAVE_DB_H

View File

@ -1,4 +1,4 @@
.\" $NetBSD: blocklistctl.8,v 1.1.1.1 2020/06/15 01:52:52 christos Exp $
.\" $NetBSD: blocklistctl.8,v 1.2 2020/06/15 02:29:44 christos Exp $
.\"
.\" Copyright (c) 2015 The NetBSD Foundation, Inc.
.\" All rights reserved.
@ -28,7 +28,7 @@
.\" POSSIBILITY OF SUCH DAMAGE.
.\"
.Dd June 7, 2016
.Dt BLACKLISTCTL 8
.Dt BLOCKLISTCTL 8
.Os
.Sh NAME
.Nm blocklistctl

View File

@ -1,4 +1,4 @@
.\" $NetBSD: blocklistd.8,v 1.1.1.1 2020/06/15 01:52:53 christos Exp $
.\" $NetBSD: blocklistd.8,v 1.2 2020/06/15 02:29:44 christos Exp $
.\"
.\" Copyright (c) 2015 The NetBSD Foundation, Inc.
.\" All rights reserved.
@ -28,7 +28,7 @@
.\" POSSIBILITY OF SUCH DAMAGE.
.\"
.Dd April 21, 2020
.Dt BLACKLISTD 8
.Dt BLOCKLISTD 8
.Os
.Sh NAME
.Nm blocklistd

View File

@ -1,4 +1,4 @@
.\" $NetBSD: blocklistd.conf.5,v 1.1.1.1 2020/06/15 01:52:53 christos Exp $
.\" $NetBSD: blocklistd.conf.5,v 1.2 2020/06/15 02:29:44 christos Exp $
.\"
.\" Copyright (c) 2015 The NetBSD Foundation, Inc.
.\" All rights reserved.
@ -28,7 +28,7 @@
.\" POSSIBILITY OF SUCH DAMAGE.
.\"
.Dd May 18, 2020
.Dt BLACKLISTD.CONF 5
.Dt BLOCKLISTD.CONF 5
.Os
.Sh NAME
.Nm blocklistd.conf

View File

@ -43,7 +43,7 @@ diff -u -p -u -r1.63 Makefile
+SRCS+= pfilter.c
+LDADD+= -lblocklist
+DPADD+= ${LIBBLACKLIST}
+DPADD+= ${LIBBLOCKLIST}
+
.if defined(NO_INTERNAL_LS)
CPPFLAGS+=-DNO_INTERNAL_LS

View File

@ -64,7 +64,7 @@ diff -u -u -r1.8 Makefile
update.c xfrout.c zoneconf.c ${SRCS_UNIX}
+LDADD+=-lblocklist
+DPADD+=${LIBBLACKLIST}
+DPADD+=${LIBBLOCKLIST}
.include <bsd.prog.mk>
Index: dist/bin/named/client.c
===================================================================

View File

@ -74,7 +74,7 @@ diff -u -r1.6 Makefile
DPADD+= ${LIBPMASTER} ${LIBPMILTER} ${LIBPGLOBAL} ${LIBPDNS} ${LIBPXSASL}
LDADD+= ${LIBPMASTER} ${LIBPMILTER} ${LIBPGLOBAL} ${LIBPDNS} ${LIBPXSASL}
+DPADD+= ${LIBBLACKLIST}
+DPADD+= ${LIBBLOCKLIST}
+LDADD+= -lblocklist
+
DPADD+= ${LIBPTLS} ${LIBSSL} ${LIBCRYPTO}

View File

@ -5,7 +5,7 @@
FTPWHO_OBJS=ftpwho.o scoreboard.o misc.o
BUILD_FTPWHO_OBJS=utils/ftpwho.o utils/scoreboard.o utils/misc.o
+
+CPPFLAGS+=-DHAVE_BLACKLIST
+CPPFLAGS+=-DHAVE_BLOCKLIST
+LIBS+=-lblocklist
+OBJS+= pfilter.o
+BUILD_OBJS+= src/pfilter.o
@ -84,7 +84,7 @@
+#include "pfilter.h"
+#include "conf.h"
+#include "privs.h"
+#ifdef HAVE_BLACKLIST
+#ifdef HAVE_BLOCKLIST
+#include <blocklist.h>
+#endif
+
@ -93,7 +93,7 @@
+void
+pfilter_init(void)
+{
+#ifdef HAVE_BLACKLIST
+#ifdef HAVE_BLOCKLIST
+ if (blstate == NULL)
+ blstate = blocklist_open();
+#endif
@ -102,7 +102,7 @@
+void
+pfilter_notify(int a)
+{
+#ifdef HAVE_BLACKLIST
+#ifdef HAVE_BLOCKLIST
+ conn_t *c = session.c;
+ int fd;
+

View File

@ -61,7 +61,7 @@ diff -u -u -r1.10 Makefile
DPADD+= ${LIBWRAP}
+
+LDADD+= -lblocklist
+DPADD+= ${LIBBLACKLIST}
+DPADD+= ${LIBBLOCKLIST}
diff -ru openssh-7.7p1/auth-pam.c dist/auth-pam.c
--- openssh-7.7p1/auth-pam.c 2018-04-02 01:38:28.000000000 -0400
+++ dist/auth-pam.c 2018-05-23 11:56:22.206661484 -0400

View File

@ -1,4 +1,4 @@
/* $NetBSD: blocklist.h,v 1.1.1.1 2020/06/15 01:52:53 christos Exp $ */
/* $NetBSD: blocklist.h,v 1.2 2020/06/15 02:29:45 christos Exp $ */
/*-
* Copyright (c) 2014 The NetBSD Foundation, Inc.
@ -28,8 +28,8 @@
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef _BLACKLIST_H
#define _BLACKLIST_H
#ifndef _BLOCKLIST_H
#define _BLOCKLIST_H
#include <sys/socket.h>
@ -44,12 +44,12 @@ int blocklist_sa_r(struct blocklist *, int, int,
__END_DECLS
/* action values for user applications */
#define BLACKLIST_API_ENUM 1
#define BLOCKLIST_API_ENUM 1
enum {
BLACKLIST_AUTH_OK = 0,
BLACKLIST_AUTH_FAIL,
BLACKLIST_ABUSIVE_BEHAVIOR,
BLACKLIST_BAD_USER
BLOCKLIST_AUTH_OK = 0,
BLOCKLIST_AUTH_FAIL,
BLOCKLIST_ABUSIVE_BEHAVIOR,
BLOCKLIST_BAD_USER
};
#endif /* _BLACKLIST_H */
#endif /* _BLOCKLIST_H */

View File

@ -1,4 +1,4 @@
/* $NetBSD: blocklist.c,v 1.1.1.1 2020/06/15 01:52:53 christos Exp $ */
/* $NetBSD: blocklist.c,v 1.2 2020/06/15 02:29:45 christos Exp $ */
/*-
* Copyright (c) 2014 The NetBSD Foundation, Inc.
@ -33,7 +33,7 @@
#endif
#include <sys/cdefs.h>
__RCSID("$NetBSD: blocklist.c,v 1.1.1.1 2020/06/15 01:52:53 christos Exp $");
__RCSID("$NetBSD: blocklist.c,v 1.2 2020/06/15 02:29:45 christos Exp $");
#include <stdio.h>
#include <bl.h>
@ -65,16 +65,16 @@ blocklist_sa_r(struct blocklist *bl, int action, int rfd,
/* internal values are not the same as user application values */
switch (action) {
case BLACKLIST_AUTH_FAIL:
case BLOCKLIST_AUTH_FAIL:
internal_action = BL_ADD;
break;
case BLACKLIST_AUTH_OK:
case BLOCKLIST_AUTH_OK:
internal_action = BL_DELETE;
break;
case BLACKLIST_ABUSIVE_BEHAVIOR:
case BLOCKLIST_ABUSIVE_BEHAVIOR:
internal_action = BL_ABUSE;
break;
case BLACKLIST_BAD_USER:
case BLOCKLIST_BAD_USER:
internal_action = BL_BADUSER;
break;
default:

View File

@ -1,4 +1,4 @@
.\" $NetBSD: libblocklist.3,v 1.1.1.1 2020/06/15 01:52:53 christos Exp $
.\" $NetBSD: libblocklist.3,v 1.2 2020/06/15 02:29:45 christos Exp $
.\"
.\" Copyright (c) 2015 The NetBSD Foundation, Inc.
.\" All rights reserved.
@ -28,7 +28,7 @@
.\" POSSIBILITY OF SUCH DAMAGE.
.\"
.Dd March 30, 2020
.Dt LIBBLACKLIST 3
.Dt LIBBLOCKLIST 3
.Os
.Sh NAME
.Nm blocklist_open ,
@ -89,17 +89,17 @@ argument.
The
.Ar action
parameter can take these values:
.Bl -tag -width ".Va BLACKLIST_ABUSIVE_BEHAVIOR"
.It Va BLACKLIST_AUTH_FAIL
.Bl -tag -width ".Va BLOCKLIST_ABUSIVE_BEHAVIOR"
.It Va BLOCKLIST_AUTH_FAIL
There was an unsuccessful authentication attempt.
.It Va BLACKLIST_AUTH_OK
.It Va BLOCKLIST_AUTH_OK
A user successfully authenticated.
.It Va BLACKLIST_ABUSIVE_BEHAVIOR
.It Va BLOCKLIST_ABUSIVE_BEHAVIOR
The sending daemon has detected abusive behavior
from the remote system.
The remote address should
be blocked as soon as possible.
.It Va BLACKLIST_BAD_USER
.It Va BLOCKLIST_BAD_USER
The sending daemon has determined the username
presented for authentication is invalid.
The
@ -108,7 +108,7 @@ daemon compares the username to a configured list of forbidden
usernames and
blocks the address immediately if a forbidden username matches.
(The
.Ar BLACKLIST_BAD_USER
.Ar BLOCKLIST_BAD_USER
support is not currently available.)
.El
.Pp