Cache rejected tx to avoid rerequesting

AlreadyHave only prevents rerequesting transactions accepted to the mempool or identified as orphans; if a transaction failed validation, it keeps requesting it and validating it every time it receives an inv. This change adds a small mruset to remember some failed transactions.

This requires a new distinction between permanent failures (that are independent of chain state) and temporary failures; the few potentially temporary rejections are not cached.

--

I wrote this because my node keeps banning old peers affected by #3190, when they're only resending the failed transactions because we keep getdataing them. A small cache of invalid transactions has low overhead in code complexity and runtime complexity, and prevents a lot of unnecessary banning for #3190 and any possible future bugs with similar effects.
200 is arbitrary. I figured it would be large enough to handle the rate at which invalid txes would occur under "normal" circumstances like the wallet tx empty-vin bug. I don't think reasonable behavior is very dependent on the set size/expiration policy so long as it's in the right ballpark; it seems like returns diminish quickly beyond the cache being big enough to handle the bulk of unnecessary transaction-rerequesting. An expiry time would be slightly more complex to deal with than a maximum number of entries, and since I don't see the choice of policies making any important functional difference I just went with the simplest.