Commit Graph

2692 Commits

Author SHA1 Message Date
semmle-qlci
33c02fe928 Merge pull request #355 from hvitved/csharp/guards-logic
Approved by calumgrant
2018-11-06 19:06:30 +00:00
Tom Hvitved
2d25a04a2e C#: Add test for guard implications logic 2018-11-05 16:47:10 +01:00
Tom Hvitved
f5e6b79add C#: Address review comments 2018-11-05 16:14:15 +01:00
calum
c003150ed8 C#: Add missing file. 2018-11-02 16:46:49 +00:00
calum
29df7f5e96 C#: Mark false-negatives. 2018-11-02 16:46:49 +00:00
calum
7fa442d127 C#: Merge tests. 2018-11-02 16:46:49 +00:00
calum
ae96b347e2 C#: Address review comments. 2018-11-02 16:46:49 +00:00
calum
62fb693924 C#: Tidy up code and fix performance of remote flow sources. 2018-11-02 16:45:48 +00:00
calum
2090d69c3f C#: Tidy up tests. 2018-11-02 16:45:48 +00:00
calum
697e66e312 C#: Move test into subdirectory. 2018-11-02 16:45:48 +00:00
calum
d6e6ae66b8 C#: qltest stubs for UrlRedirect.ASPNETCore 2018-11-02 16:45:47 +00:00
calum
4655acadb2 C#: Stubs for XSSFlowASPNetCore test. 2018-11-02 16:45:47 +00:00
calum
8b8d2f9bef C#: Add auto-generated stubs. 2018-11-02 16:45:47 +00:00
Denis Levin
ba9cb5e22d cs: Adding sources and sinks for ASPNET.Core
Inintial query checkin.
Note: tests require Nuget packages with ASPNET and ASPNETCore in Packages directory, and won't compile without them.
The packages.config should include this:
  <package id="Microsoft.AspNet.Mvc" version="5.2.3" targetFramework="net461" />
  <package id="Microsoft.AspNet.WebPages" version="3.2.3" targetFramework="net461" />
  <package id="Microsoft.AspNetCore.Antiforgery" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Authorization" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Cors" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Cryptography.Internal" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.DataProtection" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.DataProtection.Abstractions" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Diagnostics" version="1.1.2" targetFramework="net452" />
  <package id="Microsoft.AspNetCore.Diagnostics.Abstractions" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Hosting" version="1.1.3" targetFramework="net452" />
  <package id="Microsoft.AspNetCore.Hosting.Abstractions" version="1.1.3" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Hosting.Server.Abstractions" version="1.1.3" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Html.Abstractions" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Http" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Http.Abstractions" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Http.Extensions" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Http.Features" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.HttpOverrides" version="1.1.2" targetFramework="net452" />
  <package id="Microsoft.AspNetCore.JsonPatch" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Localization" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Mvc" version="1.1.3" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Mvc.Abstractions" version="1.1.3" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Mvc.ApiExplorer" version="1.1.3" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Mvc.Core" version="1.1.3" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Mvc.Cors" version="1.1.3" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Mvc.DataAnnotations" version="1.1.3" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Mvc.Formatters.Json" version="1.1.3" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Mvc.Localization" version="1.1.3" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Mvc.Razor" version="1.1.3" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Mvc.Razor.Host" version="1.1.3" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Mvc.TagHelpers" version="1.1.3" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Mvc.ViewFeatures" version="1.1.3" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Razor" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Razor.Runtime" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.ResponseCaching" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.ResponseCaching.Abstractions" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.ResponseCompression" version="1.0.2" targetFramework="net452" />
  <package id="Microsoft.AspNetCore.Rewrite" version="1.0.2" targetFramework="net452" />
  <package id="Microsoft.AspNetCore.Routing" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Routing.Abstractions" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.AspNetCore.Server.Kestrel" version="1.1.2" targetFramework="net452" />
  <package id="Microsoft.AspNetCore.Server.Kestrel.Https" version="1.1.2" targetFramework="net452" />
  <package id="Microsoft.AspNetCore.Server.WebListener" version="1.1.4" targetFramework="net452" />
  <package id="Microsoft.AspNetCore.StaticFiles" version="1.1.2" targetFramework="net452" />
  <package id="Microsoft.AspNetCore.WebUtilities" version="1.1.2" targetFramework="net451" />
  <package id="Microsoft.Extensions.DependencyInjection.Abstractions" version="1.1.1" targetFramework="net451" />
  <package id="Microsoft.Extensions.Primitives" version="2.1.0" targetFramework="net451" />
  <package id="Microsoft.NETCore.App" version="2.0.0" />
  <package id="Microsoft.AspNetCore.Mvc" version="2.1.0" />
  <package id="Microsoft.AspNetCore.Mvc.Core" version="2.1.0" />
  <package id="Microsoft.AspNetCore.Mvc.Abstractions" version="2.1.0" />
  <package id="Microsoft.AspNetCore.Http.Extensions" version="2.1.0" />
  <package id="Microsoft.AspNetCore.Http.Abstractions" version="2.1.0" />
  <package id="Microsoft.AspNetCore.Http.Features" version="2.1.0" />
