You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+32-18Lines changed: 32 additions & 18 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,24 +12,24 @@ We collected several different systems running on the JVM, in different programm
12
12
In this documentation, we will refer to these projects as System Under Test (SUT).
13
13
Currently, the SUTs are either _REST_, _GraphQL_ or _RPC_ APIs.
14
14
15
-
This dataset was previously known as EMB. It was rebranded into WFD since version 4.0.0.
15
+
> This dataset was previously known as EMB. It was rebranded into WFD since version 4.0.0.
16
16
17
17
This collection of SUTs was originally assembled for easing experimentation with the fuzzer called [EvoMaster](http://evomaster.org).
18
18
However, finding this type of application is not trivial among open-source projects.
19
19
Furthermore, it is not simple to sort out all the technical details on how to set these applications up and start them in a simple, uniform approach.
20
20
Therefore, this repository provides the important contribution of providing all these necessary scripts for researchers that need this kind of case study.
21
21
22
-
__Black-box Testing__. For each SUT, we provide Docker Compose scripts to start the APIs with all their needed dependencies (e.g., databases). APIs are configured with mitmproxy and JaCoCo to collect information on the fuzzing results.
22
+
__Black-box Testing__. For each SUT, we provide Docker Compose scripts (under the [dockerfiles](dockerfiles) folder) to start the APIs with all their needed dependencies (e.g., databases). APIs are configured with _mitmproxy_ and _JaCoCo_ to collect information on the fuzzing results.
23
23
24
-
__White-box Testing__. For each SUT, we implemented _driver_ classes, which can programmatically _start_, _stop_ and _reset_ the state of SUT (e.g., data in SQL databases).
24
+
__White-box Testing__. For each SUT, we implemented _driver_ classes for _EvoMaster_ (currently the only existing white-box fuzzer for the JVM), which can programmatically _start_, _stop_ and _reset_ the state of SUT (e.g., data in SQL databases).
25
25
As well as enable setting up different properties in a _uniform_ way, like choosing TCP port numbers for the HTTP servers.
26
26
If a SUT uses any external services (e.g., a SQL database), these will be automatically started via Docker in these driver classes.
27
27
28
-
**NOTE**: version 1.6.1 was last one in which we still updated drivers for JavaScript and C\#. Those SUTs are not built anymore by default, and latest versions of *EvoMaster* might not work on those old drivers. Updating drivers for different programming languages (and re-implement white-box heuristics) is a massive amount of work, which unfortunately has little to no value for the scientific community (based on our experience). Those SUTs are still here in WFD to enable *black-box* experiments (and to be able to replicate old experiments), but unfortunately not for *white-box* testing with latest versions of *EvoMaster*.
28
+
**NOTE**: version 1.6.1 was last one in which we still updated drivers for JavaScript and C\#. Those SUTs are not built anymore by default, and latest versions of *EvoMaster* might not work on those old drivers. Updating drivers for different programming languages (and re-implement white-box heuristics) is a massive amount of work, which unfortunately has little to no value for the scientific community (based on our experience). Those SUTs are still here in WFD to be able to replicate old experiments, but unfortunately not for *white-box* testing with latest versions of *EvoMaster*.
29
29
30
30
31
31
32
-
A video providing some high level overview of EMB can be found [here](https://youtu.be/wJs34ATgLEw).
32
+
An old video (2023) providing some high level overview of EMB can be found [here](https://youtu.be/wJs34ATgLEw).
@@ -58,6 +58,7 @@ In *IEEE International Conference on Software Testing, Validation and Verificati
58
58
The projects were selected based on searches using keywords on GitHub APIs, using convenience sampling.
59
59
Several SUTs were looked at, in which we discarded the ones that would not compile, would crash at startup, would use obscure/unpopular libraries with no documentation to get them started, are too trivial, student projects, etc.
60
60
Where possible, we tried to prioritize/sort based on number of _stars_ on GitHub.
61
+
When authors of other fuzzers used some other open-source JVM APIs in their studies, we included them here into WFD.
61
62
62
63
63
64
Note that some of these open-source projects might be no longer supported, whereas others are still developed and updated.
@@ -73,6 +74,10 @@ For simplicity, all schemas are also available as JSON/YML files under the folde
73
74
74
75
> **IMPORTANT**: More details (e.g., #LOCs and used databases) on these APIs can be found [in this table](statistics/table_emb.md).
75
76
77
+
Real-world APIs require authentication.
78
+
How to setup authentication information, based on the current content of the initialized databases, is expressed in [Web Fuzzing Commons (WFC)](https://github.com/WebFuzzing/Commons) format.
79
+
Auth configuration files can found in the [auth](auth) folder.
80
+
76
81
77
82
### REST: Java/Kotlin (36)
78
83
@@ -238,14 +243,15 @@ To use WFD, you need to clone this repository:
Everything can be setup by running the script `scripts/dist.py`.
248
-
Note that you will need installed at least Maven, Gradle, JDK 8, JDK 11, JDK 17, NPM, as well as Docker.
254
+
Note that you will need installed at least Maven, Gradle, JDK 8, JDK 11, JDK 17, JDK 21, NPM, as well as Docker.
249
255
Also, you will need to setup environment variables like `JAVA_HOME_8`, `JAVA_HOME_11`, `JAVA_HOME_17` and `JAVA_HOME_21`.
250
256
The script will issue error messages if any prerequisite is missing.
251
257
Once the script is completed, all the SUTs will be available under the `dist` folder, and a `dist.zip` will be created as well (if `scripts/dist.py` is run with `True` as input).
@@ -301,14 +307,8 @@ In latest versions of Maven, you need to create an authorization token in GitHub
301
307
302
308
303
309
In the built `dist` folder, the files will be organized as follows:
304
-
`<name>-sut.jar` will be the non-instrumented SUTs, whereas their executable drivers will be called `<name>-evomaster-runner.jar`.
305
-
Instrumentation can be done at runtime by attaching the `evomaster-agent.jar` JavaAgent. If you are running experiments with EvoMaster, this will be automatically attached when running experiments with `exp.py` (available in the EvoMaster's repository). Or it can be attached manually with JVM option `-Devomaster.instrumentation.jar.path=evomaster-agent.jar` when starting the driver.
306
-
307
-
308
-
309
-
For running experiments with EvoMaster, you can also "start" each driver directly from an IDE (e.g., IntelliJ).
310
-
Each of these drivers has a "main" method that is running a REST API (binding on default port 40100), where each operation (like start/stop/reset the SUT) can be called via an HTTP message by EvoMaster.
311
-
310
+
`<name>-sut.jar` will be the non-instrumented SUTs, whereas their executable drivers for white-box testing will be called `<name>-evomaster-runner.jar`.
311
+
Instrumentation can be done at runtime by attaching the `evomaster-agent.jar` JavaAgent. If you are running experiments with EvoMaster, this will be automatically attached when running experiments with experiment scripts (discussed in next section). Or it can be attached manually with JVM option `-Devomaster.instrumentation.jar.path=evomaster-agent.jar` when starting the driver.
312
312
313
313
314
314
You can also build (and install) each module separately, based on needs.
@@ -325,11 +325,25 @@ For thr JVM, each module has 2 submodules, called `cs` (short for "Case Study")
325
325
`cs` contains all the source code of the different SUTs, whereas `em` contains all the drivers.
326
326
Note: building a top-module will build as well all of its internal submodules.
327
327
328
-
The driver classes for Java are called `EmbeddedEvoMasterController`.
328
+
The _EvoMaster_driver classes for Java are called `EmbeddedEvoMasterController`.
329
329
Note that Java also has a different kind of driver called `ExternalEvoMasterController`.
330
330
The difference is that in External the SUT is started on a separated process, and not running in the same JVM of the driver itself.
331
331
332
332
333
+
### Running Experiments
334
+
335
+
To simplify the running of experiments, we provide different scripts under the [experiments](experiments) folder:
336
+
337
+
1)__bb-exp.py__: to set up black-box experiments, generating Bash scripts.
338
+
2)__wb-exp.py__: to set up white-box experiments, generating Bash scripts.
339
+
3)__schedule.py__: to enable running and scheduling Bash job scripts in parallel.
340
+
341
+
342
+
343
+
For debugging/experimenting with EvoMaster in white-box testing, you can also "start" each driver directly from an IDE (e.g., IntelliJ).
344
+
Each of these drivers has a "main" method that is running a REST API (binding on default port 40100), where each operation (like start/stop/reset the SUT) can be called via an HTTP message by EvoMaster.
0 commit comments