Description
Some SIP trunk providers require the PBX to send SIP REGISTER requests to enable inbound call delivery. Without registration, the provider doesn't know where to route DID calls.
Implementation
A new TrunkRegistrationModule that:
- Reads
register = true and register_expires from each trunk's config
- Sends SIP REGISTER requests to trunk providers with credential authentication
- Maintains registration with automatic re-registration at 85% of expiry interval
- Implements exponential backoff on failures
Config
[[proxy.trunks]]
name = "my-trunk"
host = "sip.provider.com"
username = "user"
password = "pass"
register = true
register_expires = 300
Files
src/proxy/trunk_register.rs — new module
src/proxy/routing/mod.rs — register and register_expires fields on TrunkConfig
src/app.rs — module registration
Reference: davidcforbes/rustpbx@a1eea50
Description
Some SIP trunk providers require the PBX to send SIP REGISTER requests to enable inbound call delivery. Without registration, the provider doesn't know where to route DID calls.
Implementation
A new
TrunkRegistrationModulethat:register = trueandregister_expiresfrom each trunk's configConfig
Files
src/proxy/trunk_register.rs— new modulesrc/proxy/routing/mod.rs—registerandregister_expiresfields onTrunkConfigsrc/app.rs— module registrationReference: davidcforbes/rustpbx@a1eea50