The Firebird source code resides in the Git repository hosted on GitHub. The repository can be checked out through the Git client with the following instruction set:
git clone

This command will check out the complete repository which includes all the Firebird versions, both released and being developed. If you need some particular version, switch to the branch or tag you need. Please refer to the Git documentation for specific instructions.