Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Fix memory access error in C_GetSlotList #110

Merged
merged 4 commits into from
Aug 29, 2024
Merged

Conversation

microshine
Copy link
Contributor

This pull request primarily addresses a critical bug fix where the code was not handling cases where the pkcs11 module may return slotCount 0 on the first call to C_GetSlotList, and a non-zero value on subsequent calls. This issue led to a segmentation fault when using pSlotList. The fix involves checking if slotCount is 0 and returning an empty array if no slots are available.

Additionally, this pull request includes:

  • Updates to the Coveralls GitHub action to version 2.
  • Updates to the npm dependencies to their latest versions.

@microshine microshine merged commit 5667c0b into master Aug 29, 2024
9 checks passed
@microshine microshine deleted the fix-slotlist-null branch August 29, 2024 10:36
@coveralls
Copy link

coveralls commented Aug 29, 2024

Coverage Status

coverage: 97.414%. remained the same
when pulling 929b6a3 on fix-slotlist-null
into 9767368 on master.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants