Commit Graph

1503 Commits

Author SHA1 Message Date
4d7ccd2d86 port resultbrowser to python3 2021-12-15 00:30:10 +01:00
da7af918c6 port faultspaceplot to python3 2021-12-15 00:28:42 +01:00
e52ece5aed README updates
- replace danceos.org links (danceos.org is permanently out of
  service)
- add dissertation link

This fixes #10.

Change-Id: I27278db1b36f94727a710ea7998374ecf5a60297
2021-08-01 23:56:47 +02:00
7bdefb6849 generic-tracing: --catch-trap aborts when a trap is observed
Enabling --catch-trap makes sure tracing aborts with an error message
in case a CPU exception/trap is observed in the fault-free golden run.
In most cases, this is an indication the analyzed program is broken in
the first place, which should be detected early in the FI process.

This is a refurbished version of a commit by Marcel Johannfunke.

Change-Id: I50cc8e12e0986d3623a1be78259cfad13dc56205
2021-07-27 16:28:37 +02:00
67f1be840f prune-trace: correctly handle 0 trace entries
If the analyzed program does not read any memory, or the reading
memory accesses are filtered out in the import step (import-trace -m),
the trace table may hold no entries for the program.  This commit
makes sure the SamplingPruner and FESamplingPruner deal properly with
this situation.

Change-Id: I6bb5da23f345fa97cf8ab0b688cce5d00945249a
2021-07-27 16:28:37 +02:00
3b7404de43 import-trace: add --cover-memorymap switch
This compatibility-breaking change introduces the --cover-memorymap
switch to import-trace.  It makes a previous behavior optional, which
enforces DB entries for addresses covered by the --memorymap that
don't occur in the trace.  This creates a continuous and potentially
very large fault space in the DB, which never made any real sense.

Change-Id: I47e412bb621b595748c1772e02d2577308be8664
2021-07-27 16:28:37 +02:00
6598520c0a fix small bug in assertion caused by incorrect spelling 2021-07-13 08:09:25 +02:00
355015fb64 generic-tracing: fix bounds-checking mode
This fixes a bug (uninitialized member variable check_bounds)
introduced in commit 43ebf3e, which led to bounds checking sometimes
being accidentally enabled.

Change-Id: Ia2992a38dd83416ce0ec2a9d845d7827617cbd89
2021-03-26 15:40:20 +01:00
2fd5c20a7c bochs: backport decoding of CRC32 instr fix
Upstream SVN r10223
Backport was neccessary, because the CRC32 assambly instruction
did not work as expected in bochs.
2021-03-24 20:12:53 +01:00
18b3203257 enlarge varchar of name to bigger value in the symbol table
Some benchmarks need this space for the function name, because of name mangling.
2021-03-24 20:05:11 +01:00
f33b4bac22 [generic-experiment] Fix whitespace in .proto file 2020-12-18 18:19:52 +01:00
4489537b4d [generic-experiment] WRITE_OUTERSPACE -> ACCESS_OUTERSPACE
This is a breaking change. However, the name is and always was
misleading. Therefore, we change it to the correct name.
2020-12-18 18:19:52 +01:00
d35ae687b0 [generic-experiment] Correct names for argument names
As the outerspace listeners catch read and write accesses, this must
be documented in the help message. The old parameter name is now marked as
deprecated and can be removed in 2022.

Furthmore, the experiment now has the combined command line argument
--catch-outerspace, which enables catching accesses below and above
the ELF.
2020-12-18 18:19:52 +01:00
625756f338 [generic-experiment] improve the injector logging 2020-12-18 18:19:52 +01:00
43ebf3ee81 [generic-tracing] add check-bound mode
During the trace generation, we can enable the bounds check, which
catches all events that are monitored by the generic-experiement
options:

  --catch-write-textsegment
  --catch-upper-outerspace
  --catch-lower-outerspace
