diff options
author | Holger Hans Peter Freyther <zecke@selfish.org> | 2011-04-06 11:27:52 +0200 |
---|---|---|
committer | Holger Hans Peter Freyther <zecke@selfish.org> | 2011-04-06 11:29:46 +0200 |
commit | ef38e85542a92b125548c9f7913c6ca25b2fd980 (patch) | |
tree | eeb56f15a52fe46e6eb6cd2db02a4e9d8be8ac5b /openbsc/src/osmo-bsc_nat/bsc_ussd.c | |
parent | da2f769681ab4e0d671176744fb554abd25a3705 (diff) |
nat: Remember if the MSC accepted the connection on principle
For the USSD module we only want to handle requests that are
legitimate. This is achieved by looking for the CM Service Accept
or the BSSAP CIPHER MODE COMMAND.
Diffstat (limited to 'openbsc/src/osmo-bsc_nat/bsc_ussd.c')
-rw-r--r-- | openbsc/src/osmo-bsc_nat/bsc_ussd.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/openbsc/src/osmo-bsc_nat/bsc_ussd.c b/openbsc/src/osmo-bsc_nat/bsc_ussd.c index 50c50ed1f..ff1d27a0b 100644 --- a/openbsc/src/osmo-bsc_nat/bsc_ussd.c +++ b/openbsc/src/osmo-bsc_nat/bsc_ussd.c @@ -318,6 +318,10 @@ int bsc_check_ussd(struct sccp_connections *con, struct bsc_nat_parsed *parsed, if (!con->imsi) return 0; + /* We have not verified the IMSI yet */ + if (!con->authorized) + return 0; + if (!con->bsc->nat->ussd_lst_name) return 0; if (!con->bsc->nat->ussd_query) |