blob: 1564157adaf397bd5ad35b259beabcec105ec5a6 [file] [log] [blame]
Harald Weltea5ad7a42019-03-21 22:52:44 +01001[[chapter_overview]]
2== Overview
3
Daniel Willmann376aa9e2020-09-24 20:23:34 +02004=== About OsmoGbProxy
Harald Weltea5ad7a42019-03-21 22:52:44 +01005
Daniel Willmann376aa9e2020-09-24 20:23:34 +02006OsmoGbProxy is the Osmocom proxy for the 3GPP Gb interface. The Gb
Harald Weltea5ad7a42019-03-21 22:52:44 +01007interface is defined by 3GPP as the protocol between the BSS and the
8SGSN inside the 2G/2.5G/2.75G packet switched network domain.
9
10As Osmocom implements a BTS-colocated PCU, there are potentially many
11Gb interface connections between all those many PCUs in the network
12and the SGSN. This can be cumbersome to configure/maintain at the
Daniel Willmann376aa9e2020-09-24 20:23:34 +020013SGSN side.
Harald Weltea5ad7a42019-03-21 22:52:44 +010014
Daniel Willmann376aa9e2020-09-24 20:23:34 +020015OsmoGbProxy aggregates many PCU-facing Gb connections into one Gb
Harald Weltea5ad7a42019-03-21 22:52:44 +010016connection to the SGSN. This is achieved by
17
18* maintaining sepaate NS-VCs on the PCU side and on the SGSN side
19* more or less transparently routing BSSGP peer-to-peer Virtual Circuits
20 (BVCs) through the proxy
21* having some special handling for the signaling BVC (BVCI=0) which is
22 shared among all the PCUs connected to the proxy
23
Daniel Willmann376aa9e2020-09-24 20:23:34 +020024
Harald Weltea5ad7a42019-03-21 22:52:44 +010025=== Data Model
26
27==== gbproxy_config
28
Daniel Willmann376aa9e2020-09-24 20:23:34 +020029This contains the parsed configuration of the OsmoGbProxy.
Harald Weltea5ad7a42019-03-21 22:52:44 +010030
31==== gproxy_peer
32
33A "peer" is any remote NS-entity that the proxy interacts with. A peer
34includes information about:
35
36* the [unique] NSEI of the peer
37* the [unique] BVCI of the peer
38* the Routeing Area (RA) of the peer
39
40==== gbproxy_tlli_state
41
42One of the (unique) TLLI of any of the subscribers/UEs attached to any of
43the BTSs/PCUs served by the proxy.
44
45==== gbproxy_link_info
46
47One of the [unique] subscribers/connections that are served through this
48proxy. The information includes
49
50* the TLLI on BSS side
51* the TLLI on SGSN side (may be different due to P-TMSI rewriting)
52* the NSEI of the SGSN for this link
53* a timestamp when we last conversed with this subscriber
54* state related to IMSI acquisition
55** a temporary queue of stored messages (until IMSI acquisition succeeds)
56** N(U) rewriting state (inserting IDENTTIY REQ changes LLC sequence numbers)
57
58==== gbproxy_match
59
60A single matching rule against which IMSIs are matched. The matching rule
61is expressed as regular expression. There can be one such matching rule for
62each
63
64* routing between two different SGSNs, see below
65* patching of messages (e.g. APN, PLMN)
66
67
68=== Advanced Features
69
70==== PLMN patching
71
72This feature permits to modify the PLMN inside any BSSGP messages
73containing the Routing Area ID (RAID).
74
75The configured core-mcc and core-mnc will be used towards the SGSN,
76irrespective of which MCC/MNC the PCU is using/reporting on Gb.
77
78==== APN patching
79
80This will transparently re-write the APN name inside SM ACTIVATE PDP
81REQUEST messages on the way from the MS to the SGSN. The patching is
82performed based on matching on the IMSI of the subscriber.
83
84The configured core-apn will be used towards the SGSN, irrespective
85of which APN the MS is requesting in its Layer3 signaling.
86
87APN patching can only be performed if no GPRS encryption is enabled in
88the network!
89
90APN patching is useful in case a valid APN cannot reliably be
91provisioned via other means, such as via the SIM Card, OTA-DM or via
92CAMEL rewriting in the SGSN.
93
94==== P-TMSI patching
95
96This feature transparently rewrite the P-TMSI between MS and SGSN. This
97is required when using the Secondary SGSN support, as both SGSNs could
98allocate overlapping TMSIs and we must make sure they're unique across
99both SGSNs.
100
101P-TMSI patching is required by (and hence automatically enablede if
102secondary SGSN support is enabled.
103
104P-TMSI patching can only be performed if no GPRS encryption is enabled in
105the network!
106
107==== IMSI Acquisition
108
109This is a special feature where the proxy will by itself inject GMM IDENTITY
110REQUEST messages for the IMSI into the downlink BSSGP traffic in order
111to establish the IMSI of subscribers for which it is not otherwise known
112
113IMSI acquisition is automatically enabled if secondary SGSN support is
114enabled.
115
116==== Secondary SGSN Support
117
118This allows the proxy to connect not only to one SGSN, but to two
119different SGSNs. IMSI matching rules are applied to determine which of
120the SGSNs is to be used for traffic of this subscriber.
121
122One possible use case of this feature is to have a "local break-out" for
123subscribers who are native to this network (and hence save
124latencies/overhead of back-hauling all related traffic via the
125SGSN+GGSN) while at the same time maintaining the classic behavior for
126inbound roaming subscribers, where the roaming agreements mandate that
127data traffic is brought back to the GGSN in the HPLMN via the SGSN of
128the VPLMN.