2020-12-18 18:19:52 +01:00
eb43273e9b [generic-experiment] make text segment listener, listen only to writes
The generic experiment set the TriggerAccessType not the
WatchAccessType. Therefore, the text segment listener fired on write
AND read events. The watch access type can only be set in the constructor.
2020-12-18 18:19:52 +01:00
cd150a6f5b [generic-experiment/ElfReader] access listeners based on ELF segments
This patch uses ELF segments instead of section for determining the
extent of the binary in memory. Consequently, the outerspace listener
was modified to use these new bounds. Additionally, the generic
experiment was changed to include a lowerspace listener, which listens
for write access below the physical memory location of the ELF.
2020-12-18 18:19:52 +01:00
86267cce9f DatabaseCampaign: increase progress report interval
Change-Id: I439bf16b98fb11f89ece398fcaf13cc4fa2dd4cd
2020-12-16 15:39:39 +01:00
c148b70b55 DatabaseCampaign: bail out on query failures
Change-Id: If76d4a2d391879e5e12b65ef593b35436cb0e34d
2020-12-16 15:39:39 +01:00
f2e8c508de DatabaseCampaign: fix progress bar for >1 variant
Change-Id: I21843249830c67699214b6bed71f452b6ca03cb2
2020-12-16 15:39:39 +01:00
c422a86bfd cmake: fix boost version dependency
Change-Id: Icec5121440c189ebd8bc26d2366730d332055dbc
2020-12-16 15:39:39 +01:00
bd7cf9c922 ecos_kernel_test: formatting
Change-Id: I4bccb9a7c4fe286c34f4a74ad641e9107039c47b
2020-12-16 15:39:39 +01:00
b516f2f07f Database: doc fixes
Change-Id: I6304e4379ee0d94bd816b968eb5f08a281cfd0b4
2020-12-16 15:39:39 +01:00
54155b1fe5 capstone: fix missing build dependency
Change-Id: I890871323ecdfec09c2bd25cfede50fd0712d5cd
2020-12-16 15:39:39 +01:00
c5d7b19752 perf: call onDeletion in the right places
Change-Id: I920aacec475d8ec3f51e11bcb59f37b84a730ee7
2020-12-16 15:39:39 +01:00
28cf14cf00 ElfReader: compilation fix
Change-Id: I60e60e795154ffb270592b206dbfd85c3837bfc8
2020-12-16 15:39:39 +01:00
5929eac85c SimulatorController: Selection between multiple experiments
If the user enabled multiple experiments, it does not make sense to
execute them concurrently. Therefore, we now only register all enabled
experiments and choose one experiment on fail-client startup. For this
selection, the user can either set the FAIL_EXPERIMENT environment
variable or invoke the tool with a specific argv[0]. For the
bin/-folder, we create symlinks for this mechanism.

With this change, the generic-tracing and generic-experiment can be
compiled into the same executable and we could distribute a "standard"
version of FAIL*.
2020-12-16 15:38:29 +01:00
2ecdba92a5 [generic-experiment] allow passing state directory via environment 2020-12-16 15:38:29 +01:00
f92b930acb tools/tests: small end-to-end test suite for importing/pruning
As bigger changes lie ahead, we want a small end-to-end test suite
that ensures that our importing and tracing does not fall apart. With
this change, we add the infrastructure and two test-cases (fib, qsort)
including ELFs, traces, and injection results.

In order to run the basic-pruner test cases, one needs to setup a
MySQL table and set the CMake option ENABLE_DATABASE_TESTS.
2020-12-16 15:38:29 +01:00
df44da9f33 DatabaseExperiment: Use google::protobuf::Reflection
The previous path google::protobuf::Message::Reflection was deprecated
in 2008 (779f61c6a3ce02a119e28e802f229e61b69b9046), and we only used
it here. With newer versions of proto-c, this breaks the build.
2020-12-16 15:38:29 +01:00
973716ff35 Database: fix typo in command line argument
This is an API breaking change. Nevertheless, help text and
command-line parser were out of sync and the variant of the help-text
does make much more sense.
2020-12-16 15:38:29 +01:00
743e746e0f editorconfig: add .editorfile to support a consistent coding style 2020-12-16 15:38:29 +01:00
d296f15652 dump-trace: record the number of memory fault locations
With the number of accessed memory addresses and the duration of the
trace, we can deduce the size of the rectangular memory fault space.
This will be used in testing.
2020-12-16 15:38:29 +01:00
8421e1ef03 import-trace: diagnostics typo
Change-Id: Ic02f66884a300dd081c61ac911cd3d5767f08744
2020-07-06 17:33:04 +02:00
5e80a59058 qemu: incomplete QEMUx86CPU implementation
Change-Id: I3598e420f95e75523895f8cf496f443a92a687ec
2020-06-08 16:29:43 +02:00
cd31e27e97 Merge branch 'qemu-fixes'
Change-Id: I2154750088405bd552020e6ebe6982ee05df3b16
2020-06-08 09:58:26 +02:00
f9ed535c4a qemu: configuration-related fixes
+ Make it compile again.  Why was qemu/lol.h ever committed?

