Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Fix openssl storeutl to allow serial + issuer #19856

Closed
wants to merge 1 commit into from

Conversation

simo5
Copy link
Contributor

@simo5 simo5 commented Dec 7, 2022

storeutl wants to enforce the use of issuer and serial together, however the current code prevents to use them together and returns an error if only one of them is specified.

Checklist
  • documentation is added or updated
  • tests are added or updated

storeutl wants to enforce the use of issuer and serial together,
however the current code prevents to use them together and returns an
error if only one of them is specified.

Signed-off-by: Simo Sorce <simo@redhat.com>
@simo5
Copy link
Contributor Author

simo5 commented Dec 8, 2022

The issues reported by CI do not look to be related to may change, is the master tree broken ?

@t8m
Copy link
Member

t8m commented Dec 8, 2022

The issues reported by CI do not look to be related to may change, is the master tree broken ?

Rather the compiler(s) has been updated in the CI images and this triggers some nonsense warnings and test breakages.

@t8m t8m added branch: master Merge to master branch approval: review pending This pull request needs review by a committer approval: otc review pending This pull request needs review by an OTC member triaged: bug The issue/pr is/fixes a bug branch: 3.0 Merge to openssl-3.0 branch branch: 3.1 Merge to openssl-3.1 tests: exempted The PR is exempt from requirements for testing labels Dec 8, 2022
Copy link
Member

@t8m t8m left a comment

Choose a reason for hiding this comment

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

It would be nice to get some testcase(s) added to 90-test_store.t.

@t8m t8m removed the approval: otc review pending This pull request needs review by an OTC member label Dec 8, 2022
@simo5
Copy link
Contributor Author

simo5 commented Dec 8, 2022

@t8m I wanted to add a test but:

$ ~/tmp/openssl/bin/openssl storeutl -issuer '/C=AU/ST=QLD/CN=SSLeay\/rsa test cert', -serial 0x4aa432cf71ab4a9f74d7e5229a2a74368e53f4e1 -certs file:[blah..]/openssl/test-runs/test_store/store_2016635/rehash/testx509.pem
storeutl: the store scheme doesn't support the given search criteria.

My provider now supports this (tested manually), but the standard file provider seems to be lacking support. In fact I see there is no way to set neither the issuer not the serial parameters in the implementation of store manager, no wonder the command was broken ...

@simo5
Copy link
Contributor Author

simo5 commented Dec 12, 2022

@t8m is there anything else I should do for this PR ?

@t8m
Copy link
Member

t8m commented Dec 12, 2022

@t8m is there anything else I should do for this PR ?

Nope. It is waiting for a second review.

Copy link
Member

@beldmit beldmit left a comment

Choose a reason for hiding this comment

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

LGTM

@beldmit beldmit added approval: done This pull request has the required number of approvals and removed approval: review pending This pull request needs review by a committer labels Dec 12, 2022
@openssl-machine
Copy link
Collaborator

24 hours has passed since 'approval: done' was set, but this PR has failing CI tests. Once the tests pass it will get moved to 'approval: ready to merge' automatically, alternatively please review and set the label manually.

@t8m
Copy link
Member

t8m commented Dec 14, 2022

Merged to master, 3.1, and 3.0 branches. Thank you for your contribution.

@t8m t8m closed this Dec 14, 2022
openssl-machine pushed a commit that referenced this pull request Dec 14, 2022
storeutl wants to enforce the use of issuer and serial together,
however the current code prevents to use them together and returns an
error if only one of them is specified.

Signed-off-by: Simo Sorce <simo@redhat.com>

Reviewed-by: Dmitry Belyavskiy <beldmit@gmail.com>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from #19856)
openssl-machine pushed a commit that referenced this pull request Dec 14, 2022
storeutl wants to enforce the use of issuer and serial together,
however the current code prevents to use them together and returns an
error if only one of them is specified.

Signed-off-by: Simo Sorce <simo@redhat.com>

Reviewed-by: Dmitry Belyavskiy <beldmit@gmail.com>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from #19856)

(cherry picked from commit abdf351)
openssl-machine pushed a commit that referenced this pull request Dec 14, 2022
storeutl wants to enforce the use of issuer and serial together,
however the current code prevents to use them together and returns an
error if only one of them is specified.

Signed-off-by: Simo Sorce <simo@redhat.com>

Reviewed-by: Dmitry Belyavskiy <beldmit@gmail.com>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from #19856)

(cherry picked from commit abdf351)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approval: done This pull request has the required number of approvals branch: master Merge to master branch branch: 3.0 Merge to openssl-3.0 branch branch: 3.1 Merge to openssl-3.1 tests: exempted The PR is exempt from requirements for testing triaged: bug The issue/pr is/fixes a bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants