Make the data needed for hashing available from pyx509.

And cleanup things.
Code cleanup.
Performance optimizations to pyasn1 BitString.

Both decoder and encoder could be made 2-3 times faster without
changing anything but the local loops.