some updates to keys and gates