Re: [asterisk-users] Fwd: Sublime Text License Key

2015-10-07 Thread Optical Phoenix
Yeah... I emailed them and let them know I screwed up, but no reply. I
humbly request you don't use my key. Sublimetext is pretty great, and you
can download and use it for free, fully functional, without pretending to
be me. The nag screen is even polite. I'm so embarrassed that I did this...

On Mon, Oct 5, 2015 at 12:05 PM, Steve Howes 
wrote:

> On 05/10/15 16:18, Mitul Limbani wrote:
>
>>
>> The company making sublime text gets few thousands of dollars of notional
>> loss :)
>>
>> I was thinking more about if they'd built in software activation type
> stuff. But yea, stealing bad etc too.
>
> Steve
>
>
> --
> _
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
> New to Asterisk? Join us for a live introductory webinar every Thurs:
>   http://www.asterisk.org/hello
>
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>   http://lists.digium.com/mailman/listinfo/asterisk-users
>
-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

[asterisk-users] Change Contact field in sip invite

2015-10-07 Thread Andrew Colin
Hi Guys

 

Does anyone know of a way I can change the contact field in the sip invite
to display sip:username:ip instead of sip:did:ip

We need to do this without changing the from field.

I tried using fromuser=username  but that just modifies both the contact and
the from parameter

 

I know in freeswitch they use the parameter extension-In-Contact

 

Has anyone managed to do this before?

 

-- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

[asterisk-users] Storing HANGUPCAUSE in CDR

2015-10-07 Thread Ross Beer
Hi,
I have the following code that operates when a channel is hung-up:
[record-hangupcause]exten => 1,n,Set(CDR(hangupcause)=${HANGUPCAUSE})exten => 
s,n,Return()
Before the dial a hangup handler is registered:
Set(CHANNEL(hangup_handler_push)=record-hangupcause,s,1)
The routine is called and the variables are being set, however not on the 
channel's CDR which made the call. I believe this is due to the CDR being 
closes as soon as the dial returns. 
By changing the cdr option 'endbeforehexten=no' this should keep the CDR 
accessible, however all this does is cause another CDR to be created for the 
'h' extension.
Is there a way to update the CDR so that a result can be stored per dial?
Thank you in advance,
Ross



  -- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] PJSIP: how to retrieve underlying SIP Call-ID

2015-10-07 Thread Michael Ulitskiy
Hello Matt,

That works (CHANNEL(pjsip,call-id)). Thanks.

I'm still interested to know if PJSIP_HEADER is supposed to be able to read 
headers of the outbound channel.

I'm also very interested to know if there's any way in asterisk to access 
headers received in "200 OK" reply,
as my proxy returns some important information there.

Thanks a lot,

Michael

