add X=CID header to sip calls to allow homer to correlate legs

This commit is contained in:
Dave Horton
2020-01-25 13:26:27 -05:00
parent b500d676e4
commit 4a4fa485b8
3 changed files with 6 additions and 3 deletions

View File

@@ -49,7 +49,10 @@ class CallSession extends Emitter {
}
// now send the INVITE in towards the feature servers
const headers = {'X-Forwarded-For': `${this.req.source_address}:${this.req.source_port}`};
const headers = {
'X-CID': this.req.get('Call-ID'),
'X-Forwarded-For': `${this.req.source_address}:${this.req.source_port}`
};
if (this.req.locals.carrier) Object.assign(headers, {'X-Originating-Carrier': this.req.locals.carrier});
debug(`sending INVITE to ${proxy} with ${uri}`);

2
package-lock.json generated
View File

@@ -1,6 +1,6 @@
{
"name": "sbc-inbound",
"version": "0.1.0",
"version": "0.1.2",
"lockfileVersion": 1,
"requires": true,
"dependencies": {

View File

@@ -1,6 +1,6 @@
{
"name": "sbc-inbound",
"version": "0.1.1",
"version": "0.1.2",
"main": "app.js",
"engines": {
"node": ">= 10.16.0"