2018-11-02 16:45:47 +00:00
Tom Hvitved
665173692c C#: Fix whitespaces 2018-10-30 13:15:46 +01:00
Tom Hvitved
e76e448953 C#: Unify logic in guards library
Unify the logic for Boolean/nullness/matching guards.
2018-10-30 13:15:15 +01:00
Tom Hvitved
3f6fb0f573 Merge pull request #364 from calumgrant/cs/extractor/fix-violations
C#: Remove results from cs/local-shadows-member
2018-10-29 11:25:23 +01:00
calumgrant
ec2bf914c8 Merge pull request #339 from hvitved/csharp/cfg/assertions
C#: Detect constantly failing assertions in the CFG
2018-10-26 10:32:23 +01:00
Tom Hvitved
a3d74b00e0 C#: Address review comments 2018-10-25 14:15:09 +02:00
calum
3041756207 C#: Allow constructor parameters to shadow class members. 2018-10-24 17:48:51 +01:00
calum
5a4af0c2b2 C#: Update test case for LockOrder. 2018-10-19 18:13:03 +01:00
calum
5864e57398 C#: Improvements to LockOrder.ql. Detect inter-procedural locks, and tidy up the tests. 2018-10-19 18:11:49 +01:00
calum
61232cb08e C#: Address review comments in QL. 2018-10-19 16:33:04 +01:00
Tom Hvitved
515d6b6d26 C#: Detect constantly failing assertions in the CFG 2018-10-19 14:07:40 +02:00
Tom Hvitved
acea4ddfc4 C#: Introduce control flow exit completions 2018-10-19 14:07:35 +02:00
Tom Hvitved
0c1db6afc3 C#: Add more CFG tests
Added tests for exits inside `try` statements and constantly failing assertions.
2018-10-19 14:05:30 +02:00
Tom Hvitved
b233961a9a C#: Add assertion tests 2018-10-19 14:05:30 +02:00
calum
3de1f3b101 C#: Query and qltest for VulnerablePackage. 2018-10-18 10:23:51 +01:00
Tom Hvitved
603c3d6a43 C#: Teach null-guards library about pattern matching 2018-10-15 10:55:16 +02:00
semmle-qlci
76af2d2e3d Merge pull request #249 from hvitved/csharp/cfg/boolean-splitting
Approved by calumgrant
2018-10-11 20:14:37 +01:00
Tom Hvitved
98db3f89c2 C#: Extend pre-SSA consistency tests 2018-10-11 13:59:06 +02:00
Tom Hvitved
c064b1f41d Merge pull request #103 from lukecartey/csharp/zipslip-update
C#: ZipSlip - Refine sanitizers
2018-10-10 10:47:23 +02:00
Max Schaefer
2d8f424ce8 C#: Convert tests/query-tests/Stubs/Test.cs to Unix line endings. 2018-10-09 13:01:00 +01:00
Tom Hvitved
8df657c9f0 Merge pull request #217 from calumgrant/cs/make_stubs
C#: Tool to generate stubs for qltests
2018-10-09 09:59:53 +02:00
Tom Hvitved
4ca10986cb C#: Remove queries.xml from the Metrics folder 2018-10-04 11:13:01 +02:00
Luke Cartey
1a90f7df2c C#: ZipSlip - Address review comments.
- Add backticks
 - Add extra test.
2018-10-03 11:38:48 +01:00
Tom Hvitved
e8cd99335a C#: Simple Boolean control flow graph splitting 2018-09-28 14:59:39 +02:00
Tom Hvitved
d0f63ca303 C#: Introduce SplitKind class 2018-09-28 14:59:39 +02:00
Tom Hvitved
05e00ab05b C#: Fix whitespaces 2018-09-28 14:59:39 +02:00
Tom Hvitved
a48d77f7b8 C#: Add internal PreSsa library 2018-09-28 14:59:38 +02:00
Tom Hvitved
b8caa117f1 C#: Add internal PreBasicBlocks library 2018-09-28 14:59:38 +02:00
Dave Bartolomeo
1f36f5552f Normalize all text files to LF
Use `* text=auto eol=lf`
2018-09-23 16:24:31 -07:00
Dave Bartolomeo
26abf5d4a2 Force LF for basically everything. 2018-09-23 16:24:31 -07:00
calum
abe5d0dd72 C#: Fixes to stub generation. 2018-09-21 13:06:33 +01:00
calum
593f0a9d71 C#: Implement query and script for generating C# qltest stubs. 2018-09-20 15:01:26 +01:00
Tom Hvitved
70e713122f Merge branch 'rc/1.18' into merge-rc 2018-09-11 09:11:03 +02:00
calum
ecb3efba34 C#: Fix merge conflicts. 2018-09-07 18:12:28 +01:00
calum
9ec2172dca C#: Fix CFG for unknown expressions, and add a test that also covers object initializer lists fixed by the extractor. 2018-09-07 17:56:44 +01:00
Tom Hvitved
04f29951a5 Merge pull request #98 from calumgrant/cs/literal-conversion-fix
C#: Regression test for extractor
2018-09-07 08:42:00 +02:00
calum
d5eacf8c13 C#: Change expected output. Address review comments. 2018-09-06 18:20:01 +01:00