[PATCH] D154603: [analyzer][clangsa] Add new option to alpha.security.cert.InvalidPtrChecker

2023-09-29 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 abandoned this revision. gamesh411 added a comment. Moving this to GitHub as Phabricator is shutting down. Relevant PR here: https://github.com/llvm/llvm-project/pull/67663 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154603/new/

[PATCH] D154603: [analyzer][clangsa] Add new option to alpha.security.cert.InvalidPtrChecker

2023-09-11 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 marked 2 inline comments as done. gamesh411 added a comment. @steakhal gentle ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154603/new/ https://reviews.llvm.org/D154603 ___ cfe-commits

[PATCH] D154603: [analyzer][clangsa] Add new option to alpha.security.cert.InvalidPtrChecker

2023-09-11 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 556510. gamesh411 added a comment. - use std::string - simplify tests Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154603/new/ https://reviews.llvm.org/D154603 Files:

[PATCH] D150647: [WIP][analyzer] Fix EnumCastOutOfRangeChecker C++17 handling

2023-09-11 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 abandoned this revision. gamesh411 added a comment. This is no longer relevant, as the fix already went in (D153954 ). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150647/new/

[PATCH] D154603: [analyzer][clangsa] Add new option to alpha.security.cert.InvalidPtrChecker

2023-08-23 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. In D154603#4609809 , @gamesh411 wrote: > In D154603#4580609 , @steakhal > wrote: > >> I'm sorry starting the review of this one only now, but I'm quite booked. >> Is it still relevant?

[PATCH] D154603: [analyzer][clangsa] Add new option to alpha.security.cert.InvalidPtrChecker

2023-08-23 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. In D154603#4580609 , @steakhal wrote: > I'm sorry starting the review of this one only now, but I'm quite booked. > Is it still relevant? If so, I'll continue. Yes thanks for the effort! I would like to go through with this

[PATCH] D154603: [analyzer][clangsa] Add new option to alpha.security.cert.InvalidPtrChecker

