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

Check for last resort in core_group/new_from_welcome #1503

Merged
merged 10 commits into from
Feb 21, 2024
Merged

Check for last resort in core_group/new_from_welcome #1503

merged 10 commits into from
Feb 21, 2024

Conversation

josephlukefahr
Copy link
Contributor

@josephlukefahr josephlukefahr commented Feb 18, 2024

Closes #1502

This PR just copies the logic in group::MlsGroup::new_from_welcome(...), which checks for last resort extension in keypackage, to group::CoreGroup::new_from_welcome(...).

@josephlukefahr josephlukefahr requested a review from a team as a code owner February 18, 2024 17:06
Copy link
Member

@kkohbrok kkohbrok left a comment

Choose a reason for hiding this comment

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

Thanks for the PR! It looks like it solves the issue. To confirm that it does and to ensure we don't run into this sort of thing in the future, would you be so kind as to add a simple test? You can add the test to mls_group/test_mls_group.rs, where you can find inspiration on how to set up the test as well. I think it's better to have the test at the MlsGroup (rather than the CoreGroup) level, since we're likely to move all provider access to MlsGroup level eventually anyway (see #1207).

(Also you'll have to run cargo fmt on the code before we can merge.)

@josephlukefahr
Copy link
Contributor Author

josephlukefahr commented Feb 19, 2024

See 050d330 for the test. Open to feedback/guidance on robustness of the test procedure for this case.

@josephlukefahr
Copy link
Contributor Author

See 4253a26 for the cargo fmt changes.

kkohbrok
kkohbrok previously approved these changes Feb 20, 2024
Copy link
Member

@kkohbrok kkohbrok left a comment

Choose a reason for hiding this comment

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

Thanks for adding the test and making the requested changes! This looks good to me, but clippy has a few complaints. Once you sort those out we can get this merged.

Copy link
Member

@kkohbrok kkohbrok left a comment

Choose a reason for hiding this comment

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

Sorry, one last thing: Could you add an entry to the changelog indicating that this bug was fixed? You can find it in CHANGELOG.md.

Copy link
Member

@kkohbrok kkohbrok left a comment

Choose a reason for hiding this comment

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

Excellent, thanks!

@kkohbrok kkohbrok merged commit b572335 into openmls:main Feb 21, 2024
49 checks passed
@josephlukefahr josephlukefahr deleted the jwl/core_group_last_resort branch February 22, 2024 23:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
3 participants