tree: d474e9ad0a5512548acd2432110198b67635703d [path history] [tgz]
  1. src/
  2. README.md
src/connectivity/wlan/wlancfg/fuzz/README.md

WLAN Fuzz Test

What is tested

The fuzz test in this directory tests the SavedNetworksManager. It tests the storing, looking up, and persistence of saved networks. The SSID and credentials to save are fuzzed.

Where to see fuzz test results

The fuzz test can be run locally using ffx fuzz. Fuchsia fuzzers also run regularly on ClusterFuzz and bugs are filed for failing tests on Monorail.

More information can be found on the Fuchsia site fuzzing page

Adding Tests

More tests can be easily added alongside the existing fuzz test. Tests can be written similar to unit tests, but with the fuzz attribute and with variables to be fuzzed set as test arguments.

In this fuzz test, NetworkIdentifier and Credential can be used as fuzz input because they derive the Arbitrary trait. If another type is needed and does not already implement Arbitrary, the Arbitrary trait can be derived for that type or the value can be constructed within the fuzz test using a buffer of bytes.

For more information, go to the Fuchsia doc for writing a fuzzer.