Call Us Today! 877.742.2583




Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: add warning

...

AttributeDescriptionAccepted valuesExample
type

Specifies the action to be taken when this rule matches the IP address under test.

Note

The rule's action always overrides the ACL's default actions (see 2.2 list tag section).


[ allow | deny ]type="allow"
cidr

Match an incoming connection by their IP address. Multiple ranges need to be separated by a comma.

Info
titleOverlapping IP address ranges

In the case of overlapping IP addresses, the rule with the more specific range will take precedence.

For example, NODE A will win over NODE B in the same list below.

Code Block
languagexml
titleacl.conf.xml
<list name="sample" default="allow">
  <!-- NODE A -->
  <node type="allow" cidr="192.168.42.42/32"/>
  <!-- NODE B -->
  <node type="deny" cidr="192.168.42.0/24"/>
</list>



Note

IPv6 ACL definitions are only supported in FreeSWITCH vesion 1.0.7 and later.


list of IP address ranges using CIDR notation

cidr="1.2.3.0/24"

cidr="12.34.56.78/32,20.0.0.0/8"

domain

Scans the user definitions of the specified domain from the directory, and if your domain's users have cidr attributes, the ACL will be automatically built.

Example usage:

Code Block
languagexml
<node type="allow" domain="$${domain}"/>

See section 3.3 Domain user example for more.

Info
titleDirectory

User definitions are usually found in ${conf_dir}/directory/default/*.xml (see XML User Directory).


Info
titleChannel variables

For $${domain}, see Channel Variables and vars.xml. (The domain variable is an alias to the domain_name variable.)


Any domain name acceptable by FreeSWITCH.domain="$${domain}"


Warning

Beware that applying the domain attribute to users changes the behavior of the sofia state machine. If you find users in the specified domain starting in the public context with an empty user_context variable, check here first.


3. ACL examples

3.1 Sample allow

...