SIP 405 Method Not Allowed
The method is known but not allowed for this address.
4xx Client failure · RFC 3261 · Answer to OPTIONS: Up. It doesn't allow OPTIONS.
What SIP 405 means
A 405 says the server understands the request's method but doesn't allow it for the address in the Request-URI. RFC 3261 requires the response to include an Allow header listing the methods the server will accept there, so the response itself tells you what is permitted.
On trunks, 405 usually means a method is switched off by policy: OPTIONS on an SBC that doesn't want to be probed, MESSAGE or SUBSCRIBE on a PBX that doesn't offer them, or REFER on a trunk that doesn't allow transfers. It differs from 501, which means the server doesn't implement the method at all.
Example response
SIP/2.0 405 Method Not Allowed
Via: SIP/2.0/UDP 198.51.100.19:5060;branch=z9hG4bK-405-m2
From: <sip:[email protected]>;tag=3d8e
To: <sip:sbc.example.net>;tag=na-61
Call-ID: [email protected]
CSeq: 1 OPTIONS
Allow: INVITE, ACK, CANCEL, BYE
Content-Length: 0Common causes of SIP 405
- The SBC has OPTIONS disabled for peers it doesn't know, or for all peers.
- A transfer was attempted with REFER on a trunk that doesn't accept it.
- The PBX doesn't offer messaging or presence, so MESSAGE, SUBSCRIBE or PUBLISH are refused.
- The method is allowed on the server, but not for the specific address the request was sent to.
How to fix SIP 405
- Read the Allow header; it lists exactly what the server will accept at that address.
- If OPTIONS is refused, ask the SBC owner to allow it from your address, or rely on the 405 itself as proof the SBC is up.
- For refused transfers, have the PBX complete transfers itself instead of sending REFER to the trunk.
- Check that the request went to the right address; the same server may allow the method somewhere else.
SIP 405 as an answer to OPTIONS
A 405 to OPTIONS means the server is up but doesn't allow OPTIONS. The SBC is reachable and processing SIP; it just won't answer this method with a 200. A PingVo Route counts a 405 as reachable by default, so the probe still tells you when the SBC stops answering altogether.
Questions about SIP 405
What is the difference between SIP 405 and 501?
405 means the server knows the method but won't allow it for this address. 501 means it doesn't support the method anywhere.
Can I monitor an SBC that answers OPTIONS with 405?
Yes. The 405 proves the SBC is alive and parsing SIP. Silence, not the 405, is the failure to watch for.
Is a 405 without an Allow header valid?
No. RFC 3261 requires Allow in a 405. A server that leaves it out isn't following the standard, but the 405 still means the method was refused.