On Tuesday, October 06, 2015 05:06:34 PM Matthew Jordan wrote:
> On Tue, Oct 6, 2015 at 3:25 PM, Michael Ulitskiy  wrote:
> > Hello,
> >
> >
> >
> > I've started to play with PJSIP and got stuck at the following problem.
> >
> > I need to retrieve SIP Call-ID associated with PJSIP channel.
> >
> > For inbound channel I can use ${PJSIP_HEADER(read,Call-ID)}, but that
> > doesn't work for
> >
> > outbound channel even in pre-dial or hangup handler. Whatever I do
> > PJSIP_HEADER
> >
> > seem to be unable to read headers for outbound channel.
> >
> >
> >
> > Here's what I do:
> >
> >
> >
> > [xyz]
> >
> > exten => 999,1,NoOp(Call-ID: ${PJSIP_HEADER(read,Call-ID)})
> >
> > same =>
> > n,Dial(PJSIP/xyz011101/sip:xyz011101@:5060,30,b(_pre_dial,s,1))
> >
> > exten => h,1,NoOp()
> >
> >
> >
> > [_pre_dial]
> >
> > exten => s,1,NoOp(Call-ID: ${PJSIP_HEADER(read,Call-ID)})
> >
> > same => n,Set(CHANNEL(hangup_handler_push)=_hangup,s,1())
> >
> > same => n,Return
> >
> >
> >
> > [_hangup]
> >
> > exten => s,1,NoOp(Call-ID: ${PJSIP_HEADER(read,Call-ID)})
> >
> > same => n,Return
> >
> >
> >
> >
> >
> > Here's the result:
> >
> > -- Executing [999@xyz:1] NoOp("PJSIP/poly_650_2_01-006f", "Call-ID:
> > e3e249e5-7e8941dd-da386565@192.168.100.238") in new stack
> >
> > -- Executing [999@xyz:2] Dial("PJSIP/poly_650_2_01-006f",
> > "PJSIP/xyz011101/sip:xyz011101@:5060,30,b(_pre_dial,s,1)")
> > in new stack
> >
> > -- PJSIP/xyz011101-0070 Internal Gosub(_pre_dial,s,1) start
> >
> > -- Executing [s@_pre_dial:1] NoOp("PJSIP/xyz011101-0070", "Call-ID: ")
> > in new stack
> >
> > -- Executing [s@_pre_dial:2] Set("PJSIP/xyz011101-0070",
> > "CHANNEL(hangup_handler_push)=_hangup,s,1()") in new stack
> >
> > -- Executing [s@_pre_dial:3] Return("PJSIP/xyz011101-0070", "") in new
> > stack
> >
> > == Spawn extension (xyz, 999, 1) exited non-zero on
> > 'PJSIP/xyz011101-0070'
> >
> > -- PJSIP/xyz011101-0070 Internal Gosub(_pre_dial,s,1) complete
> > GOSUB_RETVAL=
> >
> > -- Called PJSIP/xyz011101/sip:xyz011101@:5060
> >
> > == Using SIP RTP Audio TOS bits 184
> >
> > -- PJSIP/xyz011101-0070 is ringing
> >
> > -- PJSIP/xyz011101-0070 Internal Gosub(_hangup,s,1) start
> >
> > -- Executing [s@_hangup:1] NoOp("PJSIP/xyz011101-0070", "Call-ID: ") in
> > new stack
> >
> > -- Executing [s@_hangup:2] Return("PJSIP/xyz011101-0070", "") in new
> > stack
> >
> > == Spawn extension (xyz, 999, 1) exited non-zero on
> > 'PJSIP/xyz011101-0070'
> >
> > -- PJSIP/xyz011101-0070 Internal Gosub(_hangup,s,1) complete
> > GOSUB_RETVAL=
> >
> > == Spawn extension (xyz, 999, 2) exited non-zero on
> > 'PJSIP/poly_650_2_01-006f'
> >
> > -- Executing [h@xyz:1] NoOp("PJSIP/poly_650_2_01-006f", "") in new stack
> >
> >
> >
> > As you can see I can get Call-ID of inbound channel, but I receive null for
> > the outbound channel in both pre-dial and hangup handlers.
> >
> >
> >
> > So my question is if there's a way to retrieve SIP Call-ID for outbound
> > channels?
> >
> > Also the 2nd question is if PJSIP_HEADER is supposed to be able to read
> > headers of the outbound channel?
> >
> 
> Hi Michael -
> 
> While you can use PJSIP_HEADER, the ability to retrieve the SIP
> Call-ID through the CHANNEL function on a PJSIP channel was actually
> just added in 13.6.0, and should be in the latest RC (13.6.0-rc2 [2]).
> 
> In either case, you're using a function as opposed to some
> application, which means you do need to call the functions on the
> specific channel. To get access to the outbound channel, you can use a
> pre-dial handler's 'b' option [3]. The Call-ID *should* be set up on
> the underlying invite session in the PJSIP dialog, even though it
> hasn't been transmitted yet.
> 
> Matt
> 
> [1] https://gerrit.asterisk.org/#/c/1204/
> [2] http://downloads.asterisk.org/pub/telephony/asterisk/ChangeLog-13.6.0-rc2
> [3] https://wiki.asterisk.org/wiki/display/AST/Pre-Dial+Handlers
> 
> -- 
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users