Fix SSHException when re-keying over a fast connection
Fix SSHException when re-keying over a fast connection

When Paramiko initiates a re-key request over a high-bandwidth, medium-latency
connection, it erroneously terminates the connection with the error,
"SSHException: Remote transport is ignoring rekey requests".  This is due to
the hard-coded limit of 20 packets that may be received after a re-key request
has been sent.

See, for example, this bug report:

    "Transfer fails at 1GB: rekey window too small, hard-coded"
        https://github.com/paramiko/paramiko/issues/49

This patch changes paramiko's behaviour as follows:

- Decrease the threshold for starting re-keying from 2**30 to 2**29 bytes.
- Decrease the threshold for starting re-keying from 2**30 to 2**29 packets.
- Increase the limit of received packets between re-key request & completion
  from 20 packets to 2**29 packets.
- Add a limit of 2**29 received bytes between re-key request & completion.

In other words, we re-key more often in order to allow more data to be
in-transit during re-keying.

NOTE: It looks like Paramiko disables the keep-alive mechanism during
re-keying.  This patch does not change that behaviour.

redixin/paramiko,rcorrieri/paramiko,anadigi/paramiko,digitalquacks/paramiko,toby82/paramiko,CptLemming/paramiko,varunarya10/paramiko,fvicente/paramiko,remram44/paramiko,jaraco/paramiko,jorik041/paramiko,davidbistolas/paramiko,alex/paramiko,thusoy/paramiko,torkil/paramiko,zpzgone/paramiko,mhdaimi/paramiko,dlitz/paramiko,thisch/paramiko,esc/paramiko,Bluehorn/paramiko,ameily/paramiko,SebastianDeiss/paramiko,nischu7/paramiko,reaperhulk/paramiko,selboo/paramiko,mirrorcoder/paramiko,Automatic/paramiko,paramiko/paramiko,mitsuhiko/paramiko,zarr12steven/paramiko,dorianpula/paramiko