Allow to limit the number of inputs/outputs

Without that, deserializing user-provided transactions could allow for a DoS attack by specifying a huge input/output count.