Projects
osmocom:latest
libosmo-pfcp
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Changes of Revision 4
View file
libosmo-pfcp.spec
Changed
@@ -1,20 +1,20 @@ Name: libosmo-pfcp Requires: osmocom-latest -Version: 0.2.0 +Version: 0.3.0 Release: 0 Summary: PFCP protocol encoding, decoding and endpoint implementation -License: AGPL-3.0-or-later AND GPL-2.0-or-later +License: GPL-2.0-or-later Group: Hardware/Mobile URL: https://osmocom.org/projects/libosmo-pfcp -Source: libosmo-pfcp_0.2.0.tar.xz +Source: libosmo-pfcp_0.3.0.tar.xz Source1: rpmlintrc BuildRequires: autoconf-archive BuildRequires: automake >= 1.9 BuildRequires: libtool >= 2 BuildRequires: lksctp-tools-devel BuildRequires: pkgconfig >= 0.20 -BuildRequires: pkgconfig(libosmocore) >= 1.8.0 -BuildRequires: pkgconfig(libosmogsm) >= 1.8.0 +BuildRequires: pkgconfig(libosmocore) >= 1.9.0 +BuildRequires: pkgconfig(libosmogsm) >= 1.9.0 BuildRequires: pkgconfig(talloc) %description @@ -27,7 +27,7 @@ %package -n libosmo-gtlv1 Requires: osmocom-latest Summary: Generic TLV and TLIV protocol support -License: GPL-2.0-or-later AND AGPL-3.0-or-later +License: GPL-2.0-or-later Group: System/Libraries %description -n libosmo-gtlv1 @@ -51,7 +51,7 @@ %package -n libosmo-pfcp0 Requires: osmocom-latest Summary: PFCP protocol support -License: GPL-2.0-or-later AND AGPL-3.0-or-later +License: GPL-2.0-or-later Group: System/Libraries %description -n libosmo-pfcp0
View file
libosmo-pfcp_0.2.0.dsc -> libosmo-pfcp_0.3.0.dsc
Changed
@@ -2,13 +2,13 @@ Source: libosmo-pfcp Binary: libosmo-pfcp, libosmo-gtlv1, libosmo-gtlv-dev, libosmo-gtlv-dbg, libosmo-pfcp0, libosmo-pfcp-dev, libosmo-pfcp-dbg Architecture: any -Version: 0.2.0 -Maintainer: Osmocom team <osmocom-net-gprs@lists.osmocom.org> +Version: 0.3.0 +Maintainer: Osmocom team <openbsc@lists.osmocom.org> Homepage: https://projects.osmocom.org/projects/libosmo-pfcp Standards-Version: 3.9.8 Vcs-Browser: https://gitea.osmocom.org/osmocom/libosmo-pfcp Vcs-Git: https://gitea.osmocom.org/osmocom/libosmo-pfcp -Build-Depends: debhelper (>= 10), dh-autoreconf, autotools-dev, autoconf, autoconf-archive, automake, libtool, pkg-config, libosmocore-dev (>= 1.8.0), libtalloc-dev (>= 2.1.0) +Build-Depends: debhelper (>= 10), dh-autoreconf, autotools-dev, autoconf, autoconf-archive, automake, libtool, pkg-config, libosmocore-dev (>= 1.9.0), libtalloc-dev (>= 2.1.0) Package-List: libosmo-gtlv-dbg deb debug extra arch=any libosmo-gtlv-dev deb libdevel optional arch=any @@ -18,8 +18,8 @@ libosmo-pfcp-dev deb libdevel optional arch=any libosmo-pfcp0 deb libs optional arch=any Checksums-Sha1: - a5ed842a761f38973ca3b869a200c5be3af48f18 67568 libosmo-pfcp_0.2.0.tar.xz + 5a706570f2422fe6ddec207c6e9ea81bb2c29c79 69012 libosmo-pfcp_0.3.0.tar.xz Checksums-Sha256: - bb04ba69a08c78ba8a1fa8f65051353b8fde8d00a499e0c46047001e090ca410 67568 libosmo-pfcp_0.2.0.tar.xz + d25101b019b8c202136fdc600b090a34a2db842729573e41205e18fe4a9c4e82 69012 libosmo-pfcp_0.3.0.tar.xz Files: - 7a75dee0c4ca93dce8fc618fd6212f70 67568 libosmo-pfcp_0.2.0.tar.xz + c1c2b40f660c5f034df8f58da2686ab9 69012 libosmo-pfcp_0.3.0.tar.xz
View file
libosmo-pfcp_0.2.0.tar.xz/.tarball-version -> libosmo-pfcp_0.3.0.tar.xz/.tarball-version
Changed
@@ -1 +1 @@ -0.2.0 +0.3.0
View file
libosmo-pfcp_0.2.0.tar.xz/Makefile.am -> libosmo-pfcp_0.3.0.tar.xz/Makefile.am
Changed
@@ -4,7 +4,6 @@ ## remove line below when OE toolchain is updated to version which include those ACLOCAL_AMFLAGS = -I m4 AM_CPPFLAGS = \ - $(all_includes) \ -I$(top_srcdir)/include \ $(NULL)
View file
libosmo-pfcp_0.2.0.tar.xz/configure.ac -> libosmo-pfcp_0.3.0.tar.xz/configure.ac
Changed
@@ -37,8 +37,8 @@ PKG_PROG_PKG_CONFIG(0.20) dnl checks for libraries -PKG_CHECK_MODULES(LIBOSMOCORE, libosmocore >= 1.8.0) -PKG_CHECK_MODULES(LIBOSMOGSM, libosmogsm >= 1.8.0) +PKG_CHECK_MODULES(LIBOSMOCORE, libosmocore >= 1.9.0) +PKG_CHECK_MODULES(LIBOSMOGSM, libosmogsm >= 1.9.0) dnl checks for header files AC_HEADER_STDC
View file
libosmo-pfcp_0.2.0.tar.xz/contrib/libosmo-pfcp.spec.in -> libosmo-pfcp_0.3.0.tar.xz/contrib/libosmo-pfcp.spec.in
Changed
@@ -3,7 +3,7 @@ Version: @VERSION@ Release: 0 Summary: PFCP protocol encoding, decoding and endpoint implementation -License: AGPL-3.0-or-later AND GPL-2.0-or-later +License: GPL-2.0-or-later Group: Hardware/Mobile URL: https://osmocom.org/projects/libosmo-pfcp Source: %{name}-%{version}.tar.xz @@ -12,8 +12,8 @@ BuildRequires: libtool >= 2 BuildRequires: lksctp-tools-devel BuildRequires: pkgconfig >= 0.20 -BuildRequires: pkgconfig(libosmocore) >= 1.8.0 -BuildRequires: pkgconfig(libosmogsm) >= 1.8.0 +BuildRequires: pkgconfig(libosmocore) >= 1.9.0 +BuildRequires: pkgconfig(libosmogsm) >= 1.9.0 BuildRequires: pkgconfig(talloc) %description @@ -26,7 +26,7 @@ %package -n libosmo-gtlv1 Requires: osmocom-latest Summary: Generic TLV and TLIV protocol support -License: GPL-2.0-or-later AND AGPL-3.0-or-later +License: GPL-2.0-or-later Group: System/Libraries %description -n libosmo-gtlv1 @@ -50,7 +50,7 @@ %package -n libosmo-pfcp0 Requires: osmocom-latest Summary: PFCP protocol support -License: GPL-2.0-or-later AND AGPL-3.0-or-later +License: GPL-2.0-or-later Group: System/Libraries %description -n libosmo-pfcp0
View file
libosmo-pfcp_0.2.0.tar.xz/debian/changelog -> libosmo-pfcp_0.3.0.tar.xz/debian/changelog
Changed
@@ -1,3 +1,27 @@ +libosmo-pfcp (0.3.0) unstable; urgency=medium + + Neels Janosch Hofmeyr + * clarify API doc for osmo_pfcp_endpoint_tx() + * add doc/charts/pfcp_msgs*.msc + * libosmo-pfcp.pc.in: add missing libosmogsm + * build: drop COVERAGE + * build: drop $(all_includes) + * build: drop LIBOSMOVTY from libosmo-pfcp + * build: libosmo-gtlv: move LIBS to libosmo_gtlv_la_LIBADD + * build: fix linking gen__pfcp_ies_auto to use build-tree libosmo-gtlv + * build: add gen__pfcp_ies_auto_LDFLAGS = -no-install + * pfcp_msg: refactor LOG_PFCP_MSG + * coverity: fix null deref + + Oliver Smith + * Run struct_endianness.py + * debian: make consistent + + Harald Welte + * Fix license information in dpkg + rpm packages: GPLv2+ and not AGPLv3+ + + -- Pau Espin Pedrol <pespin@sysmocom.de> Tue, 12 Sep 2023 13:55:22 +0200 + libosmo-pfcp (0.2.0) unstable; urgency=medium Neels Hofmeyr
View file
libosmo-pfcp_0.2.0.tar.xz/debian/control -> libosmo-pfcp_0.3.0.tar.xz/debian/control
Changed
@@ -1,8 +1,8 @@ Source: libosmo-pfcp Section: libs Priority: optional -Maintainer: Osmocom team <osmocom-net-gprs@lists.osmocom.org> -Build-Depends: debhelper (>=10), +Maintainer: Osmocom team <openbsc@lists.osmocom.org> +Build-Depends: debhelper (>= 10), dh-autoreconf, autotools-dev, autoconf, @@ -10,7 +10,7 @@ automake, libtool, pkg-config, - libosmocore-dev (>= 1.8.0), + libosmocore-dev (>= 1.9.0), libtalloc-dev (>= 2.1.0) Standards-Version: 3.9.8 Vcs-Git: https://gitea.osmocom.org/osmocom/libosmo-pfcp @@ -44,7 +44,7 @@ Section: libdevel Depends: osmocom-latest, ${misc:Depends}, libosmo-gtlv1 (= ${binary:Version}), - libosmocore-dev (>= 1.8.0), + libosmocore-dev (>= 1.9.0), libtalloc-dev (>= 2.1.0) Description: Development files for libosmo-gtlv libosmo-gtlv implements decoding, encoding and logging of protocols using a
View file
libosmo-pfcp_0.2.0.tar.xz/debian/copyright -> libosmo-pfcp_0.3.0.tar.xz/debian/copyright
Changed
@@ -4,16 +4,16 @@ Files: * Copyright: 2022 sysmocom - s.f.m.c. GmbH <info@sysmocom.de> -License: AGPL-3.0+ +License: GPL-2.0+ This program is free software; you can redistribute it and/or modify - it under the terms of the GNU Affero General Public License as published by - the Free Software Foundation; either version 3 of the License, or + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or (at your option) any later version. . This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU Affero General Public License for more details. + GNU General Public License for more details. . - You should have received a copy of the GNU Affero General Public License + You should have received a copy of the GNU General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.
View file
libosmo-pfcp_0.3.0.tar.xz/doc/charts/pfcp_msgs.msc
Added
@@ -0,0 +1,60 @@ +msc { + hscale="1"; + upflabel="User Plane function",cpflabel="Control Plane function"; + + cpf rbox cpf label="Look up UPF,\npick any one of the available\nIP addrs for the UPF"; + + ...; + upf abox cpf label="not yet associated"; + upf rbox cpf label="reject any session related msgs"; + ...; + + upf <<= cpf label="PFCP Association Setup Request\nCP function Node Id, features"; + upf =>> cpf label="PFCP Association Setup Response\nUP function Node Id, features"; + upf abox cpf label="associated"; + upf rbox cpf label="start Heartbeat checking"; + ...; + upf <<= cpf label="Heartbeat Request"; + upf =>> cpf label="Heartbeat Response"; + ...; + upf =>> cpf label="Heartbeat Request"; + upf <<= cpf label="Heartbeat Response"; + ...; + + upf <<= cpf label="Session Establishment Request\nCP Node-Id\nCP F-SEID\n1+ Packet Detection Rule(s)\n1+ Forward Action Rule(s)"; + upf =>> cpf label="Session Establishment Response"; + + upf <<= cpf label="Session Modification Request"; + upf =>> cpf label="Session Modification Response"; + + upf <<= cpf label="Session Deletion Request"; + upf =>> cpf label="Session Deletion Response"; + + ...; + upf rbox cpf label="F-SEID: accept any other IP addrs than peer's Node Id"; + ...; + + --- label="Graceful release initiated by CP"; + + upf <<= cpf label="Association Update Request\nwith PFCP Association Release Preparation Start = 1"; + upf =>> cpf label="Association Update Response"; + upf =>> cpf label="Session Report Request\nto report non-zero usage reports,\nat least one message per PFCP Session"; + upf <<= cpf label="Association Release Request"; + upf =>> cpf label="Association Release Response"; + + --- label="Graceful release initiated by UP"; + + upf =>> cpf label="Association Update Request\nwith PFCP Association Release Preparation = 1"; + cpf abox cpf label="refrain from establishing sessions"; + upf <<= cpf label="Association Update Response"; + upf <<= cpf label="Session Deletion Request(s)\nto collect usage reports\nper session"; + upf =>> cpf label="Session Deletion Response(s)"; + cpf rbox cpf label="wait Graceful Release Period"; + upf <<= cpf label="Association Release Request"; + upf =>> cpf label="Association Release Response"; + + --- label="Release (immediate)"; + + upf <<= cpf label="Association Release Request"; + upf =>> cpf label="Association Release Response"; +}
View file
libosmo-pfcp_0.3.0.tar.xz/doc/charts/pfcp_msgs_gtp.msc
Added
@@ -0,0 +1,91 @@ +msc { + hscale="1"; + sgsnlabel="SGSN\n123.44.0.9",sgwclabel="SGW-C\n123.44.0.5",sgwulabel="SGW-U\n123.44.0.6",pgwclabel="PGW-C\n123.44.0.7",pgwulabel="PGW-U\n123.44.0.8"; + + sgsn <=> sgwc label="S4-C GTPv2-C"; + sgwc <=> sgwu label="Sxa PFCP"; + sgsn <=> sgwu label="S4-U GTPv1-U"; + sgwc <=> pgwc label="S5-C GTPv2-C"; + pgwc <=> pgwu label="Sxb PFCP"; + sgwu <=> pgwu label="S5-U GTPv1-U"; + + ...; + + sgsn => sgwc label="GTP Create Session Request"; + sgsn note sgwc label="F-TEID S11 = 123.44.0.9,0x004\nF-TEID S5 = 123.44.0.7,0x000\nPDN addr alloc = IPv4 192.168.100.2"; + + |||; + |||; + + sgwc => sgwu label="PFCP Session Establishment Request"; + sgwc note sgwu label="2x Create PDR\nF-TEID = CHOOSE\nFAR = NOCP,BUFF"; + + |||; + |||; + + sgwc <= sgwu label="PFCP Session Establishment Response"; + sgwc note sgwu label="Created PDR F-TEID 123.44.0.6,0x015\nCreated PDR F-TEID 123.44.0.6,0x016"; + + |||; + |||; + + sgwc => pgwc label="GTP Create Session Request"; + sgwc note pgwc label="F-TEID S5 = 123.44.0.5,0x00b\nPDN addr alloc = IPv4 192.168.100.2\nBearer Ctx: F-TEID S5 = 123.44.0.6,0x015"; + + |||; + |||; + + pgwc => pgwu label="PFCP Session Establishment Request"; + pgwc note pgwu label="Create PDR 1:\nPDI: src-iface Core, UE IPv4 192.168.100.2\nFAR-1: FORW, dst-iface Access,\nhdr creation: GTP-U 123.44.0.6,0x015\n\nCreate PDR 2:\nPDI: src-iface Access, F-TEID = CHOOSE id:05\nhdr removal: GTP-U\nFAR-2: FORW, dst-iface Core\n\nCreate PDR 3:\nPDI: src-iface CP-function, F-TEID = CHOOSE\nhdr removal: GTP-U\nFAR-1\n\nCreate PDR 4:\nPDI: src-iface Access, F-TEID = CHOOSE id:05, SDF Filter\nhdr removal: GTP-U\nFAR-3: FORW, dst-iface CP-Function,\nhdr creation: GTP-U 123.44.0.7,0x00b"; + + |||; + + pgwc <= pgwu label="PFCP Session Establishment Response"; + pgwc note pgwu label="Created PDR-1\nCreated PDR-2: F-TEID = 123.44.0.8,0x01e\nCreated PDR-3: F-TEID = 123.44.0.8,0x01f\nCreated PDR-4: F-TEID = 123.44.0.8,0x01e"; + + |||; + |||; + + sgwc <= pgwc label="GTP Create Session Response"; + sgwc note pgwc label="TEID: 0x00b\nF-TEID: 123.44.0.7,0x00b\nPDN Addr: 192.168.100.2\nBearer Ctx: F-TEID S5 123.44.0.8,0x01e"; + + |||; + |||; + + sgwc => sgwu label="PFCP Session Modification Request"; + sgwc note sgwu label="Update FAR-2: FORW, dst-iface Core,\nhdr creation GTP-U 123.44.0.8,0x01e"; + + |||; + + sgwc <= sgwu label="PFCP Session Modification Response"; + + |||; + |||; + + sgsn <= sgwc label="GTP Create Session Response"; + sgsn note sgwc label="TEID: 0x004\nF-TEID S11/S4: 123.44.0.5,0x007\nF-TEID S5/S8: 123.44.0.7,0x00b\nPDN Addr: 192.168.100.2\nBearer Ctx:\nF-TEID S1-U: 123.44.0.6,0x016\nF-TEID S5/S8: 123.44.0.8,0x01e"; + + |||; + |||; + + sgsn => sgwc label="GTP Modify Bearer Request"; + sgsn note sgwc label="TEID: 0x007\nBearer Ctx:\nF-TEID S1-U: 192.168.104.167,0x32adb2ad"; + + |||; + |||; + + sgwc => sgwu label="PFCP Session Modification Request"; + sgwc note sgwu label="Update FAR-1: FORW, dst-iface Access,\nhdr creation: GTP-U 192.168.104.167,0x32adb2ad"; + + |||; + |||; + + + sgwc <= sgwu label="PFCP Session Modification Response"; + + |||; + + sgsn <= sgwc label="GTP Modify Bearer Response"; + sgsn note sgwc label="TEID: 0x004\nBearer Ctx:\nF-TEID S1-U: 192.168.104.167,0x32adb2ad"; + +}
View file
libosmo-pfcp_0.2.0.tar.xz/include/osmocom/pfcp/pfcp_msg.h -> libosmo-pfcp_0.3.0.tar.xz/include/osmocom/pfcp/pfcp_msg.h
Changed
@@ -42,30 +42,15 @@ #define OSMO_PFCP_MSGB_ALLOC_SIZE 2048 -#define OSMO_LOG_PFCP_MSG_SRC(M, LEVEL, file, line, FMT, ARGS...) do { \ - struct osmo_fsm_inst *_fi = (M) ? ((M)->ctx.session_fi ?: (M)->ctx.peer_fi) : NULL; \ - enum osmo_pfcp_cause *cause = osmo_pfcp_msg_cause(M); \ - if ((M)->h.seid_present) { \ - LOGPFSMSLSRC(_fi, DLPFCP, LEVEL, file, line, \ - "%s%s PFCP seq-%u SEID-0x%"PRIx64" %s%s%s: " FMT, \ - _fi ? "" : osmo_sockaddr_to_str_c(OTC_SELECT, &(M)->remote_addr), \ - (M)->rx ? "-rx->" : "<-tx-", (M)->h.sequence_nr, \ - (M)->h.seid, \ - osmo_pfcp_message_type_str((M)->h.message_type), cause ? ": " : "", \ - cause ? osmo_pfcp_cause_str(*cause) : "", ##ARGS); \ - } else { \ - LOGPFSMSLSRC(_fi, DLPFCP, LEVEL, file, line, \ - "%s%s PFCP seq-%u %s%s%s: " FMT, \ - _fi ? "" : osmo_sockaddr_to_str_c(OTC_SELECT, &(M)->remote_addr), \ - (M)->rx ? "-rx->" : "<-tx-", (M)->h.sequence_nr, \ - osmo_pfcp_message_type_str((M)->h.message_type), cause ? ": " : "", \ - cause ? osmo_pfcp_cause_str(*cause) : "", ##ARGS); \ - } \ - } while (0) +#define OSMO_LOG_PFCP_MSG_SRC(M, LEVEL, file, line, FMT, ARGS...) \ + LOGPSRC(DLPFCP, LEVEL, file, line, "%s: " FMT, osmo_pfcp_msg_log_info_c(OTC_SELECT, M), ##ARGS) #define OSMO_LOG_PFCP_MSG(M, LEVEL, FMT, ARGS...) \ OSMO_LOG_PFCP_MSG_SRC(M, LEVEL, __FILE__, __LINE__, FMT, ##ARGS) +int osmo_pfcp_msg_log_info_buf(char *buf, size_t buflen, const struct osmo_pfcp_msg *m); +char *osmo_pfcp_msg_log_info_c(void *ctx, const struct osmo_pfcp_msg *m); + struct osmo_pfcp_header_parsed { uint8_t version; enum osmo_pfcp_message_type message_type;
View file
libosmo-pfcp_0.2.0.tar.xz/libosmo-pfcp.pc.in -> libosmo-pfcp_0.3.0.tar.xz/libosmo-pfcp.pc.in
Changed
@@ -7,5 +7,6 @@ Description: C Utility Library that implements the PFCP protocol and endpoint Version: @VERSION@ Requires: libosmo-gtlv, libosmocore, talloc +Requires.private: libosmogsm Libs: -L${libdir} -losmo-pfcp Cflags: -I${includedir}/
View file
libosmo-pfcp_0.2.0.tar.xz/src/libosmo-gtlv/Makefile.am -> libosmo-pfcp_0.3.0.tar.xz/src/libosmo-gtlv/Makefile.am
Changed
@@ -1,5 +1,4 @@ AM_CPPFLAGS = \ - $(all_includes) \ -I$(top_srcdir)/include \ -I$(top_builddir) \ -I$(builddir) \ @@ -8,12 +7,6 @@ AM_CFLAGS = \ -Wall \ $(LIBOSMOCORE_CFLAGS) \ - $(COVERAGE_CFLAGS) \ - $(NULL) - -AM_LDFLAGS = \ - $(LIBOSMOCORE_LIBS) \ - $(COVERAGE_LDFLAGS) \ $(NULL) lib_LTLIBRARIES = \ @@ -26,6 +19,10 @@ gtlv_gen.c \ $(NULL) +libosmo_gtlv_la_LIBADD = \ + $(LIBOSMOCORE_LIBS) \ + $(NULL) + # This is _NOT_ the library release version, it's an API version. # Please read Chapter 6 "Library interface versions" of the libtool # documentation before making any modification
View file
libosmo-pfcp_0.2.0.tar.xz/src/libosmo-pfcp/Makefile.am -> libosmo-pfcp_0.3.0.tar.xz/src/libosmo-pfcp/Makefile.am
Changed
@@ -1,5 +1,4 @@ AM_CPPFLAGS = \ - $(all_includes) \ -I$(top_srcdir)/include \ -I$(top_builddir)/include \ -I$(top_builddir) \ @@ -10,15 +9,6 @@ -Wall \ $(LIBOSMOCORE_CFLAGS) \ $(LIBOSMOGSM_CFLAGS) \ - $(LIBOSMOVTY_CFLAGS) \ - $(COVERAGE_CFLAGS) \ - $(NULL) - -AM_LDFLAGS = \ - $(LIBOSMOCORE_LIBS) \ - $(LIBOSMOGSM_LIBS) \ - $(LIBOSMOVTY_LIBS) \ - $(COVERAGE_LDFLAGS) \ $(NULL) lib_LTLIBRARIES = \ @@ -35,10 +25,16 @@ pfcp_ies_auto.c \ $(NULL) +libosmo_pfcp_la_LIBADD = \ + $(top_builddir)/src/libosmo-gtlv/libosmo-gtlv.la \ + $(LIBOSMOCORE_LIBS) \ + $(LIBOSMOGSM_LIBS) \ + $(NULL) + # This is _NOT_ the library release version, it's an API version. # Please read Chapter 6 "Library interface versions" of the libtool # documentation before making any modification -LIBVERSION=1:0:1 +LIBVERSION=2:0:2 libosmo_pfcp_la_LDFLAGS = -version-info $(LIBVERSION) -no-undefined -export-symbols-regex '^osmo_' @@ -68,5 +64,8 @@ gen__pfcp_ies_auto_LDADD = \ $(top_builddir)/src/libosmo-gtlv/libosmo-gtlv.la \ $(LIBOSMOCORE_LIBS) \ - $(COVERAGE_LDFLAGS) \ + $(NULL) + +gen__pfcp_ies_auto_LDFLAGS = \ + -no-install \ $(NULL)
View file
libosmo-pfcp_0.2.0.tar.xz/src/libosmo-pfcp/pfcp_endpoint.c -> libosmo-pfcp_0.3.0.tar.xz/src/libosmo-pfcp/pfcp_endpoint.c
Changed
@@ -326,7 +326,12 @@ * Store the message in the local message queue for possible retransmissions. * On success, return zero, and pass ownership of m to ep. ep deallocates m when all retransmissions are done / a reply * has been received. - * On error, return nonzero, and immediately deallocate m. */ + * On error, return nonzero, and immediately deallocate m. + * + * WARNING: Do not access the osmo_pfcp_msg m after calling this function! In most cases, m will still remain allocated, + * and accessing it will work, but especially when an error occurs, m will be deallocated immediately. Hence, you will + * see no problem during normal successful operation, but your program will crash with use-after-free on any error! + */ int osmo_pfcp_endpoint_tx(struct osmo_pfcp_endpoint *ep, struct osmo_pfcp_msg *m) { struct osmo_pfcp_ie_node_id *node_id;
View file
libosmo-pfcp_0.2.0.tar.xz/src/libosmo-pfcp/pfcp_msg.c -> libosmo-pfcp_0.3.0.tar.xz/src/libosmo-pfcp/pfcp_msg.c
Changed
@@ -72,7 +72,7 @@ uint8_t message_type; uint16_t message_length; #elif OSMO_IS_BIG_ENDIAN -/* auto-generated from the little endian part above (libosmocore/contrib/struct_endianess.py) */ +/* auto-generated from the little endian part above (libosmocore/contrib/struct_endianness.py) */ uint8_t version:3, spare:2, follow_on:1, message_priority_present:1, seid_present:1; uint8_t message_type; uint16_t message_length; @@ -93,7 +93,7 @@ uint8_t message_priority:4, spare:4; #elif OSMO_IS_BIG_ENDIAN -/* auto-generated from the little endian part above (libosmocore/contrib/struct_endianess.py) */ +/* auto-generated from the little endian part above (libosmocore/contrib/struct_endianness.py) */ struct osmo_pfcp_header_common c; uint64_t session_endpoint_identifier; uint8_t sequence_nr3; @@ -550,3 +550,32 @@ { OSMO_NAME_C_IMPL(ctx, 256, "ERROR", osmo_pfcp_msg_to_str_buf, m) } + +int osmo_pfcp_msg_log_info_buf(char *buf, size_t buflen, const struct osmo_pfcp_msg *m) +{ + struct osmo_strbuf sb = { .buf = buf, .len = buflen }; + struct osmo_fsm_inst *fi = m ? (m->ctx.session_fi ?: m->ctx.peer_fi) : NULL; + enum osmo_pfcp_cause *cause = m ? osmo_pfcp_msg_cause(m) : NULL; + + if (fi) + OSMO_STRBUF_PRINTF(sb, "%s{%s}: ", + osmo_fsm_inst_name(fi), + osmo_fsm_state_name(fi->fsm, fi->state)); + else + OSMO_STRBUF_APPEND(sb, osmo_sockaddr_to_str_buf2, &m->remote_addr); + OSMO_STRBUF_PRINTF(sb, "%s PFCP seq-%u", + m->rx ? "-rx->" : "<-tx-", + m->h.sequence_nr); + if (m->h.seid_present) + OSMO_STRBUF_PRINTF(sb, " SEID-0x%"PRIx64, m->h.seid); + + OSMO_STRBUF_PRINTF(sb, " %s", osmo_pfcp_message_type_str(m->h.message_type)); + if (cause) + OSMO_STRBUF_PRINTF(sb, ": %s", osmo_pfcp_cause_str(*cause)); + return sb.chars_needed; +} + +char *osmo_pfcp_msg_log_info_c(void *ctx, const struct osmo_pfcp_msg *m) +{ + OSMO_NAME_C_IMPL(ctx, 128, "ERROR", osmo_pfcp_msg_log_info_buf, m) +}
View file
libosmo-pfcp_0.2.0.tar.xz/tests/libosmo-gtlv/Makefile.am -> libosmo-pfcp_0.3.0.tar.xz/tests/libosmo-gtlv/Makefile.am
Changed
@@ -4,7 +4,6 @@ $(NULL) AM_CPPFLAGS = \ - $(all_includes) \ -I$(top_srcdir)/include \ $(NULL)
View file
libosmo-pfcp_0.2.0.tar.xz/tests/libosmo-gtlv/test_gtlv_gen/Makefile.am -> libosmo-pfcp_0.3.0.tar.xz/tests/libosmo-gtlv/test_gtlv_gen/Makefile.am
Changed
@@ -1,5 +1,4 @@ AM_CPPFLAGS = \ - $(all_includes) \ -I$(top_srcdir)/include \ -I$(bulddir) \ $(NULL)
View file
libosmo-pfcp_0.2.0.tar.xz/tests/libosmo-gtlv/test_tliv/Makefile.am -> libosmo-pfcp_0.3.0.tar.xz/tests/libosmo-gtlv/test_tliv/Makefile.am
Changed
@@ -1,5 +1,4 @@ AM_CPPFLAGS = \ - $(all_includes) \ -I$(top_srcdir)/include \ -I$(bulddir) \ $(NULL)
View file
libosmo-pfcp_0.2.0.tar.xz/tests/libosmo-pfcp/Makefile.am -> libosmo-pfcp_0.3.0.tar.xz/tests/libosmo-pfcp/Makefile.am
Changed
@@ -1,5 +1,4 @@ AM_CPPFLAGS = \ - $(all_includes) \ -I$(top_srcdir)/include \ -I$(top_builddir)/include \ $(NULL)
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.