Permit and Deny calls from Extension

Hi All, Is there a way to assign multiple permit and deny by IP subnet addresses on a particular extension?

I have two IP sub net
172.16.1.0/255.255.255.0
192.168.1.0/255.255.255.0

I need when extension on 172.16.1.x range can call any no. But when it will be on 192.168.1.x call block to any extension as well as outside.

I am using FreePBX 13.0.105

Please help.