Reboot phone using Notify
Posted: Thu Dec 22, 2016 1:18 am
Here is the wireshark output of the reboot command that works when issued from my PBX. I would like to duplicate this in an external program. Note that 10.10.220.109 is the phone and 10.10.220.112 is the PBX. Can someone help me with the code needed in C#?
Request-Line: NOTIFY sip:101@10.10.220.109:5062 SIP/2.0
Method: NOTIFY
Request-URI: sip:101@10.10.220.109:5062
[Resent Packet: False]
Message Header
Via: SIP/2.0/UDP 10.10.220.112:5060:BRANCH=Z9Hg4Bk-D8754Z-69280EIDEF09C232-1---D8754Z-;rport
Max-Forwards: 70
Contact: <sip:101@10.10.220.112:5060>
To: <sip:101@10.10.220.112>
From: <sip:101@10.10.220.112>;tag=b85d0108
Call-ID: NjJmMjZjYjY2NTEzZmFmMWQ4NTAwNGJkN0Ix0TIzYWE.
CSeq: 1 NOTIFY
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REGISTER, SUBSCRIBE, NOTIFY, REFER, INFO, MESSAGE
Supported: replaces
User-Agent: 3CXPhoneSystem 14.0.48169.513 (48654)
Event: check-sync;reboot=true
Content-Length: 0
A couple of things that I found curious (I'm new to SIP). In the message header the "To" and "From" are both using the IP of the PBX, while in the Request-Line it uses the IP of the phone. Also, the Message Header references port 5060, while the Request-Line uses 5062. I don't know if any of the hieroglyphics represents authentication information, but if that is needed, please offer guidance there as well.
Finally, I assume if I set reboot=false, the phone will auto-provision without a reboot. Is that true, or do I need a different command?
Request-Line: NOTIFY sip:101@10.10.220.109:5062 SIP/2.0
Method: NOTIFY
Request-URI: sip:101@10.10.220.109:5062
[Resent Packet: False]
Message Header
Via: SIP/2.0/UDP 10.10.220.112:5060:BRANCH=Z9Hg4Bk-D8754Z-69280EIDEF09C232-1---D8754Z-;rport
Max-Forwards: 70
Contact: <sip:101@10.10.220.112:5060>
To: <sip:101@10.10.220.112>
From: <sip:101@10.10.220.112>;tag=b85d0108
Call-ID: NjJmMjZjYjY2NTEzZmFmMWQ4NTAwNGJkN0Ix0TIzYWE.
CSeq: 1 NOTIFY
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REGISTER, SUBSCRIBE, NOTIFY, REFER, INFO, MESSAGE
Supported: replaces
User-Agent: 3CXPhoneSystem 14.0.48169.513 (48654)
Event: check-sync;reboot=true
Content-Length: 0
A couple of things that I found curious (I'm new to SIP). In the message header the "To" and "From" are both using the IP of the PBX, while in the Request-Line it uses the IP of the phone. Also, the Message Header references port 5060, while the Request-Line uses 5062. I don't know if any of the hieroglyphics represents authentication information, but if that is needed, please offer guidance there as well.
Finally, I assume if I set reboot=false, the phone will auto-provision without a reboot. Is that true, or do I need a different command?