RSA.generateKey: x4-7 speedup

* better trial division
* reduced number of Miller-Rabin rounds
* some minor changes
RSA.generageKey: tune trial division
Fix RSA.decrypt: pad with zeros up to key length
Merge branch 'master' into progressive