Minor renaming of message functions.
Add KeyIdentifier protocol for key-id.
Refactor key-algorithm multimethod.
Add Encodable protocol.
Misc docs and cleanup.