security: get KeyDigest from PublicKey.

Change-Id: Ibb7cf0aba262dbb80d5ea1d2da02318963c0f417
Refs: #1964