Block External Direct Extention Dial

I would like to block external users from being able to directly dial an extension via the phonebook or at the IVR.

Any help would be appreciated.

There is a check box for this in the IVR setup.

Not certain how it works if they use the phonebook…