Attention is currently required from: msuraev. neels has posted comments on this change. ( https://gerrit.osmocom.org/c/libosmo-sccp/+/29084 )
Change subject: SIGTRAN: enforce optional data length limits ......................................................................
Patch Set 4: Code-Review-1
(5 comments)
Commit Message:
https://gerrit.osmocom.org/c/libosmo-sccp/+/29084/comment/06c69059_3b261ef1 PS4, Line 7: SIGTRAN: enforce optional data length limits "enforce length limits on SCCP Optional Data" ?
File src/sccp_scoc.c:
https://gerrit.osmocom.org/c/libosmo-sccp/+/29084/comment/c270a568_6601112b PS4, Line 580: if (prim && msgb_l2(prim->oph.msg) && msgb_l2len(prim->oph.msg)) { exit early
if (!(...)) return true; if (msgb...) { ... } xua_msg_add_data(...); return true;
https://gerrit.osmocom.org/c/libosmo-sccp/+/29084/comment/3dbb9804_bdfbc6b7 PS4, Line 585: xua_msg_free(xua); freeing here is very confusing memory management. The caller should do this free when receiving an error rc.
https://gerrit.osmocom.org/c/libosmo-sccp/+/29084/comment/d876a623_fb00d419 PS4, Line 615: if (!xua_add_data(prim, xua, "4.2")) this looks like a mem leak of above xua_msg_alloc(). the free should not be in xua_add_data()
https://gerrit.osmocom.org/c/libosmo-sccp/+/29084/comment/0191abbb_68985a90 PS4, Line 617: /* optional: hop coun */ "count" ?