Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
pub
frama-c
Commits
053f0d3a
Commit
053f0d3a
authored
Jan 16, 2023
by
Allan Blanchard
Browse files
Merge branch 'fix/yojson-2' into 'master'
Upgrades tests to yojson 2 See merge request frama-c/frama-c!4047
parents
ba8e91fe
05bf596a
Changes
8
Expand all
Hide whitespace changes
Inline
Side-by-side
nix/yojson.nix
View file @
053f0d3a
{
lib
,
fetchurl
,
buildDunePackage
,
cppo
,
easy-format
,
biniou
}:
{
lib
,
fetchurl
,
buildDunePackage
,
cppo
,
seq
}:
buildDunePackage
rec
{
pname
=
"yojson"
;
version
=
"
1.7.0
"
;
version
=
"
2.0.2
"
;
useDune2
=
true
;
src
=
fetchurl
{
url
=
"https://github.com/ocaml-community/yojson/releases/download/
${
version
}
/yojson-
${
version
}
.tbz"
;
sha256
=
"
1iich6323npvvs8r50lkr4pxxqm9mf6w67cnid7jg1j1g5gwcvv5
"
;
sha256
=
"
sha256-h2u284r3OoSilDij2jXkhXxgoUVWpgZSWxSMb9vlRhs=
"
;
};
nativeBuildInputs
=
[
cppo
];
propagatedBuildInputs
=
[
easy-format
biniou
];
propagatedBuildInputs
=
[
seq
];
meta
=
with
lib
;
{
description
=
"An optimized parsing and printing library for the JSON format"
;
...
...
opam
View file @
053f0d3a
...
...
@@ -121,7 +121,7 @@ depends: [
"ocamlfind" # needed beyond build stage, used by -load-module
"ocamlgraph" { >= "1.8.8" }
"why3" { >= "1.5.1" }
"yojson" {>= "1.6.0" & (
<
"2.0.
0
" | !with-test)}
"yojson" {>= "1.6.0" & (
>=
"2.0.
1
" | !with-test)}
"zarith" { >= "1.5" }
# PPXs
...
...
reference-configuration.md
View file @
053f0d3a
...
...
@@ -14,5 +14,5 @@ compiling Frama-C+dev.
-
ppx_deriving_yojson.3.7.0
-
ppx_import.1.10.0
-
why3.1.5.1
-
yojson.
1.7.0
-
yojson.
2.0.2
-
zarith.1.12
src/plugins/markdown-report/tests/sarif/oracle/cwe125.sarif
View file @
053f0d3a
{
"$schema":
"https://raw.githubusercontent.com/oasis-tcs/sarif-spec/master/Schemata/sarif-schema-2.1.0.json",
"$schema": "https://raw.githubusercontent.com/oasis-tcs/sarif-spec/master/Schemata/sarif-schema-2.1.0.json",
"version": "2.1.0",
"runs": [
{
...
...
@@ -15,8 +14,7 @@
},
"invocations": [
{
"commandLine":
"frama-c -check -no-autoload-plugins -add-symbolic-path=PTEST_SESSION:. -load-plugin=eva,from,scope,inout,markdown-report cwe125.c -save ./cwe125_parse.sav",
"commandLine": "frama-c -check -no-autoload-plugins -add-symbolic-path=PTEST_SESSION:. -load-plugin=eva,from,scope,inout,markdown-report cwe125.c -save ./cwe125_parse.sav",
"arguments": [
"-check", "-no-autoload-plugins",
"-add-symbolic-path=PTEST_SESSION:.",
...
...
@@ -27,8 +25,7 @@
"executionSuccessful": true
},
{
"commandLine":
"frama-c -check -no-autoload-plugins -add-symbolic-path=PTEST_SESSION:. -load-plugin=eva,from,scope,inout,markdown-report -load ./cwe125_parse.sav -eva -save ./cwe125_eva.sav",
"commandLine": "frama-c -check -no-autoload-plugins -add-symbolic-path=PTEST_SESSION:. -load-plugin=eva,from,scope,inout,markdown-report -load ./cwe125_parse.sav -eva -save ./cwe125_eva.sav",
"arguments": [
"-check", "-no-autoload-plugins",
"-add-symbolic-path=PTEST_SESSION:.",
...
...
@@ -39,8 +36,7 @@
"executionSuccessful": true
},
{
"commandLine":
"frama-c -check -no-autoload-plugins -add-symbolic-path=PTEST_SESSION:. -load-plugin=eva,from,scope,inout,markdown-report -load ./cwe125_eva.sav -then -mdr-out ./cwe125.sarif.unfiltered -mdr-gen sarif -mdr-no-print-libc -mdr-sarif-deterministic",
"commandLine": "frama-c -check -no-autoload-plugins -add-symbolic-path=PTEST_SESSION:. -load-plugin=eva,from,scope,inout,markdown-report -load ./cwe125_eva.sav -then -mdr-out ./cwe125.sarif.unfiltered -mdr-gen sarif -mdr-no-print-libc -mdr-sarif-deterministic",
"arguments": [
"-check", "-no-autoload-plugins",
"-add-symbolic-path=PTEST_SESSION:.",
...
...
@@ -71,8 +67,7 @@
"level": "none",
"message": {
"text": "mem_access.",
"markdown":
"mem_access:\n\n```acsl\nassert mem_access: \\valid_read(array + index);\n```\n\n\n\nThis alarm represents a potential Invalid pointer dereferencing."
"markdown": "mem_access:\n\n```acsl\nassert mem_access: \\valid_read(array + index);\n```\n\n\n\nThis alarm represents a potential Invalid pointer dereferencing."
},
"locations": [
{
...
...
@@ -94,8 +89,7 @@
"level": "error",
"message": {
"text": "mem_access.",
"markdown":
"mem_access:\n\n```acsl\nassert mem_access: \\valid_read(array + index);\n```\n\n\n\nThis alarm represents a potential Invalid pointer dereferencing."
"markdown": "mem_access:\n\n```acsl\nassert mem_access: \\valid_read(array + index);\n```\n\n\n\nThis alarm represents a potential Invalid pointer dereferencing."
},
"locations": [
{
...
...
src/plugins/markdown-report/tests/sarif/oracle/std_string.sarif
View file @
053f0d3a
This diff is collapsed.
Click to expand it.
src/plugins/markdown-report/tests/sarif/oracle/with-libc.sarif
View file @
053f0d3a
{
"$schema":
"https://raw.githubusercontent.com/oasis-tcs/sarif-spec/master/Schemata/sarif-schema-2.1.0.json",
"$schema": "https://raw.githubusercontent.com/oasis-tcs/sarif-spec/master/Schemata/sarif-schema-2.1.0.json",
"version": "2.1.0",
"runs": [
{
...
...
@@ -15,8 +14,7 @@
},
"invocations": [
{
"commandLine":
"frama-c -check -no-autoload-plugins -add-symbolic-path=PTEST_SESSION:. -load-plugin=eva,from,scope,inout,markdown-report -eva -eva-no-results -mdr-gen sarif -mdr-sarif-deterministic libc.c -mdr-out ./with-libc.sarif.unfiltered",
"commandLine": "frama-c -check -no-autoload-plugins -add-symbolic-path=PTEST_SESSION:. -load-plugin=eva,from,scope,inout,markdown-report -eva -eva-no-results -mdr-gen sarif -mdr-sarif-deterministic libc.c -mdr-out ./with-libc.sarif.unfiltered",
"arguments": [
"-check", "-no-autoload-plugins",
"-add-symbolic-path=PTEST_SESSION:.",
...
...
@@ -1265,8 +1263,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *((char *)s + (0 .. n - 1)) in function bzero."
"text": "from clause of term *((char *)s + (0 .. n - 1)) in function bzero."
},
"locations": [
{
...
...
@@ -2030,8 +2027,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *((char *)dest + (0 .. n - 1)) in function memcpy."
"text": "from clause of term *((char *)dest + (0 .. n - 1)) in function memcpy."
},
"locations": [
{
...
...
@@ -2219,8 +2215,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *((char *)dest + (0 .. n - 1)) in function memmove."
"text": "from clause of term *((char *)dest + (0 .. n - 1)) in function memmove."
},
"locations": [
{
...
...
@@ -2431,8 +2426,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *((char *)dest + (0 .. n - 1)) in function mempcpy."
"text": "from clause of term *((char *)dest + (0 .. n - 1)) in function mempcpy."
},
"locations": [
{
...
...
@@ -2597,8 +2591,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *((char *)s + (0 .. n - 1)) in function memset."
"text": "from clause of term *((char *)s + (0 .. n - 1)) in function memset."
},
"locations": [
{
...
...
@@ -2809,8 +2802,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *(dest + (0 .. strlen{Old}(src))) in function stpcpy."
"text": "from clause of term *(dest + (0 .. strlen{Old}(src))) in function stpcpy."
},
"locations": [
{
...
...
@@ -3324,8 +3316,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *(dest +\n (strlen{Old}(dest) ..\n strlen{Old}(dest) +\n strlen{Old}(src))) in function strcat."
"text": "from clause of term *(dest +\n (strlen{Old}(dest) ..\n strlen{Old}(dest) +\n strlen{Old}(src))) in function strcat."
},
"locations": [
{
...
...
@@ -4280,8 +4271,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *(dest + (0 .. strlen{Old}(src))) in function strcpy."
"text": "from clause of term *(dest + (0 .. strlen{Old}(src))) in function strcpy."
},
"locations": [
{
...
...
@@ -4747,8 +4737,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term __fc_heap_status in function strdup."
"text": "from clause of term __fc_heap_status in function strdup."
},
"locations": [
{
...
...
@@ -5172,8 +5161,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *(dest + (strlen{Old}(dest) .. n)) in function strlcat."
"text": "from clause of term *(dest + (strlen{Old}(dest) .. n)) in function strlcat."
},
"locations": [
{
...
...
@@ -5384,8 +5372,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *(dest + (0 .. n - 1)) in function strlcpy."
"text": "from clause of term *(dest + (0 .. n - 1)) in function strlcpy."
},
"locations": [
{
...
...
@@ -6014,8 +6001,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *(dest +\n (strlen{Old}(dest) ..\n strlen{Old}(dest) +\n strlen{Old}(src))) in function strncat."
"text": "from clause of term *(dest +\n (strlen{Old}(dest) ..\n strlen{Old}(dest) +\n strlen{Old}(src))) in function strncat."
},
"locations": [
{
...
...
@@ -6065,8 +6051,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *(dest + (strlen{Old}(dest) .. strlen{Old}(dest) + n)) in function strncat."
"text": "from clause of term *(dest + (strlen{Old}(dest) .. strlen{Old}(dest) + n)) in function strncat."
},
"locations": [
{
...
...
@@ -6116,8 +6101,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *(dest + (strlen{Old}(dest) .. strlen{Old}(dest) + n)) in function strncat."
"text": "from clause of term *(dest + (strlen{Old}(dest) .. strlen{Old}(dest) + n)) in function strncat."
},
"locations": [
{
...
...
@@ -6606,8 +6590,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *(dest + (0 .. n - 1)) in function strncpy."
"text": "from clause of term *(dest + (0 .. n - 1)) in function strncpy."
},
"locations": [
{
...
...
@@ -6937,8 +6920,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term __fc_heap_status in function strndup."
"text": "from clause of term __fc_heap_status in function strndup."
},
"locations": [
{
...
...
@@ -8626,8 +8608,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *(__fc_strtok_ptr + (0 ..)) in function strtok."
"text": "from clause of term *(__fc_strtok_ptr + (0 ..)) in function strtok."
},
"locations": [
{
...
...
@@ -8777,8 +8758,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *(__fc_strtok_ptr + (0 ..)) in function strtok."
"text": "from clause of term *(__fc_strtok_ptr + (0 ..)) in function strtok."
},
"locations": [
{
...
...
@@ -9338,8 +9318,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *(*saveptr + (0 ..)) in function strtok_r."
"text": "from clause of term *(*saveptr + (0 ..)) in function strtok_r."
},
"locations": [
{
...
...
@@ -9489,8 +9468,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *(*saveptr + (0 ..)) in function strtok_r."
"text": "from clause of term *(*saveptr + (0 ..)) in function strtok_r."
},
"locations": [
{
...
...
@@ -9703,8 +9681,7 @@
"kind": "pass",
"level": "none",
"message": {
"text":
"from clause of term *(dest + (0 .. n - 1)) in function strxfrm."
"text": "from clause of term *(dest + (0 .. n - 1)) in function strxfrm."
},
"locations": [
{
...
...
src/plugins/markdown-report/tests/sarif/oracle/without-libc.sarif
View file @
053f0d3a
{
"$schema":
"https://raw.githubusercontent.com/oasis-tcs/sarif-spec/master/Schemata/sarif-schema-2.1.0.json",
"$schema": "https://raw.githubusercontent.com/oasis-tcs/sarif-spec/master/Schemata/sarif-schema-2.1.0.json",
"version": "2.1.0",
"runs": [
{
...
...
@@ -15,8 +14,7 @@
},
"invocations": [
{
"commandLine":
"frama-c -check -no-autoload-plugins -add-symbolic-path=PTEST_SESSION:. -load-plugin=eva,from,scope,inout,markdown-report -eva -eva-no-results -mdr-gen sarif -mdr-sarif-deterministic libc.c -mdr-no-print-libc -mdr-out ./without-libc.sarif.unfiltered",
"commandLine": "frama-c -check -no-autoload-plugins -add-symbolic-path=PTEST_SESSION:. -load-plugin=eva,from,scope,inout,markdown-report -eva -eva-no-results -mdr-gen sarif -mdr-sarif-deterministic libc.c -mdr-no-print-libc -mdr-out ./without-libc.sarif.unfiltered",
"arguments": [
"-check", "-no-autoload-plugins",
"-add-symbolic-path=PTEST_SESSION:.",
...
...
src/plugins/server/tests/batch/oracle/wrong.out.json
View file @
053f0d3a
...
...
@@ -2,8 +2,7 @@
{
"id"
:
"unknown request"
,
"error"
:
"request not found"
},
{
"id"
:
"wrong data"
,
"error"
:
"Expected string, got object:
\n
{
\"
f1
\"
: 1,
\"
f2
\"
: {
\"
x
\"
: 1,
\"
y
\"
: 2 },
\"
f3
\"
: null }"
,
"error"
:
"Expected string, got object:
\n
{
\"
f1
\"
: 1,
\"
f2
\"
: {
\"
x
\"
: 1,
\"
y
\"
: 2 },
\"
f3
\"
: null }"
,
"at"
:
{
"id"
:
"wrong data"
,
"request"
:
"kernel.ast.printFunction"
,
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment