WPB-10207 Match cipher suite tag in query parameters against key packages on replacing key packages#4158
Merged
battermann merged 3 commits intodevelopfrom Jul 17, 2024
Merged
Conversation
…ages on replacing key packages (#4157) * check query parameter against key packages when replacing key packages * tests for error cases * changelog * Update services/brig/src/Brig/API/MLS/CipherSuite.hs Co-authored-by: Stefan Berthold <stefan.berthold@wire.com> --------- Co-authored-by: Stefan Berthold <stefan.berthold@wire.com>
pcapriotti
approved these changes
Jul 17, 2024
Contributor
pcapriotti
left a comment
There was a problem hiding this comment.
LGTM. Minor comment below.
integration/test/API/Brig.hs
Outdated
| replaceKeyPackages cid suites kps = do | ||
| replaceKeyPackages cid suites kps = replaceKeyPackages' cid (Just suites) kps | ||
|
|
||
| replaceKeyPackages' :: ClientIdentity -> Maybe [Ciphersuite] -> [ByteString] -> App Response |
Contributor
There was a problem hiding this comment.
The convention we've been sticking to in cases like this one is to create a data type say ReplaceKeyPackages with a Default instance and redefine replaceKeyPackages as ClientIdentity -> ReplaceKeyPackages -> App Response, so we can have something that resembles named arguments. Having primed method names is confusing and doesn't really scale.
battermann
approved these changes
Jul 17, 2024
This was referenced Oct 23, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
https://wearezeta.atlassian.net/browse/WPB-10207
Checklist
changelog.d