Change-Id: I398d3b9821072ca104630104270df4de2b91464a
2020-06-08 09:57:37 +02:00
e17dfe9c3a capstone: fix compilation
The removed line seems to have been overlooked when
reordering/splitting commits.

Change-Id: Idb6e7f69d76b3f6c8268cf08a85ab756c442d6fc
2020-05-24 19:26:29 +02:00
73b246c7df capstone: debug stuff, cleanup
Change-Id: Ia831c20097e86d1f178efb09884a60caa542f12a
2020-05-23 22:52:00 +02:00
1dd929aad5 capstone: only use insn.detail if it's not NULL
Capstone NULLs the detail field when it encounters a bad/invalid opcode.

Change-Id: I421386903756e03049e950f09b8a500b54fe4a73
2020-05-23 22:52:00 +02:00
0c38fd7345 capstone: disassemble .text also for STT_NOTYPE
Symbol type FUNC (STT_FUNC, "code object") seems not to suffice when parts
of the disassembled binary come from assembler source files.  We try to
disassemble STT_NOTYPE (symbol type "unspecified") as well now.

Change-Id: I582190900e66d6af0779dfaf3b569f0e157e9ce7
2020-05-23 22:52:00 +02:00
33d40df4bd DatabaseCampaign/-Experiment: add randomjump faults
Taken from experiments/erika-tester.

Change-Id: Ic1aa72d1bfc839009297892cf9e50b3edb53fef9
2020-05-23 22:52:00 +02:00
dc73349a4d bochs: restore original RIP increase behavior
The now commented-out variant that was introduced in commit be9d291
(when FAIL* was still in an SVN repo, r1702) may be necessary for some
specific system behavior after modifying the currently executed
instruction, but breaks random-jump FI (import-trace -i
RandomJumpImporter).

Change-Id: I1ef3dc6dceab66b01cddd988e0f201065e404f99
2020-05-23 22:52:00 +02:00
8d1657a409 cmake: use -std=c++11 instead of c++14
With GCC 9, some of the stdlibc++'s header files don't compile with
AspectC++ anymore.  Until this is resolved, we compile with -std=c++11
although we actually use C++14 features; we need to ignore the
warnings pointing this out until AspectC++ works with these header
files.

Change-Id: If4d3c9fcbee61b7f8c6ffdf7f1ef9a641b6b6743
2020-05-20 10:08:47 +02:00
0dc0225dfa import-trace: diagnose missing ELF in RandomJumpImporter
Change-Id: Iede6947713f9e857e1d7c96f8d49e155ac4f59e5
2020-05-13 17:26:44 +02:00
d625021c2e Merge branch 'capstone'
Change-Id: I66475d1dfa2136f388db80d4ff39e181c4c857f7
2020-03-17 11:56:09 +01:00
25d153e037 README updates (publications, Docker note)
Change-Id: Iaac09495245bfebe0809999854c480b848ea49fb
2020-03-17 10:40:37 +01:00
039fa7bedf doc: explain how to build w/ Capstone
Change-Id: Ifc72117838e402fc432521bd10284dd0e61ca6b4
2020-03-16 18:49:44 +01:00
b94ef2acec capstone: deal properly with symbols outside .text section
Especially for dynamically linked ELF binaries (such as those in the
testing/ subdirectory), symbols with a start address outside the .text
section may exist.  This change skips any symbol that is not fully within
this section (and assigns a reasonable size to a zero-sized last symbol
within the symbol table), and turns green all Capstone-related test cases.

Change-Id: I2b51d0f21f325e6052ebc36d9533621bdf9aa38d
2020-03-16 18:49:44 +01:00
4e07ba50bd capstone: add missing disassembler test cases
Change-Id: I81e7f2ae9e70137c775f04a0a98c922e50b3743d
2020-03-16 18:49:44 +01:00