Daniel J. Bernsteins qmail MTA is known for its security but also for not being longer adequate to prevent backscatter. Erwin Hoffmann provided the RECIPIENT extension to qmail that needs to be feeded with addresses.
The provided scripts on Erwins qmail page were not satisfying for my setup, so I wrote my own address gathering script.
The script tries to follow the qmail delivery path as close as possible.
It always stops when finding -default extensions to .qmail files with one
exception:
.qmail-default files are tested for the presence of vpopmail delivery
instructions.
If vpopmail is found then additionally the user database for the virtual domain is analyzed.
The script is available for Download here. It only depends on a standard Python installation.