Standardize cipher hex values and fix collision.

Thanks for the work putting this together; I found it very valuable. My two commits fix a few issues, see the descriptions for details.