=?utf-8?q?Donát?= Nagy ,Daniel Krupp
,
=?utf-8?q?Donát?= Nagy ,Daniel Krupp
Message-ID:
In-Reply-To:
https://github.com/dkrupp closed https://github.com/llvm/llvm-project/pull/68607
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lis
=?utf-8?q?Donát?= Nagy ,Daniel Krupp
,
=?utf-8?q?Donát?= Nagy ,Daniel Krupp
Message-ID:
In-Reply-To:
https://github.com/dkrupp updated
https://github.com/llvm/llvm-project/pull/68607
>From 143db26ffe8620c2b45eb15d331466c883bbfce0 Mon Sep 17 00:00:00 2001
From: Daniel Krupp
Date: Mon, 9 Oct
https://github.com/NagyDonat updated
https://github.com/llvm/llvm-project/pull/68607
From 143db26ffe8620c2b45eb15d331466c883bbfce0 Mon Sep 17 00:00:00 2001
From: Daniel Krupp
Date: Mon, 9 Oct 2023 16:52:13 +0200
Subject: [PATCH 1/8] [analyzer] Removing untrusted buffer size taint warning
alpha
@@ -95,22 +94,23 @@ void testReadStdIn(){
}
void multipleTaintSources(void) {
- int x,y,z;
- scanf("%d", &x); // expected-note {{Taint originated here}}
+ char cmd[2048], file[1024];
+ scanf ("%1022[^\n] ", cmd); // expected-note {{Taint originated here}}
https://github.com/NagyDonat approved this pull request.
LGTM with a few minor changes.
https://github.com/llvm/llvm-project/pull/68607
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -53,34 +54,32 @@ void taintDiagnosticVLA(void) {
// Tests if the originated note is correctly placed even if the path is
// propagating through variables and expressions
-char *taintDiagnosticPropagation(){
- char *pathbuf;
- char *size=getenv("SIZE"); // expected-note {{
https://github.com/NagyDonat edited
https://github.com/llvm/llvm-project/pull/68607
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
=?utf-8?q?Donát?= Nagy ,Daniel Krupp
Message-ID:
In-Reply-To:
https://github.com/dkrupp updated
https://github.com/llvm/llvm-project/pull/68607
>From 143db26ffe8620c2b45eb15d331466c883bbfce0 Mon Sep 17 00:00:00 2001
From: Daniel Krupp
Date: Mon, 9 Oct 2023 16:52:13 +0200
Subject: [PATCH 1/7
https://github.com/NagyDonat updated
https://github.com/llvm/llvm-project/pull/68607
From 143db26ffe8620c2b45eb15d331466c883bbfce0 Mon Sep 17 00:00:00 2001
From: Daniel Krupp
Date: Mon, 9 Oct 2023 16:52:13 +0200
Subject: [PATCH 1/6] [analyzer] Removing untrusted buffer size taint warning
alpha
@@ -95,22 +94,23 @@ void testReadStdIn(){
}
void multipleTaintSources(void) {
- int x,y,z;
- scanf("%d", &x); // expected-note {{Taint originated here}}
+ char cmd[2048], file[1024];
+ scanf ("%1022[^\n] ", cmd); // expected-note {{Taint originated here}}
github-actions[bot] wrote:
:warning: C/C++ code formatter, clang-format found issues in your code.
:warning:
You can test this locally with the following command:
``bash
git-clang-format --diff e50a857fb16bcfe7cfc99bf87db620bc82d1cff5
5d7c44a7e4b338f83f791ebc6ec3297d62983c0b --
https://github.com/dkrupp updated
https://github.com/llvm/llvm-project/pull/68607
>From 143db26ffe8620c2b45eb15d331466c883bbfce0 Mon Sep 17 00:00:00 2001
From: Daniel Krupp
Date: Mon, 9 Oct 2023 16:52:13 +0200
Subject: [PATCH 1/5] [analyzer] Removing untrusted buffer size taint warning
alpha.s
https://github.com/dkrupp updated
https://github.com/llvm/llvm-project/pull/68607
>From 143db26ffe8620c2b45eb15d331466c883bbfce0 Mon Sep 17 00:00:00 2001
From: Daniel Krupp
Date: Mon, 9 Oct 2023 16:52:13 +0200
Subject: [PATCH 1/4] [analyzer] Removing untrusted buffer size taint warning
alpha.s
@@ -305,15 +305,19 @@ void testGets_s(void) {
void testTaintedBufferSize(void) {
size_t ts;
+ // malloc, calloc, bcopy, memcpy functions are removed as unconditional sinks
+ // from the GenericTaintChecker's default configuration,
+ // because it generated too many false
@@ -95,22 +94,23 @@ void testReadStdIn(){
}
void multipleTaintSources(void) {
- int x,y,z;
- scanf("%d", &x); // expected-note {{Taint originated here}}
+ char cmd[2048],file[1024];
NagyDonat wrote:
Bikeshedding: please add a space after the comma (here an
https://github.com/NagyDonat commented:
I think this old commit could be merged after some very minor clarifications.
In addition to the changes marked in inline comments, you could also add some
TODO comments in MallocChecker and CStringChecker to mark the places where we
want to add the code
https://github.com/NagyDonat edited
https://github.com/llvm/llvm-project/pull/68607
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/dkrupp updated
https://github.com/llvm/llvm-project/pull/68607
>From 143db26ffe8620c2b45eb15d331466c883bbfce0 Mon Sep 17 00:00:00 2001
From: Daniel Krupp
Date: Mon, 9 Oct 2023 16:52:13 +0200
Subject: [PATCH 1/3] [analyzer] Removing untrusted buffer size taint warning
alpha.s
https://github.com/dkrupp updated
https://github.com/llvm/llvm-project/pull/68607
>From 143db26ffe8620c2b45eb15d331466c883bbfce0 Mon Sep 17 00:00:00 2001
From: Daniel Krupp
Date: Mon, 9 Oct 2023 16:52:13 +0200
Subject: [PATCH 1/3] [analyzer] Removing untrusted buffer size taint warning
alpha.s
https://github.com/dkrupp updated
https://github.com/llvm/llvm-project/pull/68607
>From 143db26ffe8620c2b45eb15d331466c883bbfce0 Mon Sep 17 00:00:00 2001
From: Daniel Krupp
Date: Mon, 9 Oct 2023 16:52:13 +0200
Subject: [PATCH 1/2] [analyzer] Removing untrusted buffer size taint warning
alpha.s
@@ -753,32 +756,16 @@ void GenericTaintChecker::initTaintRules(CheckerContext
&C) const {
{{{"execvp"}}, TR::Sink({{0, 1}}, MsgSanitizeSystemArgs)},
{{{"execvpe"}}, TR::Sink({{0, 1, 2}}, MsgSanitizeSystemArgs)},
{{{"dlopen"}}, TR::Sink({{0}}, MsgSanitizeSyste
@@ -733,13 +726,23 @@ void GenericTaintChecker::initTaintRules(CheckerContext
&C) const {
{{CDF_MaybeBuiltin, {{"stpcpy"}}},
TR::Prop({{1}}, {{0, ReturnValueIndex}})},
{{CDF_MaybeBuiltin, {{"strcat"}}},
- TR::Prop({{1}}, {{0, ReturnValueIndex}})},
+
@@ -753,32 +756,16 @@ void GenericTaintChecker::initTaintRules(CheckerContext
&C) const {
{{{"execvp"}}, TR::Sink({{0, 1}}, MsgSanitizeSystemArgs)},
{{{"execvpe"}}, TR::Sink({{0, 1, 2}}, MsgSanitizeSystemArgs)},
{{{"dlopen"}}, TR::Sink({{0}}, MsgSanitizeSyste
@@ -753,32 +756,16 @@ void GenericTaintChecker::initTaintRules(CheckerContext
&C) const {
{{{"execvp"}}, TR::Sink({{0, 1}}, MsgSanitizeSystemArgs)},
{{{"execvpe"}}, TR::Sink({{0, 1, 2}}, MsgSanitizeSystemArgs)},
{{{"dlopen"}}, TR::Sink({{0}}, MsgSanitizeSyste
https://github.com/DonatNagyE edited
https://github.com/llvm/llvm-project/pull/68607
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/DonatNagyE commented:
See https://github.com/llvm/llvm-project/pull/67352 for the discussion and
test results that motivated this patch. This is a conservative change that'll
remove some bug reports (both TPs and FPs) and would let us move the generic
taint checker out of t
llvmbot wrote:
@llvm/pr-subscribers-clang
Changes
alpha.security.taint.TaintPropagation checker
emitted a false warning to the following code
char buf[100];
size_t size = tainted();
if (size > 100)
return;
memset(buf, 0, size); // warn: untrusted data used as buffer size
The checker doe
https://github.com/dkrupp created
https://github.com/llvm/llvm-project/pull/68607
alpha.security.taint.TaintPropagation checker
emitted a false warning to the following code
char buf[100];
size_t size = tainted();
if (size > 100)
return;
memset(buf, 0, size); // warn: untrusted data used as b
28 matches
Mail list logo