Skip to content

Conversation

@istepic
Copy link

@istepic istepic commented May 8, 2023

When SoftHSMv2 is used for testing PKCS#11 client code before hardware is available, maximum session count on a token needs to be set in order to detects bugs in client code where sessions are leaked and remain open. This can cause problems since most hardware implementations have a limit on opened sessions count.

This change sets a limit to general session count.

When SoftHSMv2 is used for testing PKCS#11 client code
before hardware is available, maximum session count on
a token needs to be set in order to detects bugs in client
code where sessions are leaked and remain open. This
can cause problems since most hardware implementations
have a limit on opened sessions count.

This change sets a limit to general session count.
@nomis
Copy link
Contributor

nomis commented Dec 4, 2023

Shouldn't this default to the original value or be runtime configurable?

Those of us using this entirely in software don't want arbitrary low session limits.

Copy link
Contributor

@bjosv bjosv left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Additionally, I believe we also need to provide new defines when building with CMake (see config.h.in.cmake and CMakeLists.txt).

@jschlyter jschlyter marked this pull request as draft November 29, 2024 16:27
@jschlyter
Copy link
Contributor

Please rebase on develop and mark as ready when ready.

@bukka
Copy link
Contributor

bukka commented Mar 20, 2025

I agree that this way too low default and it should be runtime configurable (ideally through the config).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants