Skip to content

Commit

Permalink
minidriver.c - test if ContainerInfo dwVersion must be CONTAINER_INFO…
Browse files Browse the repository at this point in the history
…_CURRENT_VERSION

 On branch Minidriver-2
 Changes to be committed:
	modified:   minidriver.c
  • Loading branch information
dengert committed Nov 25, 2024
1 parent b0d178d commit 97c406a
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/minidriver/minidriver.c
Original file line number Diff line number Diff line change
Expand Up @@ -3598,6 +3598,13 @@ DWORD WINAPI CardGetContainerInfo(__in PCARD_DATA pCardData, __in BYTE bContaine
ret = SCARD_E_NO_KEY_CONTAINER;
goto err;
}
if (md_get_config_bool(pCardData, "md_container_version_must_match", FALSE) == TRUE) {
if (pContainerInfo->dwVersion != CONTAINER_INFO_CURRENT_VERSION) {
logprintf(pCardData, 7, "pContainerInfo->dwVersion not CONTAINER_INFO_CURRENT_VERSION\n");
ret = SCARD_E_NO_KEY_CONTAINER;
goto err;
}
}
if (pContainerInfo->dwVersion > CONTAINER_INFO_CURRENT_VERSION) {
ret = ERROR_REVISION_MISMATCH;
goto err;
Expand Down

0 comments on commit 97c406a

Please sign in to comment.