You can try sending 405 method not allowed.
But acc to RFC3261, as soon as UAC sends a BYE, it
assumes that the session is terminated. You may not
have explicit control over by at IP Phone end. Also
see the RFC snippet here:
-----------------------------------
15.1.1 UAC Behavior
A BYE request is constructed as would any other
request within a
dialog, as described in Section 12.
Once the BYE is constructed, the UAC core creates a
new non-INVITE
client transaction, and passes it the BYE request.
The UAC MUST
consider the session terminated (and therefore stop
sending or
listening for media) as soon as the BYE request is
passed to the
client transaction. If the response for the BYE is
a 481
(Call/Transaction Does Not Exist) or a 408 (Request
Timeout) or no
response at all is received for the BYE (that is, a
timeout is
returned by the client transaction), the UAC MUST
consider the
session and the dialog terminated.
---------------------------------------
-Ranga
--- Neill Wilkinson <neill.wilkinson(a)btinternet.com>
wrote:
All,
just started using SER (great experience so far!).
I'm trying to us it for a
contact centre application where I have a specific
requirement that calls
can only be terminated in one direction, from a
Cisco AS53xx gateway, not a
Cisco phone.
Here's the set-up and desired result:
User logs into the contact centre systems which
initiates a call on the PSTN
side of the AS53xx. This then creates a VOIP (SIP)
call leg from a dial-peer
on the gateway, via the SER proxy.
The agents all have Cisco 7960 IP phones which
register with the SER
registrar. The INVITE is proxied via a simple
location lookup in the SER
route[0] config file to the appropriate handset. The
agent answers the call
and is "logged" in to the system.
Now's the fun part. I want to prevent the SIP leg
being torn-down by the
agent either accidentally or on purpose hanging up
the call from the
handset.
Here's the logic (pseudo code) I have though out:
Trap the BYE from the
handset using a statement something like:
if (method=="BYE" and uri=~"sip:[0-9]+@*") {
# Agent phone initiated the BYE so do
something
route(1);
} else {
#do something else - pass on the message I
guess
};
route[1] {
# use exec to call an external function
exec_msg ('script.file');
}
The external script needs to OK the BYE message - I
assume use the FIFO
function to construct the OK message.
Now the tricky part: how do I stop the called phone
from hanging up, (I
tried a simple 403 Forbidden response) but that
didn't work. So I thought
about the REFER method with the URL of the phone
sending the BYE message-
can I send a refer to the Gateway (AS5300) that
still thinks the dialogue is
open to the phone and "hopefully" get it to send a
new INVITE dialogue to
the phone? Or would I have to generate a new INVITE
sequence from the SER
proxy exec code?
If its the latter, then I need access to the RTP
port number on the AS53xx
from the original INVITE message - and this implies
access to the SDP
payload - which I can't see from the SER script
(unless anyone can tell me
how?)
Here's a picture of what I hope to achieve!
[AS5300} [SER Proxy}
[Cisco 7960]
----------------------------------------------->INVITE
<----------------------------------------------TRYING
>
> INVITE
> ------------------------------->
>
> <---------------------------------TRYING
>
> <---------------------------------RINGING
<----------------------------------------------RINGING
>
> <-----------------------------------OK
>
> <------------------------------------------------OK
>
> <==================RTP exchange
> =================>
>
> <-------------------------------- BYE
>
> OK
> ---------------------------------->
>
> <----------------------------------------------REFER
> (with URI of Cisco
> 7960)
-------------------------------------------------->INVITE
<-------------------------------------------------TRYING
>
> INVITE
> ----------------------------->
>
> <-------------------------------TRYING
>
> <-------------------------------RINGING
<--------------------------------------------------RINGING
<-------------------------------OK
<--------------------------------------------------
OK
<=================RTP Exchange
===================>
Thanks in advance!!! All ideas Gratefully received!
Neill....:o)
Neill Wilkinson
Senior Consultant
Quortex Consultants Ltd.
e: neill.wilkinson(a)quortex.com
_______________________________________________
Serusers mailing list
serusers(a)lists.iptel.org
http://lists.iptel.org/mailman/listinfo/serusers
_______________________________
Do you Yahoo!?
Win 1 of 4,000 free domain names from Yahoo! Enter now.
http://promotions.yahoo.com/goldrush