Skip to content

Add a fuzz harness for the FTP reply parsers - #2243

Open
xroche wants to merge 1 commit into
masterfrom
fuzz-ftp
Open

xroche wants to merge 1 commit into
masterfrom
fuzz-ftp

Conversation

@xroche

@xroche xroche commented Nov 14, 2026

Copy link
Copy Markdown
Owner

The harness reads FTP replies with get_ftp_line() over a socketpair and passes each one to the PASV, EPSV, SIZE and MDTM parsers. The same bytes also go through the URL splitters as an FTP link. ftp_parse_mdtm() is no longer static so the harness can call it, and a 10-minute ASan and UBSan run found no crash.

fuzz-ftp feeds its input to get_ftp_line() over a socketpair and runs
each reply line through the PASV, EPSV, SIZE and MDTM parsers; the same
bytes, read as a URL, go through the user, host and command splitters.
ftp_parse_mdtm() loses its static so the harness can reach it.

A 10-minute ASan+UBSan run (375k execs) found no crash.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Xavier Roche <roche@httrack.com>
@xroche
xroche enabled auto-merge (squash) November 14, 2026 17:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant