Adding garbage collection for encrypted state.