Diff

Differences From Artifact [86bd0fe2e2]:

To Artifact [47338c5b52]:


   331    331   	chk_rv = C_OpenSession(slots[0], CKF_SERIAL_SESSION, NULL, NULL, &hSession);
   332    332   	if (chk_rv == CKR_OK) {
   333    333   		chk_rv = C_GetTokenInfo(slots[0], &tokenInfo);
   334    334   		if (chk_rv != CKR_OK) {
   335    335   			return(1);
   336    336   		}
   337    337   
   338         -		if ((tokenInfo.flags & CKF_LOGIN_REQUIRED) == CKF_LOGIN_REQUIRED) {
          338  +		if ((tokenInfo.flags & CKF_LOGIN_REQUIRED) == CKF_LOGIN_REQUIRED && (tokenInfo.flags & CKF_PROTECTED_AUTHENTICATION_PATH) == 0) {
   339    339   			fgets_ret = NULL;
   340    340   
   341    341   			while (fgets_ret == NULL) {
   342    342   				printf("** ENTER PIN: ");
   343    343   				fflush(stdout);
   344    344   
   345    345   				fgets_ret = fgets((char *) user_pin, sizeof(user_pin), stdin);