Age | Commit message (Collapse) | Author | Files | Lines |
|
FSM doesn't expect receiving event names containing spaces (log lines
generated are confusing).
Similar for enums, it's better using code names to match easily and make
log lines more clear.
Change-Id: I16ede8bf8352b09bc772fd7b43fad2c2274b3ec1
|
|
Change-Id: Iba22060d8646bc8ec6227684ccb91d98cb4c7be2
|
|
For new readers it's very confusing why PMM states and MM states are in
the same enum, but handled with different functions, and sometimes
called one right after the other with different enums. Calling them when
on a different ran_type makes the function early return, so let's better
conditionally call the function to make it clear in the flow when the
function is expected to do something.
Change-Id: I65ad9e180177bc9fc7c4a037cd85cfe33b161f73
|
|
Change-Id: I357f0af89f5d14d304c3e889a49a5f6c23b7fb7a
|
|
Implementation of osmo_sccp_simple_client() API internally uses ss7 id
1, which is confusing since there's no 0 in use in osmo-sgsn. Let's
explicitly use the 0 one so it is configured by "cs7 instance 0" in the
VTY.
Related: OS#4157
Change-Id: I0e23a6a76ebcba0b1b424e3d3b20d06c1da44cbe
|
|
Change-Id: I061144b6994ee40d5b32eb321dd4f3d3786d028d
|
|
Change-Id: I3b53a530ab25434e2b2f4d80ad70a8a5f22bfcac
|
|
Change-Id: Ic6912269d0d69c86f19e57f3271ebda1328e968f
|
|
This may well be the culprit of OS#3957, were already freed llme is accessed from
mmctx context later on, upon some timer is triggered in mmctx.
Related: OS#3957
Change-Id: I8e1eaeb9b3ebee8e45704b4fe007190c7db609e4
|
|
Recent commit added an assert to make sure unexpected conditions were
happening in sgsn_mm_ctx_cleanup_free(). Old code was passing
mm->gb.tlli to gprs_llgmm_assign with "new tlli" being all-1's (aka
unassign mm->gb.tlli).
The commit changed the code to use gprs_llgmm_unassign, which uses
llme->tlli instead of mm->gb.tlli, and the assert was used to make sure
no behavior change occured with the commit.
It seems TTCN3 test TC_attach_auth_id_timeout triggers that assert, and
after closer debug it seems mm->gb.tlli == llme->old_tlli, which makes
sense since there's a mm->gb.tlli_new which is expected to be
llme->tlli.
When TLLI changes in GMM (Attach Request or RA Update), it is stored
into mm->gb.tlli_new and assigned on the LLC layer using gprs_llgm_assign(),
and upon completion signalling from MS, (after handling response to initial request)
it is assigned to mm->gb.tlli (and value kept in mm->gb.tlli_new).
So mm->gb.tlli and mm->gb.tlli_new usually contain the same value unless
a new TLLI is allocated, and during the span of
Request->Response->Complete it is kept different, the LLC layer having assigned
the value of mm->gb.tlli_new.
So, old code (before the commit adding the assert) was wrongly using
mm->gb.tlli instead of mm->gb.tlli_new at the moment of unassigning (but
not really problematic in practice since behavior is the same as long as
"old TLLI" value is not all-1's.
So we are fine and correct using gprs_llgm_unassign() (which passes llme->tlli
as "old TLLI") instead of what used to be done before.
In any case, the expected behavior is to free the llme object and get
rid of everything...
Fixes: 788863cda53298c24110d0fe0f8cd3309cdec747
Change-Id: I482acdbdf05ce0cb0a5804206672512854067f5b
|
|
TS 04.64 sec 7.2.1.1 LLGMM-ASSIGN specifies:
"""
If TLLI Old all 1's and TLLI New all 1's then TLLI Old and TLLI New are assigned, and TLLI New shall
be used when (re-)transmitting LLC frames. Both TLLI Old and TLLI New shall be accepted when received
from the peer. It shall be treated as a TLLI change according to subclause 8.3.2.
"""
Change-Id: I3a17715bf2dba7b03c1335ad106307eb4d5f564a
|
|
May be useful to detect unexpected conditions which could end up in
memory leaks.
Related: OS#3957
Change-Id: I0d175501083ce458ff1c07ad38761d2cbf4ea470
|
|
Change-Id: Ib8be5af2a5e92a7403505b73ce4c1751832de40d
|
|
Change-Id: Ie8ba2b9da695de8730834abb591df64295bb6172
|
|
Change-Id: Iefb9b6dc34d87b4088c7535ef0a246103fe3f7e9
|
|
Change-Id: I4d1d47af332d4557e8a3a70c1055bcc172166016
|
|
Since March 15th 2017, libosmocore API logging_vty_add_cmds() had its
parameter removed (c65c5b4ea075ef6cef11fff9442ae0b15c1d6af7). However,
definition in C file doesn't contain "(void)", which means number of
parameters is undefined and thus compiler doesn't complain. Let's remove
parameters from all callers before enforcing "(void)" on it.
API osmo_stats_vty_add_cmds never had a param list but has seem problem
(no "void"), so some users decided to pass a parameter to it.
Change-Id: Ic4af704958819e6f65ac01be33ef5b3d69628ad0
Related: OS#4138
|
|
osmo-sgsn was missing the help text of the -V option
gb_proxy still thought of itself as OpenBSC
Omit the name of the program in the help text to avoid such issues in
the future.
Related: OS#1720
Change-Id: Ib57694b6bff7c98a269dc4b4dbb7173349a57b81
|
|
GCC 9 complains that variable 'gsm_cause' in do_act_pdp_req() may
be uninitialized. This may happen if sgsn_mm_ctx_find_ggsn_ctx()
would return NULL due to no static GGSN configured.
Change-Id: I09c608045dd35b9898b82e236a306ab9a6c2c0b9
|
|
Change-Id: Id1511c5022a239db5d0b44ec7adf048cca307751
|
|
Depends: libosmocore I52b9f6b5f3e96d85a390ba2af21d7814df8aaeec
Change-Id: Icf9f466efce520779c926b47b6e6d6c9815120eb
|
|
Previous commit introduced command "authentication (optional|required)",
which is only meaningful if auth-policy is remote. Upon adding the cmd,
it changed the default logic for remote policy to not require
authentication, which broke TTCN3 tests because sgsn no longer tries to
authenticate the users.
Since it's actually good to enable authentication by default where
possible, let's enable it by default when on auth-policy remote.
In order to do so, let's simply not care about the value of variable
require_authentication if auth_policy is not REMOTE. As a result, we
drop parts of the previous patch and remove unneeded checks (which are
only partially useful based on order of commands during VTY read).
Fixes: 794f446a284ed1ac6d31eb79a8f4c874d66fc34e
Change-Id: Ic707a95af178b44f08809df3d3bc8354bf34273c
|
|
It may be useful to have 'remote' authorization policy, but do not
require authentication in GERAN at the same time, e.g. in combination
with 'subscriber-create-on-demand' feature of OsmoHLR.
This change introduces a new VTY parameter similar to the one
that we already have in OsmoMSC:
authentication (optional|required)
Please note that 'required' only applies if 'auth-policy' is 'remote'.
Change-Id: I9909145e7e0af587c28827e16301a61b13eedaa9
|
|
Depends: osmo-ggsn.git I653cbdc185165592d985e3efab6e3f1add97877b
Related: OS#2873
Change-Id: Iaaffe0ec4d9590309c62b62c446677c6f6732f2a
|
|
Commit 176a4d2f33865a5c0433f8679f5e68f209d7b874 moved echo timer related
code to its own function but did some mistakes when moving the logic
from several places into its own function. As a result, echo timer was
only enabled after the 2nd pdp ctx was created, instead of the expected
1st.
First, let's be consistent and always call the function *after* changing
state, since that's what the function expects. This fixes the issue.
Finally make the logic in the function more intuitive by checking in the
if clause the only case where actually the echo timer should be enabled:
Only if policy specifies so and we have at least 1 pdp ctx against that ggsn.
Fixes: 176a4d2f33865a5c0433f8679f5e68f209d7b874
Change-Id: I826030978edb61ea5a172c2b72f63758206a6246
|
|
Spec also states same value is used for T3390, which we don't yet
implement.
Change-Id: I1a2276bd42d1ea5706cf9cc26d3e44baa6fbf066
|
|
Change-Id: I68e87f29711a282a97a43b175f13b3c70112ab60
|
|
In I73fd54ad3a4ab8be5aff0fee5c722597ad766e9d incorrect fix was added
which only initialize first element of array. Fix this by using explicit
index to initialize entire array.
Change-Id: I26e4aa44f159d1b5b91dda4a586fd4e809711245
|
|
Look at PDP Context Status IE: if there are any PDP contexts which are
ACTIVE on MS side and there are no PDP contexts which are ACTIVE on the
network side, then send Service Reject with the cause "NO PDP
ACTIVATED". This forces MS to reactivate the PDP contexts.
3GPP TS 24.008 Section 4.7.13.4 Service request procedure not accepted
by the network. Cause # 40.
Fixes: OS#3937
Change-Id: If610cbef17c25ec44e65d4f1b2340d102c560437
|
|
After Activate PDP Context request, Motorola KRZR
sends a zero length XID-Field of Type L3 Parameters
If this is not echoed back, the phone will send
Deactivate PDP Context request with SM Cause:
LLC or SNDCP failure(A/Gb only) (25)
Closes: OS#3426
Change-Id: Ibd75f7b943c84ed7264481fa2e4bc3cb2f6745d4
|
|
Fix a warning "Unhandled GSM 04.08 message type ...".
Fixes: OS#3466
Change-Id: I20bf4db8da746e0b994bfe3f8178188831b67ed3
|
|
gprs_sndcp_dcomp_term asserts if compclass is not
SNDCP_XID_DATA_COMPRESSION, so this way by checking in the caller too we
easily now if the unexpected value is in compclass or in algo.dcomp.
Change-Id: I4600e6a137f42f20fdf69637e4a9048b265c1748
|
|
If we ever only use 0/1 in an 'int', we should have used 'bool'.
Change-Id: I63876f52d5de87e4c99d92669270fd1f487e217c
|
|
For every logical session between a MS and the SGSN, there is one LLME
(LLC Management Entity) and a set of LLEs (Logical Link Entities): One
for each SAPI.
The XID procedure used to establish LLC configuration values such as
N201 (MTU) parameters happens on each LLE separately. The negotiated
parameters only affect that one LLE (SAPI) and are not global.
Still, the OsmoSGSN LLC code has the "struct llist_head *xid" member as
part of the gprs_llc_llme, and not as part of the gprs_llc_lle. This
list is a cache of the XID fields we have sent with the last XID
request, which is used in processing the response from the MS.
If two XID handshakes were to occur concurrently on two LLEs, the state
between them would get messed up. It must be maintained separately for
each LLE.
Closes: OS#3955
Change-Id: Iaeb54ca5ac58391be45e56c2e721f531969f3a9e
|
|
According to Section 6.4.1.4 of 3GPP TS 04.64
The DM unnumbered response shall be used by an LLE to report to
its peer that the LLE is in a state such that ABM operation
cannot be performed. An LLE shall transmit a DM response to any
valid command received that it cannot action.
Closes: OS#3953
Change-Id: Ie8b8e16d5a68f19f21dc4fdb5703c8a794e0173c
|
|
A MS sending LLC NULL frames on cell change is a perfectly normal event,
and we shouldn't log any cryptic NOTICE messages about it.
Change-Id: I6be0b9c8813dfb40a7955422fd8e7cebf94d189c
|
|
In reality, only UI, I, SABM, UA and XID frames carry payload. All
other frames will have llhp.data == NULL.
Let's therefore not do any msgb adjustments unless we actually know
there is a user payload field.
Change-Id: I51bbd0f2c618d477a037af343ff41de1c8a5a3ae
Closes: OS#3952
|
|
Change-Id: I8799e3a3c47377aeeb9923d9d73f5d0b73cd8d0b
|
|
Attach Requests
A security command is part of multiple procedures to ensure
integrity (optional also encryption) between MS and RNC.
It should be used for all Iu connections once.
With the rewrite of the GMM Attach FSM the use of the security command
procedure was broken for all procedures e.g. Service Request except GMM
Attach Request.
Relates: OS#3920
Change-Id: I50e8e316f06ae1a6171a6b07e4e2f0761322b779
|
|
UE expects to receive Iu-ReleaseCommand after Attach Complete. If it
doesn't receive it, then it sends Iu-ReleaseRequest after a timeout
which makes the "PS Activation" process long.
Change-Id: Ib5053e3cd655d08ff3fd0fefa48325fabb1797c8
Related: OS#3908
|
|
This fixes following error:
DMM gprs_gmm.c:1126
GMM_ATTACH_REQ_FSM(gb_gmm_req)[0x5589e78dded0]{WaitAttachComplete}:
Event VLR answered not permitted
There seems to be a race condition in FSM when MS establishes MM context
which isn't immediately followed up by PDP context (for example when no
APN is configured in MS).
This does not affect actual functionality because in this case MS won't
be able to use GPRS anyway but it's still nice to get our FSM fixed even
in this corner case.
Change-Id: I14d234632224e20faf865d2273c83cfff31abf61
|
|
* don't use spaces when printing hex data like RAND, SRES etc to
increase the chance that it'll fit onto single line which will improve
readability
* don't print non-existent QoS value
Change-Id: I0a09063f30c1116803994117f49df9d02bcc9181
|
|
Add a 'gsup ipa-name' VTY command which overrides the default
IPA name used by the SGSN on the GSUP link towards the HLR.
This is required for GSUP routing in multi-SGSN networks.
The 'gsup ipa-name' option can only be set via the config file
because changing the IPA name at run-time conflicts with active
GSUP connections and routes configured in the HLR. The osmo-sgsn
program must be restarted if its IPA name needs to change.
Related: OS#3356
Change-Id: Ib2f65fed9f56b9718e8a9647e3f01dce69870c1f
|
|
We were passing a NULL pointer of type struct gsm_network * to
ctrl_interface_setup_dynip(). Remove the pointless declaration
of this struct. Also, replace the sgsn_controlif_setup() helper
function with a direct call to ctrl_interface_setup_dynip().
The helper fnuction was just a thin wrapper around the latter.
Change-Id: Ib4151afa5bff01e63b462cca517fb60ac0503759
Related: OS#3356
|
|
This is necessary to properly test ACLs in follow-up patches.
Change-Id: Ibeba371234680f33ad35afbfffce9dca185228c1
|
|
Use OSMO_MIN macro to check for MSISDN length. This makes the code
cleaner and will, hopefully, aid static analysis tools.
Change-Id: Ic0fbeb8d248c74e54bfb51ba2cdea55c4f386ac7
Fixes: CID57879
|
|
This requires I414e67a3de733fab407161b3264d3b89070ba537 in libosmocore
to avoid warning about discarded const.
Change-Id: Ie92637dd900b0f9eba891d5aad0b4ba0ee69c08c
|
|
The code which has been used for 4 years is hardly temporary.
Change-Id: Ibe9c62e0beb89eecced941b8831d49ca266c7330
|
|
Log line actually makes more sense out of the function where IMSI acq is
resolved. We can then get rid of msg param which may cause confusion and
add complexitiy to code for no good reason.
Change-Id: I6716a260e12a3cf36af0501ce611c6c1e608f537
|
|
It makes no sense to print every stored_msg with BVCI from msg, same for
routing. This will allow getting rid of "msg" completelly in next
commit.
Change-Id: I95eafbf41012be3e02c68fc996773dd02b174fe6
|