Yes, you can use EJ257 headgaskets if you have an EJ251. I just did a headgasket/seal/timing component overhaul on my 2000 Forester and that is what I did after researching a lot. They are multi-layer steel gaskets and like someone mentioned, are supposed to hold up really well. They are also the same shape and have the same passages as the EJ251 gaskets. They are slightly thinner I believe, which raises the compression a hair, but nothing noticeable (that is what I have read).
I didn't want to take a chance with non-OEM gaskets and figured the STI gaskets were the best ones. Don't get the OEM gaskets Subaru lists for that car, as even the "Updated" gaskets are single layer steel.