CKF_LOGIN_REQUIRED
if ((si->token.flags & CKF_LOGIN_REQUIRED) && !si->logged_in) {
login_required = si->token.flags & CKF_LOGIN_REQUIRED;