{"id":13576740,"url":"https://github.com/curl/curl-fuzzer","last_synced_at":"2025-04-05T17:08:44.854Z","repository":{"id":25560434,"uuid":"104416990","full_name":"curl/curl-fuzzer","owner":"curl","description":"Quality assurance testing for the curl project","archived":false,"fork":false,"pushed_at":"2024-10-22T13:47:19.000Z","size":4827,"stargazers_count":85,"open_issues_count":14,"forks_count":30,"subscribers_count":14,"default_branch":"master","last_synced_at":"2024-10-29T15:32:23.822Z","etag":null,"topics":["curl","fuzzer","oss-fuzz","testcase"],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/curl.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-09-22T01:34:20.000Z","updated_at":"2024-10-28T16:47:19.000Z","dependencies_parsed_at":"2023-01-14T07:00:32.176Z","dependency_job_id":"6fb2de07-21c5-4f97-a0dd-3aae0f9103c9","html_url":"https://github.com/curl/curl-fuzzer","commit_stats":{"total_commits":181,"total_committers":10,"mean_commits":18.1,"dds":"0.37569060773480667","last_synced_commit":"24f27bd32b4f51a75256c413c6366a0befbec8ce"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/curl%2Fcurl-fuzzer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/curl%2Fcurl-fuzzer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/curl%2Fcurl-fuzzer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/curl%2Fcurl-fuzzer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/curl","download_url":"https://codeload.github.com/curl/curl-fuzzer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247334839,"owners_count":20922297,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["curl","fuzzer","oss-fuzz","testcase"],"created_at":"2024-08-01T15:01:13.377Z","updated_at":"2025-04-05T17:08:44.817Z","avatar_url":"https://github.com/curl.png","language":"C++","funding_links":[],"categories":["Networking Tools \u0026 Concepts","\u003ca name=\"cpp\"\u003e\u003c/a\u003eC++"],"sub_categories":["Configure WDT service","Enable Proton in Steam","viii. Linear Regression","JavaScript Libraries for Machine Learning"],"readme":"# curl-fuzzer\n\nCode and corpora for curl and libcurl fuzzing.\n\nThis is the curl fuzzing [OSS-Fuzz](https://github.com/google/oss-fuzz/tree/master/projects/curl) runs for us, non-stop.\n\n## I just want to get fuzzing!\n\nGreat! Run `./mainline.sh`. It will download you a fresh copy of curl, compile\nit with `clang`, install it to a temporary directory, then compile the fuzzer\nagainst curl. It'll also run the regression testcases.\n\nIf you have a local copy of curl that you want to use instead, pass the path as\nan argument to `./mainline.sh`. It will compile and install that curl to a\ntemporary directory instead.\n\n`./mainline.sh` is run regressibly by Github Actions.\n\n## I want more information when running a testcase or multiple testcases\n\nSetting the `FUZZ_VERBOSE` environment variable turns on curl verbose logging.\nThis can be useful when debugging a single testcase.\n\n## I want to download public corpus test files from OSS-Fuzz\n\nThe public corpus links for each target should be accessible here:\n\n- [curl_fuzzer_dict](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_dict/public.zip)\n- [curl_fuzzer_file](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_file/public.zip)\n- [curl_fuzzer_ftp](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_ftp/public.zip)\n- [curl_fuzzer_gopher](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_gopher/public.zip)\n- [curl_fuzzer_http](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_http/public.zip)\n- [curl_fuzzer_https](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_https/public.zip)\n- [curl_fuzzer_imap](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_imap/public.zip)\n- [curl_fuzzer_ldap](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_ldap/public.zip)\n- [curl_fuzzer_mqtt](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_mqtt/public.zip)\n- [curl_fuzzer_pop3](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_pop3/public.zip)\n- [curl_fuzzer_rtmp](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_rtmp/public.zip)\n- [curl_fuzzer_rtsp](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_rtsp/public.zip)\n- [curl_fuzzer_scp](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_scp/public.zip)\n- [curl_fuzzer_sftp](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_sftp/public.zip)\n- [curl_fuzzer_smb](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_smb/public.zip)\n- [curl_fuzzer_smtp](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_smtp/public.zip)\n- [curl_fuzzer_tftp](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_tftp/public.zip)\n- [curl_fuzzer_ws](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer_ws/public.zip)\n- [curl_fuzzer](https://storage.googleapis.com/curl-backup.clusterfuzz-external.appspot.com/corpus/libFuzzer/curl_fuzzer/public.zip)\n- fuzz_url: no public link yet.\n\n## I want to reproduce an error hit overnight by OSS-Fuzz\n\nCheck out [REPRODUCING.md](REPRODUCING.md) for more detailed instructions.\n\n## How do I install the Python tooling?\n\n- Create a virtual environment using your favourite method.\n  - For example:\n    ```shell\n    python3 -m venv .venv\n    ```\n- Within that virtual environment, from the root directory of this repository, install the tooling with\n  ```shell\n  pip install .\n  ```\n- Alternatively you can use `uv`; either\n  ```shell\n  uv sync\n  uv pip install -e .\n  ```\n  to sync your environment, or\n  ```shell\n  uv run \u003ctool\u003e\n  ```\n  directly.\n\n## What's in this testcase?\n\nTo look at the contents of a testcase, run\n```shell\nread_corpus \u003cpath/to/file\u003e\n```\nThis will print out a list of contents inside the file.\n\n## I want to generate a new testcase\n\nTo generate a new testcase, run\n```shell\ngenerate_corpus\n```\nwith appropriate options - pass `--help` for all options.\n\n# I want to enhance the fuzzer!\n\nWonderful! Here's a bit of information you may need to know.\n\n## File format\n\nTestcases are written in a Type-Length-Value or TLV format. Each TLV has:\n\n- 16 bits for the Type\n- 32 bits for the Length of the TLV data\n- 0 - length bytes of data.\n\nTLV type numbers are defined in both corpus.py and curl_fuzzer.h.\n\n## Adding a new TLV.\n\nTo add a new TLV:\n\n- Add support for it in the Python scripts: `generate_corpus.py`, `corpus.py`.\n  This means adding options for reading the value of the TLV from the user (or\n  from a file, or from test data)\n- Add support for it in the fuzzer: `curl_fuzzer.cc`, `curl_fuzzer.h`. This\n  likely means adding handling of the TLV to `fuzz_parse_tlv()`.\n- Ensure that `FUZZ_CURLOPT_TRACKER_SPACE` can encompass your additional TLVs!\n- If you decide to change a TLV number after you have created it and have\n  generated test cases before you changed the TLV, rerun the test case\n  generation to ensure your current TLV numbering maps your test cases as you\n  expect.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcurl%2Fcurl-fuzzer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcurl%2Fcurl-fuzzer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcurl%2Fcurl-fuzzer/lists"}