Thread View: news.software.nntp
1 messages
1 total messages
Started by Sean Donelan
Tue, 30 Jul 1996 00:00
Posting administrative control messages and NNRPD
Author: Sean Donelan
Date: Tue, 30 Jul 1996 00:00
Date: Tue, 30 Jul 1996 00:00
100 lines
4814 bytes
4814 bytes
After having a few local users post various control messages without
understanding the side effects of their actions, I did some digging
in the INND code. I found NNRPD and INEWS had different checks on
postings. Nnrpd has no limits on posting administrative control
messages such as sendsys, newgroup, checkgroups, etc. Inews required
the user to be a member of the news gid before allowing posts of
administrative control messages.
I've created a patch for NNRPD which refuses posts of most administrative
control messages with the same error inews gives. Cancels, ihaves, and
sendmes are the exceptions. Cancels because normal users have a legitimate
reason to use them. Ihave and sendmes because I don't want to break sites
which might still using them with UUCP, and because they tend to be used
by automated programs which are more difficult to change.
News administrators can still create administrative control messages
using rnews, see NEWSBIN/makegroup program for an example. But this
patch does (slightly) raise the knowledge level required to cause havoc.
And limits the damage that can be done by users with only post access
to news servers.
*** config/config.dist.orig Tue Jul 30 16:09:36 1996
--- config/config.dist Tue Jul 30 16:09:42 1996
***************
*** 411,416 ****
--- 411,419 ----
## Strip Sender from posts that didn't authenticate? Pick DO or DONT.
#### =()<NNRP_AUTH_SENDER @<NNRP_AUTH_SENDER>@>()=
NNRP_AUTH_SENDER DONT
+ ## Allow posting of administrative Control messages? Pick DO or DONT.
+ #### =()<ALLOW_CONTROL_POSTS @<ALLOW_CONTROL_POSTS>@>()=
+ ALLOW_CONTROL_POSTS DONT
## How many read/write failures until channel is put to sleep or closed?
#### =()<BAD_IO_COUNT @<BAD_IO_COUNT>@>()=
BAD_IO_COUNT 5
*** config/config.data.orig Tue Jul 30 16:16:31 1996
--- config/config.data Tue Jul 30 16:04:16 1996
***************
*** 411,416 ****
--- 411,419 ----
## Strip Sender from posts that didn't authenticate? Pick DO or DONT.
#### =()<NNRP_AUTH_SENDER @<NNRP_AUTH_SENDER>@>()=
NNRP_AUTH_SENDER DONT
+ ## Allow posting of administrative Control messages? Pick DO or DONT.
+ #### =()<ALLOW_CONTROL_POSTS @<ALLOW_CONTROL_POSTS>@>()=
+ ALLOW_CONTROL_POSTS DONT
## How many read/write failures until channel is put to sleep or closed?
#### =()<BAD_IO_COUNT @<BAD_IO_COUNT>@>()=
BAD_IO_COUNT 5
*** nnrpd/post.c.orig Mon Jul 29 04:07:52 1996
--- nnrpd/post.c Tue Jul 30 16:20:28 1996
***************
*** 218,225 ****
}
else if (EQ(ctrl, "sendsys") || EQ(ctrl, "senduuname")
|| EQ(ctrl, "version") || EQ(ctrl, "checkgroups")
! || EQ(ctrl, "ihave") || EQ(ctrl, "sendme")
! || EQ(ctrl, "newgroup") || EQ(ctrl, "rmgroup"))
/* SUPPRESS 530 *//* Empty body for statement */
;
else {
--- 218,233 ----
}
else if (EQ(ctrl, "sendsys") || EQ(ctrl, "senduuname")
|| EQ(ctrl, "version") || EQ(ctrl, "checkgroups")
! || EQ(ctrl, "newgroup") || EQ(ctrl, "rmgroup")) {
! #if defined(DONT_ALLOW_CONTROL_POSTS)
! /* These are administrative commands not used by normal users */
! (void)sprintf(Error, "Ask your news administrator to do the \"%s\" for you",
! ctrl);
! return Error;
! #endif
! }
! else if (EQ(ctrl, "ihave") || EQ(ctrl, "sendme"))
! /* Don't break some automated UUCP programs which use these commands */
/* SUPPRESS 530 *//* Empty body for statement */
;
else {
*** include/configdata.h.orig Tue Jul 30 16:11:19 1996
--- include/configdata.h Tue Jul 30 16:05:06 1996
***************
*** 254,259 ****
--- 254,262 ----
/* Strip Sender from posts that did authenticate? */
/* =()<#define @<NNRP_AUTH_SENDER>@_NNRP_AUTH_SENDER>()= */
#define DONT_NNRP_AUTH_SENDER
+ /* Allow posting of administrative Control messages? */
+ /* =()<#define @<ALLOW_CONTROL_POSTS>@_ALLOW_CONTROL_POSTS>()= */
+ #define DONT_ALLOW_CONTROL_POSTS
/* How many read/write failures until channel is put to sleep or closed? */
/* =()<#define BAD_IO_COUNT @<BAD_IO_COUNT>@>()= */
#define BAD_IO_COUNT 5
--
Sean Donelan, Data Research Associates, Inc, St. Louis, MO
Affiliation given for identification not representation
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads