Various bug fixes: replacement for PR #42 - #48
Open
davidjwbbc wants to merge 8 commits into
Open
Conversation
POST and PUT on /mbs-user-services construct an MBSUserService (or call UserService::update(), which does the same) from the request body with no exception boundary around ModelException -- the C++ exception thrown by the generated model when a required field (extServiceIds, servType, servClass, servAnnModes, servNameDescs) is missing. Uncaught, it terminates the whole process, taking down every other active session with it, instead of returning the 400 the generated OpenAPI schema actually specifies for this case. Catches ModelException at both call sites and responds via the same ProblemDetails-shaped NfServer::sendError() path already used elsewhere in this file for validation failures.
random_string()'s charset included '@', '\', '!' and ';', none of which are members of RFC 2046 SS5.1.1's bcharsnospace grammar (the only characters a boundary value may contain, quoted-string wrapper or not). '\' was the more acute problem in practice -- written unescaped into the quoted-string Content-Type header parameter, it let a strictly RFC 2045-compliant quoted-string parser derive a different (unescaped) boundary value than the literal delimiter text actually used in the body, desyncing the two and making the whole entity unparseable -- but all four characters were illegal regardless of escaping.
davidjwbbc
requested review from
devbbc,
dsilhavy,
jordijoangimenez and
rjb1000
August 6, 2026 16:43
rjb1000
previously approved these changes
Aug 6, 2026
|
(@davidjwbbc: Let's let @jordijoangimenez review too before merging.) |
dsilhavy
reviewed
Aug 6, 2026
Co-authored-by: Jordi J. Gimenez <[email protected]>
Co-authored-by: Jordi J. Gimenez <[email protected]>
Co-authored-by: Jordi J. Gimenez <[email protected]>
Co-authored-by: Jordi J. Gimenez <[email protected]>
Contributor
|
@davidjwbbc To run one last test and then merge |
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.
Closes #43
Closes #46
Closes #47
This PR fixes 3 issues raised by @jordijoangimenez. These issues come from the set raised originally in PR #42 but removes the commits for the API interfaces that we do not wish to implement until 5G-MAG/Standards#182 and 5G-MAG/Standards#191 are resolved.
Improvements have also been made to the original fixes in PR #42 for #46 and #47.