Ported parts of TLSLite to allow quick cipher scanning with little overhead.

Should also port other bits to use this basis.