Prevent calls between extensions

Prevent calls between extensions
I would like to prevent extensions 101 to 218 from calling each other
But 100 has to call and receive from all extensions …
Suggestions?

The high level of this:

  1. Create a custom context
  2. Include from-internal
  3. Add dialplan entries for exten => 101 and 218 to Playback(tt-weasels)
  4. Put 101 and 218 devices in the custom context
1 Like

@yois is spot on. In extensions_custom.conf, something like

[Block]
exten => 101,1,playback(ss-noservice)
exten => 101,n,Hangup()
exten => 218,1,playback(ss-noservice)
exten => 218,n,Hangup()
include => from-internal

Then add those two extensions to that context in FreePBX.

1 Like

just going to be “That Guy” for a moment…

you’re looking for a technical solution to an HR Problem (or so it seems)

Hello @claloano,

Add this dialplan to your extensions_custom.conf file:

[from-internal-custom]
;;; Block extension 101 to call extension 218 and vice versa ;;;
exten=> 218/101,1,Log(NOTICE,Extension ${CALLERID(num)} is calling ${EXTEN})
same => n,Hangup

exten=> 101/218,1,Log(NOTICE,Extension ${CALLERID(num)} is calling ${EXTEN})
same => n,Hangup
;;; End Block extension 101 to call extension 218 and vice versa ;;;

Thank you,

Daniel Friedman
Trixton LTD.

2 Likes

Thanks for the help but maybe not I was completely clear:
The extensions from 101 onwards … up to 218 must not be able to call each other.
While the 100 is free to receive and call everyone

Hello @claloano,

If I understood correctly, extensions 101-218 do not allow call to each other except extension 100.
If something is not working for you, send me the logs.

[from-internal-custom]
;;; Block extension 101-218 to call each other (except extension 100) ;;;

;Allow dialing to extension 100 from extensions 100-299
exten => 100/_[12]XX,1,Log(NOTICE,Extension ${CALLERID(num)} is calling ${EXTEN})
same => n,Goto(from-internal,${EXTEN},1)

;Allow dialing from extension 100 to extensions 100-299
exten => _[12]XX/100,1,Log(NOTICE,Extension ${CALLERID(num)} is calling ${EXTEN})
same => n,Goto(from-internal,${EXTEN},1)

;Block dialing to extensions 100-299
exten=> _[12]XX/_[12]XX,1,Log(NOTICE,Extension ${CALLERID(num)} is calling ${EXTEN})
same => n,Hangup

;;; End  Block extension 101-218 to call each other (except extension 100) ;;;

Thank you,

Daniel Friedman
Trixton LTD.

2 Likes

Do something like this to the phones:

Do Not Press These Buttons

6 Likes

fantastic! was what I was looking for!

1 Like

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.