You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
7 months ago | |
---|---|---|
.. | ||
Android.bp | 7 months ago | |
README.md | 7 months ago | |
media_log_fuzzer.cpp | 7 months ago |
README.md
Fuzzer for libmedialogservice
Plugin Design Considerations
The fuzzer plugin for libmedialogservice is designed based on the understanding of the service and tries to achieve the following:
Maximize code coverage
The configuration parameters are not hardcoded, but instead selected based on incoming data. This ensures more code paths are reached by the fuzzer.
medialogservice supports the following parameters:
- Writer name (parameter name:
writerNameIdx
) - Log size (parameter name:
logSize
) - Enable dump before unrgister API (parameter name:
shouldDumpBeforeUnregister
) - size of string for log dump (parameter name:
numberOfLines
)
Parameter | Valid Values | Configured Value |
---|---|---|
writerNameIdx |
0. 0 1. 1 |
Value obtained from FuzzedDataProvider |
logSize |
In the range 256 to 65536 |
Value obtained from FuzzedDataProvider |
shouldDumpBeforeUnregister |
0. 0 1. 1 |
Value obtained from FuzzedDataProvider |
numberOfLines |
In the range 0 to 65535 |
Value obtained from FuzzedDataProvider |
This also ensures that the plugin is always deterministic for any given input.
Build
This describes steps to build media_log_fuzzer binary.
Android
Steps to build
Build the fuzzer
$ mm -j$(nproc) media_log_fuzzer
Steps to run
Create a directory CORPUS_DIR and copy some files to that folder Push this directory to device.
To run on device
$ adb sync data
$ adb shell /data/fuzz/arm64/media_log_fuzzer/media_log_fuzzer CORPUS_DIR