If your current engine runs, forget it.
If your current engine has failed, figure out why first. That may prevent the same thing happening to the expen$ive replacement.
After that, consider a hybrid build. If you search "hybrid motor" or "hybrid build" you will see info. This will get you a brand new shortblock, and along with it compression, management, oiling, and fueling problems.
The issue I'd want to avoid with a newer STi engine (intact) is the wiring, valve control, etc. Hybrid or bust IMO.
EDIT: By the way, "hybrid" and "bust" are not mutually exclusive in my view. Nonetheless, I disagree with the assessment about the pistons below; however, the link is at the very least a good start.
Hybrid Engine's - Subaru WRX Forum: WRX Forums