add comments and stub prototype for credential verification