After ACL rules are configured, a multicast device can filter the received multicast packets based on source addresses or source/group addresses.
A PIM device checks the passing multicast data. By checking whether the data matches the filtering rule, the router determines whether to forward the data. In this case, you can regard the router as the filter of the multicast data. The filter helps to control the data flow and limit the information that downstream receivers can obtain. Network security is thus ensured.
Configure a basic ACL.
Configure an advanced ACL.
Run the acl [ number ] acl-number [ vpn-instance vpn-instance-name ] command to create an advanced ACL and access its view.
Run the rule [ rule-id ] { permit | deny } protocol [ source { source-ip-address { 0 | source-wildcard } | address-set address-set-name | any } | destination { destination-ip-address { 0 | destination-wildcard } | address-set address-set-name | any } ] * command to configure rules for the advanced ACL.
If a basic ACL is used, run the rule command and set the source parameter to the source address of multicast packets.
If an advanced ACL is used, run the rule command, set the source parameter to the source address of multicast packets, and set the destination parameter to a multicast group address.
pim [ vpn-instance vpn-instance-name ]
source-policy acl-number
The effect of the filtering is more obvious if the filter is closer to the source.
The source-policy command does not filter the static (S, G) entries and the PIM entries of the Join messages received from private networks.