New transaction validation code