I’ve seen that PJSIP has a couple of parameters to deny and permit access to the endpoints from certain IP addresses. Nonetheless, I haven’t found in the documentation what’s the difference between those parameters.
The deny and permit is for the source IP address of traffic. The contact_deny is for the address information contained within the Contact header for a REGISTER, to prevent an endpoint from registering an IP address that is outside the allowed list or subnet.