Skip to main content

Product

Asterisk 22 with PJSIP and FreeSWITCH 1.10 are tested. Any other SIP registrar that pgw can reach can work. One that keeps the Path header (RFC 3327) works with the default contact strategy, and one that doesn’t works with masquerade. You change the PBX’s configuration, not its code.
Any SIP app that sends RFC 8599 push parameters, connects over TLS or secure WebSocket, and is built with push credentials that you register in pgw. On iOS, the app must report every VoIP push to CallKit.
No. Pushes to an app need its publisher’s push credentials. Build the app with your own bundle ID or package name and your own credentials, and register them in pgw. See Configure apps for pgw.
No. Media flows directly between the app and the PBX.
Apache License 2.0.

Privacy

pgw never logs push tokens, push parameters, or credentials, and never sends push tokens to the PBX. In passthrough mode, the default, pgw stores no SIP passwords. In managed mode, pgw stores each user’s password encrypted. See What pgw stores.

Running pgw

Yes. The Android emulator receives real FCM pushes. Follow the Android emulator tutorial. The iOS Simulator can’t receive VoIP pushes.
iOS can suspend an app while its connection stays open. pgw sends the call on the open connection and waits provisional_timeout, 3 seconds by default, for a response before it pushes. To push for every call, set the app record’s delivery mode to always_push. See When the app is still connected.
When pgw stops, it answers each held call with 503. It keeps its bindings in SQLite, so it knows every device when it starts again, and apps reconnect and register again on their own.
No. pgw runs as a single instance. It locks data_dir at startup, so a second process on the same directory stops with data_dir is in use by another pgw process. To move pgw to another host, see Back up, move, and restore pgw.
Yes. Set upstream_listen to [::]:5060, and set upstream_hostname to a name or IPv6 address that the PBX can reach, because pgw puts it in the Via, Path, and Record-Route headers. An upstream’s host can be an IPv6 address, and invite_source_cidrs takes IPv6 prefixes. When pgw listens on IPv4 and the PBX’s host name has both IPv4 and IPv6 addresses, pgw uses IPv4.
Renew the certificate, then run systemctl reload pgw or pgw cert reload. Connected apps stay connected, and new connections get the new certificate. See Install a TLS certificate.

Next steps

Quickstart

Run pgw on your own computer and make a test call.

Troubleshooting

Find the cause when a phone doesn’t register or ring.