unixftpsignalsvsftpdfuzz-testing

Any recommendations on observing the signals (e.g. SIGSVE, SIGFPE, etc) of an FTP server?


I'm trying to write up a program that can monitor the signals (e.g. SIGSVE, SIGFPE, SIGABRT) from a target FTP server (e.g. vsftpd). Any approaches or resources that I should look into?

I'm trying to test a custom fuzz testing framework by making the framework fuzz an FTP server, to begin with. The framework is intended to run on a Linux environment.

The program is just meant to help with evaluating the framework by logging the signals of the server, to a file (for now).

I've done some searches on monitoring signals in Python: https://stackabuse.com/handling-unix-signals-in-python/

It seems simple (Based on that article) to monitor a signal but is there a way I can target the vsftpd FTP server's signal?


Solution

  • Presuming you're on Linux, maybe just script around strace? You'll get a line of output for every signal the process receives. For example, run strace on the PID of your FTP server, then send it a signal (here, a SIGINT):

    $ cat > /dev/null 
    $ strace -e signal -fp $(pidof cat)
    Process 23879 attached
    --- SIGINT {si_signo=SIGINT, si_code=SI_USER, si_pid=23887, si_uid=501} ---
    +++ killed by SIGINT +++