Refactor key creation to use a registry of key factories.

Change-Id: I6ebab7b44e4a5dbea282397ab8aca437e71bdca0
16 files changed