[S] Change in ...osmo-epdg[master]: Forward IP Address from CreateSessionresponse in GSUP EPDG Tunnel Result

2024-01-25 Thread pespin
pespin has submitted this change. ( 
https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658?usp=email )

Change subject: Forward IP Address from CreateSessionresponse in GSUP EPDG 
Tunnel Result
..

Forward IP Address from CreateSessionresponse in GSUP EPDG Tunnel Result

Related: OS#6091
Change-Id: I2a9130d242830daa826414a287f54862752017d2
---
M rebar.config
M rebar.lock
M src/gsup_server.erl
3 files changed, 29 insertions(+), 5 deletions(-)

Approvals:
  laforge: Looks good to me, but someone else must approve
  Jenkins Builder: Verified
  pespin: Looks good to me, approved




diff --git a/rebar.config b/rebar.config
index a2db3ea..19688f5 100644
--- a/rebar.config
+++ b/rebar.config
@@ -6,7 +6,7 @@
{lager, {git, "https://github.com/erlang-lager/lager;, {tag, "3.9.2"}}},
{gtplib, "3.2.0"},
{osmo_ss7, {git, "https://gitea.osmocom.org/erlang/osmo_ss7;, {ref, 
"9f294d3612f998860004820d1d85b4264721577b"}}},
-   {osmo_gsup, {git, "https://gitea.osmocom.org/erlang/osmo_gsup;, 
{branch, "lynxis/epdg"}}}
+   {osmo_gsup, {git, "https://gerrit.osmocom.org/erlang/osmo_gsup;, 
{branch, "osmocom/epdg"}}}
 ]}.

 {minimum_otp_vsn, "20.3"}.
diff --git a/rebar.lock b/rebar.lock
index 322e84d..d74d179 100644
--- a/rebar.lock
+++ b/rebar.lock
@@ -11,8 +11,8 @@
{ref,"459a3b2cdd9eadd29e5a7ce5c43932f5ccd6eb88"}},
   0},
  {<<"osmo_gsup">>,
-  {git,"https://gitea.osmocom.org/erlang/osmo_gsup;,
-   {ref,"07672d8ab1608aa9c9e50ca035521876558fcd42"}},
+  {git,"https://gerrit.osmocom.org/erlang/osmo_gsup;,
+   {ref,"1a064fa6aece492352271ae164b29262d66f6b6d"}},
   0},
  {<<"osmo_ss7">>,
   {git,"https://gitea.osmocom.org/erlang/osmo_ss7;,
diff --git a/src/gsup_server.erl b/src/gsup_server.erl
index 030a328..b8ed637 100644
--- a/src/gsup_server.erl
+++ b/src/gsup_server.erl
@@ -38,6 +38,8 @@

 -include_lib("diameter_3gpp_ts29_273_swx.hrl").
 -include_lib("osmo_ss7/include/ipa.hrl").
+-include_lib("osmo_gsup/include/gsup_protocol.hrl").
+-include_lib("gtplib/include/gtp_packet.hrl").

 -define(IPAC_PROTO_EXT_GSUP,   {osmo, 5}).

@@ -179,10 +181,22 @@
lager:info("GSUP: Rx ~p~n", [GsupMsgRx]),
Result = epdg_gtpc_s2b:create_session_req(Imsi),
case Result of
-   {ok, _} ->
+   {ok, #gtp{version = v2, type = create_session_response}} ->
+   {ok, CreateSessResp} = Result,
+   IEs = CreateSessResp#gtp.ie,
+   %%#{{v2_bearer_context,0} := BearerMap} = IEs,
+   #{{v2_pdn_address_allocation,0} := Paa} = IEs,
+   PdpAddress = #{pdp_type_org => 1, pdp_type_nr => 16#21, 
address => #{ ipv4 => Paa#v2_pdn_address_allocation.address}},
+   PdpInfo = #{pdp_context_id => 0,
+   pdp_address => PdpAddress,
+   access_point_name => "foobar.apn",
+   quality_of_service => <<0, 0, 0>>,
+   pdp_charging => 0},
Resp = #{message_type => epdg_tunnel_result,
 imsi => Imsi,
-message_class => 5
+message_class => 5,
+pdp_info_complete => true,
+pdp_info_list => [PdpInfo]
};
{error, _} ->
Resp = #{message_type => epdg_tunnel_error,

--
To view, visit https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: erlang/osmo-epdg
Gerrit-Branch: master
Gerrit-Change-Id: I2a9130d242830daa826414a287f54862752017d2
Gerrit-Change-Number: 35658
Gerrit-PatchSet: 2
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: lynxis lazus 
Gerrit-Reviewer: pespin 
Gerrit-MessageType: merged


[S] Change in ...osmo-epdg[master]: Forward IP Address from CreateSessionresponse in GSUP EPDG Tunnel Result

2024-01-25 Thread pespin
Attention is currently required from: laforge, lynxis lazus.

pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658?usp=email )

