
#-----------------------------------------------------------------------
# MODULE CONFIGURATION
#-----------------------------------------------------------------------
#
# This configuration was based on:
# http://service.real.com/firewall/adminfw.html
#
#m# 23
#a# accept
#i# cluster novirtual
#n# real
#t# servers
#
#   |--------------------------------------------------------------------|
#d# real-servers (Port 554, 7070 TCP, 7070 UDP)
#d# Allow connections to Real Player servers. You must configure your
#d# RealPlayer clients to communicate using UDP on port 7070 only,
#d# otherwise they will not work.
#   |--------------------------------------------------------------------|
#
#-----------------------------------------------------------------------
# START OF MODULE CODE
#-----------------------------------------------------------------------

for host in `Option_Value accept $INTOPT real servers`
do
	echo "Accept $INTOPT $IPADDR -> $HOST RealPlayer $LOG_MSG"
	# Data stream
	ipchains -A $inchain  -j ACCEPT -p udp -s $HOST   $UNPRIVPORTS -d $IPADDR 7070              $LOG
	# Communication protocols
	ipchains -A $outchain -j ACCEPT -p tcp -s $IPADDR $UNPRIVPORTS -d $HOST   554               $LOG
	ipchains -A $outchain -j ACCEPT -p tcp -s $IPADDR $UNPRIVPORTS -d $HOST   7070              $LOG
	ipchains -A $inchain  -j ACCEPT -p tcp -s $HOST   554          -d $IPADDR $UNPRIVPORTS ! -y $LOG
	ipchains -A $inchain  -j ACCEPT -p tcp -s $HOST   7070         -d $IPADDR $UNPRIVPORTS ! -y $LOG
done
unset host
