INN commit: trunk (doc/pod/news.pod nnrpd/perm.c)
INN Commit
rra at isc.org
Mon Feb 17 13:17:37 UTC 2014
Date: Monday, February 17, 2014 @ 05:17:35
Author: iulius
Revision: 9602
readers.conf: make mandatory the program: key in res blocks
Fixed a segfault occurring in nnrpd when a res block was used in
readers.conf without the program: key.
This key is now explicitly made mandatory.
Modified:
trunk/doc/pod/news.pod
trunk/nnrpd/perm.c
------------------+
doc/pod/news.pod | 5 +++++
nnrpd/perm.c | 10 +++++++++-
2 files changed, 14 insertions(+), 1 deletion(-)
Modified: doc/pod/news.pod
===================================================================
--- doc/pod/news.pod 2014-02-17 13:13:43 UTC (rev 9601)
+++ doc/pod/news.pod 2014-02-17 13:17:35 UTC (rev 9602)
@@ -221,6 +221,11 @@
=item *
+Fixed a segfault occurring in B<nnrpd> when a res block was used in
+F<readers.conf> without the program: key.
+
+=item *
+
Fixed an issue where users were denied posting because of an overlapping
buffer copy in a check B<nnrpd> was doing. Thanks to Florian Schlichting
for the patch.
Modified: nnrpd/perm.c
===================================================================
--- nnrpd/perm.c 2014-02-17 13:13:43 UTC (rev 9601)
+++ nnrpd/perm.c 2014-02-17 13:17:35 UTC (rev 9602)
@@ -284,7 +284,11 @@
memset(ConfigBit, '\0', ConfigBitsize);
ret->name = xstrdup(orig->name);
- ret->program = xstrdup(orig->program);
+ if (orig->program != NULL) {
+ ret->program = xstrdup(orig->program);
+ } else {
+ ret->program = NULL;
+ }
if (orig->users)
ret->users = xstrdup(orig->users);
else
@@ -716,6 +720,10 @@
tok = CONFgettoken(PERMtoks, f);
}
+ if (m->program == NULL) {
+ ReportError(f, "Missing 'program:' key.");
+ }
+
if (tok == NULL) {
ReportError(f, "Unexpected EOF.");
}
More information about the inn-committers
mailing list