lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-Id: <1443080213-2553-1-git-send-email-dsw@hexology.net>
Date:	Thu, 24 Sep 2015 09:36:53 +0200
From:	Dan Webster <dsw@...ology.net>
To:	netdev@...r.kernel.org
Cc:	Dan Webster <dsw@...ology.net>,
	Stephen Hemminger <shemming@...cade.com>,
	Vadim Kochan <vadim4j@...il.com>
Subject: [PATCH iproute2] ss: fix file-based filtering segfault

Commit 1527a17 introduced a change where the second of two ssfilter_parse()
calls in ss.c was moved outside of a conditional block (ss.c: ~3575). This
commit enabled the parsing of services, such as 'sport = :ssh', but
inadvertently broke the '-F' file-based filtering:

--
$ cat filt.txt
src 127.0.0.1

$ ss -F filt.txt
Segmentation fault (core dumped)

Program received signal SIGSEGV, Segmentation fault.
yylex () at ssfilter.y:183
183         while (*tokptr == 0) {
--

The first (redundant) ssfilter_parse() was mangling yylex() for the latter
call.

Signed-off-by: Dan Webster <dsw@...ology.net>
---
 misc/ss.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/misc/ss.c b/misc/ss.c
index 9efc3c8..7c3dfa3 100644
--- a/misc/ss.c
+++ b/misc/ss.c
@@ -3782,12 +3782,6 @@ int main(int argc, char *argv[])
 			exit(0);
 	}
 
-	/* Now parse filter... */
-	if (argc == 0 && filter_fp) {
-		if (ssfilter_parse(&current_filter.f, 0, NULL, filter_fp))
-			usage();
-	}
-
 	while (argc > 0) {
 		if (strcmp(*argv, "state") == 0) {
 			NEXT_ARG();
-- 
2.1.4

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