We are unaware of any general restrictions on buying real estate from the government.
The only one we can think of might have to do with past due child support obligations or unpaid income taxes.
We can envision a situation in which someone with such obligations attempts to buy from the government, proceeds to closing, and then his or her earnest money is confiscated for the unpaid sums. You might want to think twice about buying property from the government if you owe child support or taxes.
That being said, national and local governments do give preferences to buyers who intend to live in the properties they purchase. Often, REOs will be offered first to potential homeowners for a specified period of time.
If the house has not sold by the expiration of that time, anyone is eligible to make an offer.