1. add hsm methods
2. add assert