1. Pass structure to c library to get certificate info. 2. Add comments.