From 1c9072541b842f066ec880d9b911c7d068845852 Mon Sep 17 00:00:00 2001 From: Eric Wild Date: Wed, 23 Sep 2026 17:51:04 +0200 Subject: [PATCH] osmo-smdpp: add --smdp-address to set ES9+ SM-DP+ address The ES9+ SM-DP+ address is used for the smdpAddress check and for serverSigned1.serverAddress, both default to HOSTNAME. Add --smdp-address (default: HOSTNAME) so the advertised address can carry a port and still match what the LPA connects to when the TLS endpoint is bound to other ports than 443. TLS certificate identity is unaffected, this is only the ES9+ address. SGP.22 defines both smdpAddress and serverSigned1.serverAddress as an FQDN. Taken strictly that leaves no way to run an SM-DP+ on a port other than 443, so an address with a port is arguably outside the spec but needed for testing. Change-Id: I2fa822c7d5e0d5b68a6704a1779f9923505f9008 --- osmo-smdpp.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/osmo-smdpp.py b/osmo-smdpp.py index 8120b0fc..2add23f1 100755 --- a/osmo-smdpp.py +++ b/osmo-smdpp.py @@ -916,12 +916,17 @@ def main(argv): action='store_true', default=False) parser.add_argument("-m", "--in-memory", help="Use ephermal in-memory session storage (for concurrent runs)", action='store_true', default=False) + parser.add_argument("--smdp-address", default=HOSTNAME, + help="ES9+ SM-DP+ address advertised, defaults to \"%(default)s\". " + "Include the TLS port (e.g. %(default)s:8443) when binding a port other " + "than 443, so it matches the address the LPA connects to. " + "The TLS certificate identity is unaffected.") args = parser.parse_args() logging.basicConfig(level=logging.DEBUG if args.verbose else logging.WARNING) common_cert_path = os.path.join(DATA_DIR, args.certdir) - hs = SmDppHttpServer(server_hostname=HOSTNAME, ci_certs_path=os.path.join(common_cert_path, 'CertificateIssuer'), common_cert_path=common_cert_path, use_brainpool=args.brainpool) + hs = SmDppHttpServer(server_hostname=args.smdp_address, ci_certs_path=os.path.join(common_cert_path, 'CertificateIssuer'), common_cert_path=common_cert_path, use_brainpool=args.brainpool) if(args.nossl): hs.app.run(args.host, args.port) else: