You can solve that by adding the following to your $SPLUNK_HOME/etc/system/local/fields.conf:
[port]
INDEXED_VALUE = false
to tell splunk its index dows not contain port's values.
Here's why... by default, when you specify a search such as:
port=13 | ...
to increase performance Splunk will automatically translate that to:
13 port=13
which means "search for all events having a "13" in their index, then filter upon them to just pick those having the field "port" equal to 13, and discard the others (which must have a "13" in some other part of the text).
So, the basic -default- assumption is "field values are present in the index".
In your case, this is just not true as the "source" field is not in the event content, so it has not been indexed. By modifying fields.conf you can change the default behaviour so that Splunk' search will just be "extract everything, then compute the port fields and pick only the port=13 event"
Just to give another example, if your events was something like
2011-01-23 13:05:51 ERROR723 Desc="asdasdasddas"
and you had a field extraction like
ERROR(?<errcode>\d+)
Than again, searching for errcode=723 would give you no results as the Splunk index only contains ERROR723 and not 723 alone. Modifying fields.conf again would solve the problem.
... View more