Skip to content

Conversation

@Takuto88
Copy link
Collaborator

Implements inbound roaming reject cause configuration. This is useful for private networks and public SIMs from other carriers try to join.

In that case, you want to respond with ROAMING_NOT_ALLOWED as reject cause in 2G/3G/4G. Otherwise, the UE may believe that its subscription is terminated.

Defaults to ROAMING_NOT_ALLOWED for a safe OOBE. Production carriers are advised to change this to IMSI_UNKNOWN.

Implements inbound roaming reject cause configuration. This is useful
for private networks and public SIMs from other carriers try to join.

In that case, you want to respond with ROAMING_NOT_ALLOWED as reject
cause in 2G/3G/4G. Otherwise, the UE may believe that its subscription
is terminated.

Defaults to ROAMING_NOT_ALLOWED for a safe OOBE. Production carriers are
advised to change this to IMSI_UNKNOWN.
@Takuto88 Takuto88 requested a review from osmith42 January 21, 2026 16:46
Copy link
Collaborator

@osmith42 osmith42 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM besides the typo and some ideas, thanks for making this!

# The latter is useful when operating a private network and public SIMs should not be allowed to connect.
# "Roaming not allowed" will cause the UE to not try again on this network.
# "Imsi unknown" may cause the UE to believe that its subscription is invalid.
# For private networks, "ROAMING_NOT_ALLOWED" is recommended. Otherwise, use "IMSI_UNKNOWN".
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about mentioning in CHANGELOG.md between ## [Unreleased] and ### Added that users may want to adjust their config to add reject_unknown_imsis_with: "ROAMING_NOT_ALLOWED" if they are running a private network?

# "Roaming not allowed" will cause the UE to not try again on this network.
# "Imsi unknown" may cause the UE to believe that its subscription is invalid.
# For private networks, "ROAMING_NOT_ALLOWED" is recommended. Otherwise, use "IMSI_UNKNOWN".
reject_unknown_imsis_with: "ROAMING_NOT_ALLOWED"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This might be too much for this pull request, so feel free to reject the idea. But how about we check if this config option (and in the future: more config options) doesn't have an unexpected value set at the start of the main service of PyHSS and refuse to start up if that is the case? This would prevent users from accidentally making a typo in the config value and then possibly running with the wrong reject unknown setting.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thought about this some more, it should be easy to add such a check in lib/pyhss_config.py.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've had the same thought the other day. I think I will just go ahead and add this to this PR as it should not be a big deal.

Co-authored-by: Oliver Smith <osmith@sysmocom.de>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants