Skip to content

Skip unsupported EC curves in KeysInUse tests - #175

Merged
Maxwell Moyer-McKee (mamckee) merged 2 commits into
scossl-1.11from
mamckee-robust-keysinuse-test
Aug 26, 2026
Merged

Skip unsupported EC curves in KeysInUse tests#175
Maxwell Moyer-McKee (mamckee) merged 2 commits into
scossl-1.11from
mamckee-robust-keysinuse-test

Conversation

@mamckee

Copy link
Copy Markdown
Collaborator

This PR skips EC curves for KeysInUse tests programmatically rather than relying on hardcoded NIDs

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR updates the KeysInUse test harness to runtime-skip EC curves that can’t be generated on the current platform (instead of compile-time skipping via hardcoded #ifdef checks), and bumps the project version accordingly.

Changes:

  • Removes the compile-time #ifdef NID_X9_62_prime192v1 guard from the EC test key list.
  • Updates key generation to continue past EC curve failures and skips test execution for entries whose key generation was skipped.
  • Bumps SymCrypt-OpenSSL project version from 1.11.0 to 1.11.1.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
test/KeysInUseTest/KeysInUseTest.cpp Switches KeysInUse EC test coverage from hardcoded-NID assumptions to runtime skipping for unsupported curves.
CMakeLists.txt Increments project version to 1.11.1.
Suppressed comments (1)

test/KeysInUseTest/KeysInUseTest.cpp:1644

  • This skip path has the same OBJ_nid2sn() NULL-to-%s risk as above. It should also clear/free testKeys[i] fields before continuing, so a failed EVP_PKEY_keygen() can’t leave a non-NULL/partial pkey that would later be treated as a generated key.
            if (testKeys[i].keyType == EVP_PKEY_EC)
            {
                printf("Skipping unsupported curve %s\n", OBJ_nid2sn(testKeys[i].keygenParams));
                ERR_clear_error();
                EVP_PKEY_CTX_free(ctx);
                ctx = NULL;
                continue;
            }

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread test/KeysInUseTest/KeysInUseTest.cpp Outdated
Comment thread test/KeysInUseTest/KeysInUseTest.cpp

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.

@mamckee
Maxwell Moyer-McKee (mamckee) merged commit f29777f into scossl-1.11 Aug 26, 2026
4 checks passed
@mamckee
Maxwell Moyer-McKee (mamckee) deleted the mamckee-robust-keysinuse-test branch August 26, 2026 23:17
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.

3 participants