Sorry about that, I will correct my actions
thanks for the pointers.
The input file is merely a text file with port numbers listed for instance:
There are no quotes, commas, tabs, etc. Each line merely has a new port number in the ports file. The source file is named: 1TOP_PORTS__`date +20%y-%m-%d`.txt
So, here is what I have tried:
for i in `lynx -source "http://isc.sans.edu/trendascii.html"|sed '/SANS/d'|sed '/Commons ShareAlike/d'|sed '/#/d'|sed '/Creative/d'|sed '/(c)/d'| sed -e "s/\t/,/g"|cut -d "," -f1`; do echo "$i"; done > 1TOP_PORTS__`date +20%y-%m-%d`.txt
file=( $( < 1TOP_*.txt) )
cat global-*-ipt.log | grep "DPT\=$file"
Right now, it's grep'ing fine for the first line for the port number form the source file, but I'm drawing a blank on how to get it to iterate to the next port number from the source file.