2023-08-23 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 marked 8 inline comments as done. gamesh411 added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/cert/InvalidPtrChecker.cpp:116-117 +const NoteTag *Note = +C.getNoteTag([Region, FunctionName, Message](PathSensitiveBugReport , +

[PATCH] D154603: [analyzer][clangsa] Add new option to alpha.security.cert.InvalidPtrChecker

2023-08-23 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 552676. gamesh411 marked an inline comment as done. gamesh411 added a comment. rebased and squashed Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154603/new/ https://reviews.llvm.org/D154603 Files:

[PATCH] D154603: [analyzer][clangsa] Add new option to alpha.security.cert.InvalidPtrChecker

2023-08-23 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 552670. gamesh411 added a comment. Add tests for checker option Remove unnecessary const_cast Only model a getenv call if there is a value to model Use getPredecessor to better indicate what happens during EG building Hoist GetEnvCall variable Fix dangling

[PATCH] D157104: [analyzer] Improve underflow handling in ArrayBoundV2

2023-08-10 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 accepted this revision. gamesh411 added a comment. This revision is now accepted and ready to land. Seems like a straightforward extension, LGTM. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D157104/new/ https://reviews.llvm.org/D157104

[PATCH] D153954: [clang][analyzer] Fix empty enum handling in EnumCastOutOfRange checker

2023-08-09 Thread Endre Fülöp via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG90c1f51c4b3e: [clang][analyzer] Fix empty enum handling in EnumCastOutOfRange checker (authored by gamesh411). Repository: rG LLVM Github

[PATCH] D153954: [clang][analyzer] Fix empty enum handling in EnumCastOutOfRange checker

2023-08-09 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 548593. gamesh411 added a comment. minor review fixups Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153954/new/ https://reviews.llvm.org/D153954 Files:

[PATCH] D156312: [analyzer] Upstream BitwiseShiftChecker

2023-07-31 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. I like this, especially, that the functionality of UBOR can be merged and extended in a much cleaner way (architecturally). Comment at: clang/lib/StaticAnalyzer/Checkers/BitwiseShiftChecker.cpp:301-302 +

[PATCH] D153954: [WIP][clang][analyzer] Relax alpha.cplusplus.EnumCastOutOfRange checker

2023-07-24 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 marked 4 inline comments as done. gamesh411 added a comment. In D153954#4456713 , @shafik wrote: > I did not look at this in detail but I don't think this approach is correct. > I fixed this for constant evaluation the other day and you can

[PATCH] D153954: [WIP][clang][analyzer] Relax alpha.cplusplus.EnumCastOutOfRange checker

2023-07-24 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 543413. gamesh411 edited the summary of this revision. gamesh411 added a comment. The checker now retains the original detection logic, but only whitelists empty enums. As a future step the checker is moved into the optin package. Repository: rG LLVM

[PATCH] D154603: [analyzer][clangsa] Add new option to alpha.security.cert.InvalidPtrChecker

2023-07-06 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/cert/InvalidPtrChecker.cpp:95 // Stores the region of the environment pointer of 'main' (if present). -REGISTER_TRAIT_WITH_PROGRAMSTATE(EnvPtrRegion, const MemRegion *)

[PATCH] D154603: [analyzer][clangsa] Add new option to alpha.security.cert.InvalidPtrChecker

2023-07-06 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. Herald added subscribers: steakhal, manas, ASDenysPetrov, martong, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. Herald added a reviewer: Szelethus. Herald added a reviewer: NoQ. Herald added a project: All.

[PATCH] D153954: Relax alpha.cplusplusEnumCastOutOfRange This checker previously gave many false positives, because only the enum

2023-06-28 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. Herald added subscribers: steakhal, martong, Szelethus, dkrupp. Herald added a reviewer: Szelethus. Herald added a reviewer: NoQ. Herald added a project: All. gamesh411 requested review of this revision. Herald added a project: clang. Herald added a subscriber:

[PATCH] D150647: [WIP][analyzer] Fix EnumCastOutOfRangeChecker C++17 handling

2023-05-16 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. In D150647#4345345 , @steakhal wrote: >> In C++17 the initialization rules for enum classes are relaxed. > > In what way are they relaxed compared to regular enums? The initialization rules are relaxed compared to their

[PATCH] D150647: [WIP][analyzer] Fix EnumCastOutOfRangeChecker C++17 handling

2023-05-16 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. Just the test cases are added so far. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D150647/new/ https://reviews.llvm.org/D150647 ___ cfe-commits mailing list

[PATCH] D150647: [WIP][analyzer] Fix EnumCastOutOfRangeChecker C++17 handling

2023-05-16 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. Herald added subscribers: steakhal, manas, ASDenysPetrov, martong, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. Herald added a reviewer: Szelethus. Herald added a project: All. gamesh411 requested review of

[PATCH] D136848: [clang][AST] Compare UnresolvedLookupExpr in structural equivalence.

2022-12-19 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 accepted this revision. gamesh411 added a comment. This revision is now accepted and ready to land. I have verified this patch on open-source projects. Bitcoin had quite a few crashes without this; those are gone. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D126186: [clang-tidy] Extend cert-oop57-cpp to check non-zero memset values

2022-06-01 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. Thanks for the quick review! Fixed the double backtick in the release notes as well. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126186/new/ https://reviews.llvm.org/D126186

[PATCH] D126186: [clang-tidy] Extend cert-oop57-cpp to check non-zero memset values

2022-06-01 Thread Endre Fülöp via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGd33f199910fa: [clang-tidy] Extend cert-oop57-cpp to check non-zero memset values (authored by gamesh411). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D126186: [clang-tidy] Extend cert-oop57-cpp to check non-zero memset values

2022-05-30 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 432868. gamesh411 added a comment. Remove literal checking from the matcher for memset as well There is no change in the result set on open source projects even without restricting the matches to literals. IMO this is more in line with the rule as it's

[PATCH] D126186: [clang-tidy] Extend cert-oop57-cpp to check non-zero memset values

2022-05-30 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 432866. gamesh411 added a comment. fix Release Notes Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126186/new/ https://reviews.llvm.org/D126186 Files:

[PATCH] D126186: [clang-tidy] Extend cert-oop57-cpp to check non-zero memset values

2022-05-23 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 431348. gamesh411 added a comment. Add full diff with arcanist Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126186/new/ https://reviews.llvm.org/D126186 Files:

[PATCH] D126186: [clang-tidy] Extend cert-oop57-cpp to check non-zero memset values

2022-05-23 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 431319. gamesh411 added a comment. Added a release note Also generated the full context (arcanist could validate the site certificate, that's why I had to resort to manual diff creation. Was there a certificate change on the reviews.llmv.org site maybe?)

[PATCH] D126186: [clang-tidy] Extend cert-oop57-cpp to check non-zero memset values

2022-05-23 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. F23163926: CSA_20testbench_20report.zip There is no change in the results as far as these OS are concerned. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126186/new/ https://reviews.llvm.org/D126186

[PATCH] D126186: [clang-tidy] Extend cert-oop57-cpp to check non-zero memset values

2022-05-23 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. gamesh411 added reviewers: steakhal, martong, whisperity. gamesh411 added a project: clang-tools-extra. Herald added subscribers: carlosgalvezp, Szelethus, dkrupp, rnkovacs, xazax.hun. Herald added a project: All. gamesh411 requested review of this revision. Herald

[PATCH] D125524: [BoundV2] ArrayBoundV2 checks if the extent is tainted

2022-05-13 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 429159. gamesh411 added a comment. add analyzer tag Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125524/new/ https://reviews.llvm.org/D125524 Files:

[PATCH] D125524: [BoundV2] ArrayBoundV2 checks if the extent is tainted

2022-05-13 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. gamesh411 added a reviewer: steakhal. Herald added subscribers: martong, Szelethus, dkrupp. Herald added a reviewer: Szelethus. Herald added a project: All. gamesh411 requested review of this revision. Herald added a project: clang. Herald added a subscriber:

[PATCH] D125360: [analyzer] Add taint to the BoolAssignmentChecker

2022-05-13 Thread Endre Fülöp via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG094fb13b88b3: [analyzer] Add taint to the BoolAssignmentChecker (authored by gamesh411). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125360/new/

[PATCH] D125365: [NFC][analyzer] Pass down a State and a Pred ExplodedNode in the MallocChecker

2022-05-11 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. gamesh411 added a reviewer: steakhal. Herald added subscribers: manas, ASDenysPetrov, martong, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. Herald added a reviewer: Szelethus. Herald added a project: All.

[PATCH] D125362: [NFC][analyzer] Transitive interestingness in BugReporter

2022-05-11 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. gamesh411 added a reviewer: steakhal. Herald added subscribers: manas, ASDenysPetrov, martong, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. Herald added a reviewer: Szelethus. Herald added a project: All.

[PATCH] D125360: [analyzer] Add taint to the BoolAssignmentChecker

2022-05-11 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. gamesh411 added a reviewer: steakhal. Herald added subscribers: manas, ASDenysPetrov, martong, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. Herald added a reviewer: Szelethus. Herald added a project: All.

[PATCH] D125225: [WIP][analyzer] Taint Notes enhancements

2022-05-09 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. @steakhal This is WIP as there is still a stdlib function, that does not pass the test, and I would like to add more complex taint propagation test cases as well. Could you please glance over these commits: [Malloc] Pass down a State and a Pred ExplodedNode in the

[PATCH] D125225: [WIP][analyzer] Taint Notes enhancements

2022-05-09 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 428070. gamesh411 added a comment. - [BoolAssign] Add taint to the BoolAssignmentChecker - [BugReporter] Transitive interestingness - [Malloc] Pass down a State and a Pred ExplodedNode in the MallocChecker - [BoundV2] ArrayBoundV2 checks if the extent is

[PATCH] D125225: [WIP][analyzer] Taint Notes enhancements

2022-05-09 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. gamesh411 added a reviewer: steakhal. Herald added subscribers: manas, ASDenysPetrov, martong, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. Herald added a reviewer: Szelethus. Herald added a project: All.

[PATCH] D120369: [analyzer] Add more propagations to Taint analysis

2022-03-07 Thread Endre Fülöp via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG4fd6c6e65ab5: [analyzer] Add more propagations to Taint analysis (authored by gamesh411). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D120369/new/

[PATCH] D120369: [analyzer] Add more propagations to Taint analysis

2022-03-07 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 413388. gamesh411 added a comment. Herald added a project: All. rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D120369/new/ https://reviews.llvm.org/D120369 Files: clang/docs/analyzer/checkers.rst

[PATCH] D120369: [analyzer] Add more propagations to Taint analysis

2022-03-01 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added inline comments. Comment at: clang/docs/analyzer/checkers.rst:2361 Default propagations defined by ``GenericTaintChecker``: -``atoi``, ``atol``, ``atoll``, ``fgetc``, ``fgetln``, ``fgets``, ``fscanf``, ``sscanf``, ``getc``, ``getc_unlocked``, ``getdelim``,

[PATCH] D120369: [analyzer] Add more propagations to Taint analysis

2022-03-01 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 412057. gamesh411 marked 17 inline comments as done. gamesh411 added a comment. Herald added a subscriber: manas. - remove vscanf and co. - use debug.ExprInspection for test cases - fix semantic issues for modeled functions Repository: rG LLVM Github

[PATCH] D120236: [analyzer] Add more sources to Taint analysis

2022-02-28 Thread Endre Fülöp via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG34a7387986a6: [analyzer] Add more sources to Taint analysis (authored by gamesh411). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST

[PATCH] D120236: [analyzer] Add more sources to Taint analysis

2022-02-28 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 411765. gamesh411 added a comment. fix readlinkat arg index extend testcase for readlinkat Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D120236/new/ https://reviews.llvm.org/D120236 Files:

[PATCH] D120236: [analyzer] Add more sources to Taint analysis

2022-02-28 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 marked 3 inline comments as done. gamesh411 added a comment. readlinkat fix incoming Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D120236/new/ https://reviews.llvm.org/D120236 ___ cfe-commits

[PATCH] D120236: [analyzer] Add more sources to Taint analysis

2022-02-28 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 411763. gamesh411 added a comment. Herald added a subscriber: manas. add readlinkat rename _IO_getc testcase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D120236/new/ https://reviews.llvm.org/D120236 Files:

[PATCH] D120236: [analyzer] Add more sources to Taint analysis

2022-02-23 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added inline comments. Comment at: clang/docs/analyzer/checkers.rst:2358 Default sources defined by ``GenericTaintChecker``: -``fdopen``, ``fopen``, ``freopen``, ``getch``, ``getchar``, ``getchar_unlocked``, ``gets``, ``scanf``, ``socket``, ``wgetch`` + ``_IO_getc``,

[PATCH] D120236: [analyzer] Add more sources to Taint analysis

2022-02-23 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 410747. gamesh411 marked 9 inline comments as done. gamesh411 added a comment. - s/getcw/getwd - add gets_s - remove getopt variants - add realinkat - discuss getnameinfo? - rename tests - update getnameinfo - comment on source/propagator discrepancy -

[PATCH] D120369: [analyzer] Add more propagations to Taint analysis

2022-02-22 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. gamesh411 added a reviewer: steakhal. Herald added subscribers: ASDenysPetrov, martong, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. Herald added a reviewer: Szelethus. gamesh411 requested review of this

[PATCH] D120236: Add more sources to Taint analysis

2022-02-21 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. gamesh411 added a reviewer: steakhal. Herald added subscribers: martong, Szelethus, dkrupp. Herald added a reviewer: Szelethus. gamesh411 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Add more functions

[PATCH] D116025: [analyzer][NFC] Refactor GenericTaintChecker to use CallDescriptionMap

2022-01-18 Thread Endre Fülöp via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG17f74240e6c3: [analyzer][NFC] Refactor GenericTaintChecker to use CallDescriptionMap (authored by gamesh411). Repository: rG LLVM Github Monorepo

[PATCH] D116025: [analyzer][NFC] Refactor GenericTaintChecker to use CallDescriptionMap

2022-01-18 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 400790. gamesh411 added a comment. Remove explicit template keyword for MSVC compatibility Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116025/new/ https://reviews.llvm.org/D116025 Files:

[PATCH] D116025: [analyzer][NFC] Refactor GenericTaintChecker to use CallDescriptionMap

2022-01-17 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 400498. gamesh411 added a comment. All commits were exluded in the previous patch upload Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116025/new/ https://reviews.llvm.org/D116025 Files:

[PATCH] D114706: [analyzer] Fix sensitive argument logic in GenericTaintChecker

2022-01-17 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 abandoned this revision. gamesh411 added a comment. This is superseded by D116025 . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D114706/new/ https://reviews.llvm.org/D114706

[PATCH] D116025: [analyzer][NFC] Refactor GenericTaintChecker to use CallDescriptionMap

2022-01-17 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. Applied typo and naming fixes, introduced 2 move operations, and re-introduced short circuiting. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116025/new/ https://reviews.llvm.org/D116025

[PATCH] D116025: [analyzer][NFC] Refactor GenericTaintChecker to use CallDescriptionMap

2022-01-17 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 400464. gamesh411 marked 7 inline comments as done. gamesh411 added a comment. Fixes round two Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116025/new/ https://reviews.llvm.org/D116025 Files:

[PATCH] D116025: [analyzer][NFC] Refactor GenericTaintChecker to use CallDescriptionMap

2022-01-12 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 399246. gamesh411 added a comment. Tidy things up thanks to the recommendations of @steakhal Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116025/new/ https://reviews.llvm.org/D116025 Files:

[PATCH] D115934: [analyzer] Add range constructor to CallDescriptionMap

2021-12-20 Thread Endre Fülöp via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGc6a861e644a9: [analyzer] Add range constructor to CallDescriptionMap (authored by gamesh411). Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D115931: [analyzer] Enable move semantics for CallDescriptionMap

2021-12-20 Thread Endre Fülöp via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGe0321eb86158: [analyzer] Enable move semantics for CallDescriptionMap (authored by gamesh411). Repository: rG LLVM Github Monorepo CHANGES SINCE

[PATCH] D116025: [analyzer][NFC] Refactor GenericTaintChecker to use CallDescriptionMap

2021-12-20 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. gamesh411 added reviewers: steakhal, martong, NoQ. Herald added subscribers: manas, ASDenysPetrov, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, rnkovacs, szepet, baloghadamsoftware, xazax.hun. Herald added a reviewer: Szelethus. gamesh411 requested

[PATCH] D115931: [analyzer] Enable move semantics for CallDescriptionMap

2021-12-20 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 395395. gamesh411 added a comment. Remove static asserts as it adds little to no value in this case Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D115931/new/ https://reviews.llvm.org/D115931 Files:

[PATCH] D115934: [analyzer] Add range constructor to CallDescriptionMap

2021-12-20 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 395394. gamesh411 added a comment. Remove static asserts as it only makes the tests more brittle Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D115934/new/ https://reviews.llvm.org/D115934 Files:

[PATCH] D115934: [analyzer] Add range constructor to CallDescriptionMap

2021-12-17 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. gamesh411 added reviewers: steakhal, martong. Herald added subscribers: manas, ASDenysPetrov, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, rnkovacs, szepet, baloghadamsoftware, xazax.hun. Herald added a reviewer: Szelethus. gamesh411 requested review

[PATCH] D115931: [analyzer] Enable move semantics for CallDescriptionMap

2021-12-17 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. gamesh411 added reviewers: steakhal, martong. Herald added subscribers: manas, ASDenysPetrov, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, rnkovacs, szepet, baloghadamsoftware, xazax.hun. Herald added a reviewer: Szelethus. gamesh411 requested review

[PATCH] D114706: [analyzer] Fix sensitive argument logic in GenericTaintChecker

2021-11-29 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. gamesh411 added reviewers: steakhal, Szelethus, NoQ. Herald added subscribers: manas, ASDenysPetrov, martong, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun. gamesh411 requested review of this revision. Herald added a

[PATCH] D113251: [analyzer][doc] Add user documenation for taint analysis

2021-11-28 Thread Endre Fülöp via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rG4aac00a71db3: [analyzer][doc] Add user documenation for taint analysis (authored by gamesh411). Repository: rG LLVM

[PATCH] D113251: [analyzer][doc] Add user documenation for taint analysis

2021-11-25 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 389684. gamesh411 added a comment. update with `arc diff $(git merge-base HEAD upstream) --update D113251` in order to satisfy workflow `pre-merge checks` Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D113251: [analyzer][doc] Add user documenation for taint analysis

2021-11-23 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 389134. gamesh411 added a comment. fix indentation warning make inline code formatting look better Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113251/new/ https://reviews.llvm.org/D113251 Files:

[PATCH] D113251: [analyzer][doc] Add user documenation for taint analysis

2021-11-23 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added inline comments. Comment at: clang/docs/analyzer/checkers.rst:2341-2342 + +Default propagations defined by `GenericTaintChecker`: +``atoi``, ``atol``, ``atoll``, ``fgetc``, ``fgetln``, ``fgets``, ``fscanf``, ``sscanf``, ``getc``, ``getc_unlocked``, ``getdelim``,

[PATCH] D113251: [analyzer][doc] Add user documenation for taint analysis

2021-11-23 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 389117. gamesh411 marked 15 inline comments as done. gamesh411 added a comment. tidy up based on comments from whispy Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113251/new/

[PATCH] D113251: [analyzer][doc] Add user documenation for taint analysis

2021-11-18 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 388132. gamesh411 added a comment. Fix the review comments of @steakhal Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D113251/new/ https://reviews.llvm.org/D113251 Files: clang/docs/analyzer/checkers.rst

[PATCH] D113251: [analyzer][doc] Add user documenation for taint analysis

2021-11-18 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 marked 13 inline comments as done. gamesh411 added inline comments. Comment at: clang/docs/analyzer/checkers.rst:2351 + + clang --analyze ... -Xclang -analyzer-config -Xclang alpha.security.taint.TaintPropagation:Config=taint_config.yaml + steakhal

[PATCH] D113251: [analyzer][doc] Add user documenation for taint analysis

2021-11-05 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. gamesh411 added a reviewer: steakhal. Herald added subscribers: manas, ASDenysPetrov, martong, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun, whisperity. Herald added a reviewer: Szelethus. gamesh411 requested

[PATCH] D92103: [ASTImporter] Import the default argument of TemplateTypeParmDecl

2020-11-28 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. On bitcoin v0.18.1 , there is an assertion introduced by this change. The TU that can be used for reproduction is `src/script/interpreter.cpp`. Assertion message: CTU loaded AST file:

[PATCH] D89528: [clang][test] Fix prefix operator++ signature in iterators

2020-11-25 Thread Endre Fülöp via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGdc96cc33c13e: [clang][test] Fix prefix operator++ signature in iterators (authored by gamesh411). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D89528/new/

[PATCH] D83717: [clang-tidy] Add check fo SEI CERT item ENV32-C

2020-11-25 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 abandoned this revision. gamesh411 added a comment. In D83717#2370154 , @NoQ wrote: > I don't think you actually need active support for invoking exit handlers > path-sensitively at the end of `main()` in order to implement your checker. > You

[PATCH] D91948: [analyzer][doc] Add Container- and IteratorModeling developer docs

2020-11-23 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. Herald added subscribers: cfe-commits, steakhal, ASDenysPetrov, martong, Charusso, dkrupp, donat.nagy, Szelethus, mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun, whisperity. Herald added a project: clang. gamesh411 requested review of this

[PATCH] D83717: [clang-tidy] Add check fo SEI CERT item ENV32-C

2020-10-31 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. > Just to make sure we're on the same page -- the current approach is not > flow-sensitive, and so my concern is that it won't report any true positives > (not that it will be prone to false positives). Sorry about that. You are absolutely right; what I was trying to

[PATCH] D83717: [clang-tidy] Add check fo SEI CERT item ENV32-C

2020-10-30 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. In D83717#2279263 , @aaron.ballman wrote: > One of the concerns I have with this not being a flow-sensitive check is that > most of the bad situations are not going to be caught by the clang-tidy > version of the check. The

[PATCH] D87830: [clang-tidy][test] Allow empty checks in check_clang_tidy.py

2020-10-19 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. In D87830#2336572 , @njames93 wrote: > Probably not quite as verbose but should do the job > > // RUN: clang-tidy %s --checks=-*,my-check-to-test --warnings-as-errors=* > -- -std=c++11 Thanks  ! I can live with this

[PATCH] D89528: [clang][test] Fix prefix operator++ signature in iterators

2020-10-19 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. In D89528#2334795 , @martong wrote: > What is the context here? Did it cause any crash/bug or were you just reading > through the code for a good night sleep? :D Actually I was debugging thru iterator-related code and was

[PATCH] D87830: [clang-tidy][test] Allow empty checks in check_clang_tidy.py

2020-10-16 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. In D87830#2298198 , @aaron.ballman wrote: > > know of any tests that are impacted by this? I haven't found any tidy-tests that were negative-tests (ie.: tests that assert that there are no diagnostics). > ... if I

[PATCH] D89528: [clang][test] Fix prefix operator++ signature in iterators

2020-10-16 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. Herald added subscribers: cfe-commits, martong, Szelethus, dkrupp. Herald added a reviewer: Szelethus. Herald added a project: clang. gamesh411 requested review of this revision. Prefix operator++ should return the iterator incremented by reference. Repository:

[PATCH] D87830: [clang-tidy][test] Allow empty checks in check_clang_tidy.py

2020-09-28 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. Do you have some thoughts about this, should this be pursued, or do you think the use-case is not relevant? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87830/new/ https://reviews.llvm.org/D87830

[PATCH] D83717: [clang-tidy] Add check fo SEI CERT item ENV32-C

2020-09-17 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 292488. gamesh411 added a comment. Update commit message Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83717/new/ https://reviews.llvm.org/D83717 Files:

[PATCH] D87830: [clang-tidy][test] Allow empty checks in check_clang_tidy.py

2020-09-17 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 292487. gamesh411 added a comment. Tidy up commit message Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87830/new/ https://reviews.llvm.org/D87830 Files:

[PATCH] D87830: [clang-tidy][test] Allow empty checks in check_clang_tidy.py

2020-09-17 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 292485. gamesh411 added a comment. Update commit msg with example Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D87830/new/ https://reviews.llvm.org/D87830 Files:

[PATCH] D87830: [clang-tidy][test] Allow empty checks in check_clang_tidy.py

2020-09-17 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 created this revision. Herald added subscribers: cfe-commits, martong, steakhal, Szelethus, dkrupp, xazax.hun, whisperity. Herald added a project: clang. gamesh411 requested review of this revision. Currently there is no way to assert that a check does not produce warnings for a

[PATCH] D83717: [clang-tidy] Add check fo SEI CERT item ENV32-C

2020-09-17 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 292419. gamesh411 added a comment. Reformat diagnostic message Use explicit name longjmp instead of jump function Fix liberal auto inside Collector Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83717/new/

[PATCH] D83717: [clang-tidy] Add check fo SEI CERT item ENV32-C

2020-09-17 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 marked 13 inline comments as done. gamesh411 added a comment. Note that there are no negative test cases that assert that we do NOT report in case a custom or an anonymous namespace is used. For that I would need a small patch in the testing infrastructure. Patch needed in

[PATCH] D83717: [clang-tidy] Add check fo SEI CERT item ENV32-C

2020-09-17 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 292416. gamesh411 marked 2 inline comments as done. gamesh411 added a comment. Add abort and terminate handling Extend tests to cover every exit functions Extract matcher bind labels Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D83717: [clang-tidy] Add check fo SEI CERT item ENV32-C

2020-09-02 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 289597. gamesh411 added a comment. only consider global and ::std scope handlers Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83717/new/ https://reviews.llvm.org/D83717 Files:

[PATCH] D85424: [Analyzer] Crash fix for alpha.cplusplus.IteratorRange

2020-08-31 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. `CReduce` did not manage to produce any meaningful result after a week worth of runtime (more than ~2000 lines of code still remaining after reduction). We could track this down by tracing the ExprEngine code that assigns the Undefined SVal but that seems a huge

[PATCH] D77229: [Analyzer] Avoid handling of LazyCompundVals in IteratorModeling

2020-08-14 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 accepted this revision. gamesh411 added a comment. This revision is now accepted and ready to land. Thanks! LGTM now. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D77229/new/ https://reviews.llvm.org/D77229 ___ cfe-commits mailing

[PATCH] D77229: [Analyzer] Avoid handling of LazyCompundVals in IteratorModeling

2020-08-13 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. Aside from infrastructural questions which I am not qualified ( nor particularly knowledgeable :3 ) to address, this looks good to me. Comment at: clang/lib/StaticAnalyzer/Checkers/STLAlgorithmModeling.cpp:77 + unsigned ArgNum = 999; +

[PATCH] D85728: [Analyzer] Support for the new variadic isa<> and isa_and_not_null<> in CastValueChecker

2020-08-12 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added inline comments. Comment at: clang/lib/StaticAnalyzer/Checkers/CastValueChecker.cpp:265 + SmallVector CastToTyVec; + for (unsigned idx = 0; idx < FD->getTemplateSpecializationArgs()->size() - 1; + ++idx) { Do we intentionally skip the

[PATCH] D83717: [clang-tidy] Add check fo SEI CERT item ENV32-C

2020-08-04 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 updated this revision to Diff 282837. gamesh411 marked an inline comment as done. gamesh411 added a comment. rename file name in header Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D83717/new/ https://reviews.llvm.org/D83717 Files:

[PATCH] D83190: [analyzer] Model iterator random incrementation symmetrically

2020-08-04 Thread Endre Fülöp via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG141cb8a1eecc: [analyzer] Model iterator random incrementation symmetrically (authored by gamesh411). Repository: rG LLVM Github Monorepo CHANGES

[PATCH] D84520: [Analyzer] Improve invalid dereference bug reporting in DereferenceChecker.

2020-08-04 Thread Endre Fülöp via Phabricator via cfe-commits
gamesh411 added a comment. I would add one more test for the undefined case. Like a local array variable that is uninitialized. That could mirror some of the null-dereference cases. Comment at: clang/lib/StaticAnalyzer/Checkers/DereferenceChecker.cpp:135 +DerefKindStr =

  1   2   3   >