Yes. Most all federal employees retain pension rights unless convicted of one of a limited number of felonies listed in the US Code:
https://www.law.cornell.edu/uscode/text/5/8312
*