INN commit: branches/2.5 (doc/pod/news.pod nnrpd/perm.c)
INN Commit
rra at isc.org
Mon Feb 17 13:18:21 UTC 2014
Date: Monday, February 17, 2014 @ 05:18:21
Author: iulius
Revision: 9603
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:
branches/2.5/doc/pod/news.pod
branches/2.5/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:17:35 UTC (rev 9602)
+++ doc/pod/news.pod 2014-02-17 13:18:21 UTC (rev 9603)
@@ -49,6 +49,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:17:35 UTC (rev 9602)
+++ nnrpd/perm.c 2014-02-17 13:18:21 UTC (rev 9603)
@@ -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