Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[security] Fixes for DSA-4314-1 net-snmp #2152

Merged
merged 1 commit into from
Oct 15, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
From 2170e345858738e65d3156a49d3186e4a9288821 Mon Sep 17 00:00:00 2001
From: Zhenggen Xu <zxu@linkedin.com>
Date: Fri, 12 Oct 2018 17:13:54 -0700
Subject: [PATCH] Subject: [PATCH] CHANGES: BUG: 2743: snmpd crashes when
receiving a GetNext PDU with multiple Varbinds

skip out-of-range varbinds when calling next handler
---
agent/helpers/table.c | 4 ++++
1 file changed, 4 insertions(+)

diff --git a/agent/helpers/table.c b/agent/helpers/table.c
index 882e84c..b943d6e 100644
--- a/agent/helpers/table.c
+++ b/agent/helpers/table.c
@@ -406,6 +406,8 @@ table_helper_handler(netsnmp_mib_handler *handler,
if (reqinfo->mode == MODE_GET)
table_helper_cleanup(reqinfo, request,
SNMP_NOSUCHOBJECT);
+ else
+ request->processed = 1; /* skip if next handler called */
continue;
}

@@ -483,6 +485,8 @@ table_helper_handler(netsnmp_mib_handler *handler,
#endif /* NETSNMP_NO_WRITE_SUPPORT */
table_helper_cleanup(reqinfo, request,
SNMP_NOSUCHOBJECT);
+ else
+ request->processed = 1; /* skip if next handler called */
continue;
}
/*
--
2.18.0

1 change: 1 addition & 0 deletions src/snmpd/patch-5.7.3+dfsg/series
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
0001-SNMP-Stop-spamming-logs-with-statfs-permission-denie.patch
0002-at.c-properly-check-return-status-from-realloc.-Than.patch
0003-CHANGES-BUG-2743-snmpd-crashes-when-receiving-a-GetN.patch