Change subject: Forward IP Address from CreateSessionresponse in GSUP EPDG 
Tunnel Result
..


Patch Set 2: Code-Review+2


--
To view, visit https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: erlang/osmo-epdg
Gerrit-Branch: master
Gerrit-Change-Id: I2a9130d242830daa826414a287f54862752017d2
Gerrit-Change-Number: 35658
Gerrit-PatchSet: 2
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: lynxis lazus 
Gerrit-Reviewer: pespin 
Gerrit-Attention: laforge 
Gerrit-Attention: lynxis lazus 
Gerrit-Comment-Date: Thu, 25 Jan 2024 14:44:37 +
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


[S] Change in ...osmo-epdg[master]: Forward IP Address from CreateSessionresponse in GSUP EPDG Tunnel Result

2024-01-24 Thread pespin
Attention is currently required from: laforge, lynxis lazus.

pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658?usp=email )

Change subject: Forward IP Address from CreateSessionresponse in GSUP EPDG 
Tunnel Result
..


Patch Set 2:

(1 comment)

File rebar.config:

https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658/comment/3c5903c2_c4ee9419
PS2, Line 9:{osmo_gsup, {git, 
"https://gerrit.osmocom.org/erlang/osmo_gsup;, {branch, "osmocom/epdg"}}}
> It's actually needed because I pushed some commits there fixing the 
> PDP-Type->PDP-Address in osmo_gs […]
All that anyway is still temporary since all changes to gsup and CEAI 
interfaces are not yet merged into master since some stuff is not yet fully 
known how it will work.



--
To view, visit https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: erlang/osmo-epdg
Gerrit-Branch: master
Gerrit-Change-Id: I2a9130d242830daa826414a287f54862752017d2
Gerrit-Change-Number: 35658
Gerrit-PatchSet: 2
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: lynxis lazus 
Gerrit-Attention: laforge 
Gerrit-Attention: lynxis lazus 
Gerrit-Comment-Date: Wed, 24 Jan 2024 12:32:46 +
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: laforge 
Comment-In-Reply-To: pespin 
Gerrit-MessageType: comment


[S] Change in ...osmo-epdg[master]: Forward IP Address from CreateSessionresponse in GSUP EPDG Tunnel Result

2024-01-24 Thread pespin
Attention is currently required from: laforge, lynxis lazus.

pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658?usp=email )

Change subject: Forward IP Address from CreateSessionresponse in GSUP EPDG 
Tunnel Result
..


Patch Set 2:

(1 comment)

File rebar.config:

https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658/comment/e60bd57d_94746e26
PS2, Line 9:{osmo_gsup, {git, 
"https://gerrit.osmocom.org/erlang/osmo_gsup;, {branch, "osmocom/epdg"}}}
> probably an unrelated change to switch the repo to upstream?
It's actually needed because I pushed some commits there fixing the 
PDP-Type->PDP-Address in osmo_gsup erlang code.



--
To view, visit https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: erlang/osmo-epdg
Gerrit-Branch: master
Gerrit-Change-Id: I2a9130d242830daa826414a287f54862752017d2
Gerrit-Change-Number: 35658
Gerrit-PatchSet: 2
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: lynxis lazus 
Gerrit-Attention: laforge 
Gerrit-Attention: lynxis lazus 
Gerrit-Comment-Date: Wed, 24 Jan 2024 12:32:02 +
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: laforge 
Gerrit-MessageType: comment


[S] Change in ...osmo-epdg[master]: Forward IP Address from CreateSessionresponse in GSUP EPDG Tunnel Result

2024-01-24 Thread laforge
Attention is currently required from: lynxis lazus, pespin.

laforge has posted comments on this change. ( 
https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658?usp=email )

Change subject: Forward IP Address from CreateSessionresponse in GSUP EPDG 
Tunnel Result
..


Patch Set 2: Code-Review+1

(1 comment)

File rebar.config:

https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658/comment/aedb95e2_895945f5
PS2, Line 9:{osmo_gsup, {git, 
"https://gerrit.osmocom.org/erlang/osmo_gsup;, {branch, "osmocom/epdg"}}}
probably an unrelated change to switch the repo to upstream?



--
To view, visit https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: erlang/osmo-epdg
Gerrit-Branch: master
Gerrit-Change-Id: I2a9130d242830daa826414a287f54862752017d2
Gerrit-Change-Number: 35658
Gerrit-PatchSet: 2
Gerrit-Owner: pespin 
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge 
Gerrit-Reviewer: lynxis lazus 
Gerrit-Attention: pespin 
Gerrit-Attention: lynxis lazus 
Gerrit-Comment-Date: Wed, 24 Jan 2024 08:41:59 +
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment


[S] Change in ...osmo-epdg[master]: Forward IP Address from CreateSessionresponse in GSUP EPDG Tunnel Result

2024-01-23 Thread pespin
Attention is currently required from: lynxis lazus.

pespin has posted comments on this change. ( 
https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658?usp=email )

Change subject: Forward IP Address from CreateSessionresponse in GSUP EPDG 
Tunnel Result
..


Patch Set 2:

(1 comment)

Patchset:

PS2:
I plan to refactor this in a followup patch, probably as a gen_statem, but 
that's definetly another patch, and meanwhile can cal already pass through the 
UE IP address.



--
To view, visit https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: erlang/osmo-epdg
Gerrit-Branch: master
Gerrit-Change-Id: I2a9130d242830daa826414a287f54862752017d2
Gerrit-Change-Number: 35658
Gerrit-PatchSet: 2
Gerrit-Owner: pespin 
Gerrit-Reviewer: lynxis lazus 
Gerrit-CC: Jenkins Builder
Gerrit-Attention: lynxis lazus 
Gerrit-Comment-Date: Tue, 23 Jan 2024 11:05:59 +
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment


[S] Change in ...osmo-epdg[master]: Forward IP Address from CreateSessionresponse in GSUP EPDG Tunnel Result

2024-01-23 Thread pespin
pespin has uploaded a new patch set (#2). ( 
https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658?usp=email )


Change subject: Forward IP Address from CreateSessionresponse in GSUP EPDG 
Tunnel Result
..

Forward IP Address from CreateSessionresponse in GSUP EPDG Tunnel Result

Related: OS#6091
Change-Id: I2a9130d242830daa826414a287f54862752017d2
---
M rebar.config
M rebar.lock
M src/gsup_server.erl
3 files changed, 29 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/erlang/osmo-epdg 
refs/changes/58/35658/2
--
To view, visit https://gerrit.osmocom.org/c/erlang/osmo-epdg/+/35658?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: erlang/osmo-epdg
Gerrit-Branch: master
Gerrit-Change-Id: I2a9130d242830daa826414a287f54862752017d2
Gerrit-Change-Number: 35658
Gerrit-PatchSet: 2
Gerrit-Owner: pespin 
Gerrit-CC: Jenkins Builder
Gerrit-MessageType: newpatchset