Gateway SIP Profiles Module Documentation
Table of Contents
- Module Overview (Technical)
- Module Overview (Commercial/Business)
- Module Overview (End User/Administrator)
- Configuration Sections
- Settings Reference
- Common Scenarios & Examples
- Limitations & Important Notes
- Troubleshooting Tips
- Glossary
---
1. Module Overview (Technical)
What Are Gateway SIP Profiles?
Gateway SIP Profiles are configuration templates for SIP trunks and carriers. They define transport, codec, NAT, security, and behavior settings that are applied to gateways. This allows standardized configuration across multiple carriers with similar requirements.
Architecture
Key Tables
| Table | Purpose | |
|---|---|---|
public.gateway_sip_profiles | Profile definitions | |
public.gateway_sip_profile_settings | Profile settings |
Key Files
| File | Description | |
|---|---|---|
modules/gatewaySipProfiles/ | Frontend module | |
modules/gatewaySipProfiles/api/gatewaySipProfileApi.ts | API calls |
2. Module Overview (Commercial/Business)
Business Value
Gateway SIP Profiles provides standardized trunk configuration:
| Without Gateway Profiles | With Gateway Profiles | |
|---|---|---|
| Configure each gateway | Template once, apply many | |
| Inconsistent settings | Standardized config | |
| Repetitive work | Reusable templates | |
| Hard to maintain | Easy updates |
Use Cases
- Multi-Carrier Deployment
- Quick gateway setup
- NAT Handling
- Reliable remote carriers
- Security Standards
- Enforce security policies
- Video Calling
- Carrier-specific video
Feature Highlights
| Feature | Benefit | |
|---|---|---|
| Templates | Reusable configurations | |
| Transport Options | UDP, TCP, TLS | |
| Codec Control | Audio + Video | |
| NAT Settings | Contact rewrite | |
| T.38 Fax | Carrier fax support | |
| Security | TLS, SRTP options | |
| Debugging | SIP trace, logging |
3. Module Overview (End User/Administrator)
What Can You Do?
- Create gateway profile templates
- Configure transport protocols
- Set codec preferences (audio + video)
- Configure NAT handling
- Enable security (TLS, SRTP)
- Set timers and session limits
- Enable debugging/tracing
Gateway SIP Profiles Interface
Profile Edit View
Quick Tips
TIP
Codec Order: Drag codecs to set priority order.TIP
NAT Issues: Enable NAT Mapping and Contact Rewrite for cloud carriers.NOTE
Usage Count: Shows how many gateways use this profile.---
4. Configuration Sections
Signaling & Transport
| Setting | Description | |
|---|---|---|
| SIP Transport | UDP, TCP, or TLS | |
| DTMF Mode | RFC2833, INFO, In-band, Auto | |
| INVITE URI Format | username@domain, E.164, user-only | |
| Caller ID Policy | From, PAI, RPID | |
| NAT Mapping | Enable NAT contact rewrite | |
| Force Contact Rewrite | Always rewrite Contact | |
| Register Transport | Registration protocol | |
| SIP Timer T1 | Base retransmit timer | |
| SIP Timer T1x64 | Max retransmit timeout |
Media & Codecs
| Setting | Description | |
|---|---|---|
| Audio Codecs | PCMU, PCMA, G729, G722, OPUS, etc. | |
| Video Codecs | VP8, H264, H263, AV1 | |
| Allow Video | Enable video negotiation | |
| RTP Proxy | Force media through FS | |
| Force RTP Proxy | Always proxy RTP | |
| RTP IP | RTP bind address | |
| External RTP IP | Public IP for NAT | |
| RTCP Interval | RTCP report interval | |
| Packetization Time | Audio packet size (ms) | |
| T.38 Support | Enable T.38 fax | |
| Media Timeout | RTP timeout (seconds) |
Behavior & Timers
| Setting | Description | |
|---|---|---|
| Session Timer | Max session duration | |
| Session Refresher | UAC, UAS, or Auto | |
| Codec Negotiation | Greedy or Generous | |
| Media Timeout Mode | Drop or Ignore | |
| Max Sessions | Concurrent call limit | |
| Hold Music | MOH source |
Security / TLS
| Setting | Description | |
|---|---|---|
| Enable TLS | TLS signaling | |
| TLS Verify Policy | None, Peer, Self-signed, Optional | |
| TLS Version | 1.0, 1.1, 1.2, 1.3 | |
| Certificate Directory | Path to certs | |
| TLS Passphrase | Key passphrase | |
| Secure RTP Mode | Always, Optional, Never | |
| Require Secure Media | Enforce SRTP |
Logging & Diagnostics
| Setting | Description | |
|---|---|---|
| Debug Level | 0-9 verbosity | |
| Log Auth Failures | Track auth errors | |
| SIP Trace | Packet tracing |
5. Settings Reference
Common Profile Types
| Profile Type | Key Settings | |
|---|---|---|
| Standard Carrier | UDP, no NAT, basic codecs | |
| NAT-Safe Carrier | TCP, NAT mapping, contact rewrite | |
| Secure Carrier | TLS, SRTP required | |
| Video Enabled | Video codecs, allow video | |
| Fax Optimized | T.38 enabled, PCMU/PCMA only |
Transport Selection
| Transport | Use Case | |
|---|---|---|
| UDP | Standard carriers, low latency | |
| TCP | Large packets, NAT traversal | |
| TLS | Security required |
Codec Negotiation
| Mode | Behavior | |
|---|---|---|
| Greedy | Use your preferred order | |
| Generous | Accept peer's preference |
6. Common Scenarios & Examples
Scenario 1: Cloud Carrier (Twilio/Vonage)
- Create new profile
- Set Transport = TCP
- Enable NAT Mapping
- Enable Force Contact Rewrite
- Set codecs = PCMU, PCMA, G722
- Save and assign to gateway
Scenario 2: Secure Enterprise Trunk
- Create new profile
- Set Transport = TLS
- Enable TLS, set version = 1.2+
- Enable SRTP = Always
- Require Secure Media = Yes
- Save and assign
Scenario 3: Video SIP Trunk
- Create new profile
- Set audio codecs
- Add video codecs = VP8, H264
- Enable Allow Video
- RTP Proxy = True (if NAT)
- Save and assign
Scenario 4: Fax-Optimized Carrier
- Create new profile
- Set codecs = PCMU, PCMA only
- Enable T.38 Support = True
- Disable video
- Session timer = 300 (short for fax)
- Save and assign
---
7. Limitations & Important Notes
Technical Notes
NOTE
Profile Assignment: Profiles are assigned in Gateways module.NOTE
Sofia Profile: Must select base profile (internal/external).WARNING
Cannot Delete In-Use: Profiles with assigned gateways cannot be deleted.Best Practices
- Create Per Carrier Type: Different profiles for different carriers
- Test Thoroughly: Verify settings before production
- Use NAT Settings: Enable for cloud/SBC carriers
- Optimize Codecs: Match carrier requirements
- Enable Debugging: Use SIP trace for troubleshooting
- Document Profiles: Note what each profile is for
---
8. Troubleshooting Tips
Common Issues
| Symptom | Possible Cause | Solution | |
|---|---|---|---|
| Registration fails | Wrong transport | Check carrier requirements | |
| One-way audio | NAT/RTP issues | Enable RTP Proxy, NAT Mapping | |
| Audio quality | Wrong codec | Match carrier codecs | |
| Fax fails | No T.38 | Enable T.38 Support | |
| TLS fails | Cert issues | Check TLS settings | |
| DTMF not working | Wrong mode | Try RFC2833 vs INFO |
Carrier Compatibility Checklist
| Setting | Check | |
|---|---|---|
| Transport | Match carrier (UDP/TCP/TLS) | |
| Codecs | Support carrier's codecs | |
| DTMF | Match carrier's method | |
| NAT | Enable if behind firewall | |
| T.38 | Enable if carrier supports |
Debug Workflow
- Enable SIP Trace for profile
- Reproduce issue
- Check FreeSWITCH logs
- Look for SIP errors
- Adjust settings
- Disable trace when done
---
9. Glossary
| Term | Definition | |
|---|---|---|
| Gateway Profile | SIP settings template for trunks | |
| SIP Trunk | Connection to carrier/PSTN | |
| T.38 | Fax over IP protocol | |
| SRTP | Secure Real-time Transport Protocol | |
| NAT Mapping | Rewrite addresses for NAT | |
| Codec Negotiation | How codecs are chosen | |
| Session Timer | Call duration refresh | |
| RTP Proxy | Media through FreeSWITCH |
Lua Script Status ℹ️
No Lua Handler Required
| Component | Status |
|---|---|
| Gateway SIP Profiles | ℹ️ Configuration module - settings applied to gateway XML |
---
Documentation last updated: January 2026