kmsutils: add utilities for type destroying

Change-Id: I641d7b94067cf560686413e21df1f299d38e7bcb