Ethereal-users: [Ethereal-users] capture filter question - how to use offsets

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: "Ken Young" <CiscoKid@xxxxxxxxxxxxxxx>
Date: Wed, 7 Dec 2005 21:30:35 -0400
I am trying to create a capture filter for Ethereal (0.10.13) to capture all
traffic using a tcp destination port of 23 (telnet).

I know I could simply use 'tcp dst port 23' to achieve the end result but I
would also like to know how to perform this using offsets.  Just for
learning purposes

For example;

///////////////////////////
Transmission Control Protocol, Src Port: 2545 (2545), Dst Port: telnet (23),
Seq: 22, Ack: 224, Len: 0
    Source port: 2545 (2545)
    Destination port: telnet (23)

0000  00 00 0c 07 ac 20 00 0d 56 fa 14 61 08 00 45 00   ..... ..V..a..E.
0010  00 28 4c 46 40 00 80 06 00 00 8e ef 2a 05 8e ef   .(LF@.......*...
0020  11 0b 09 f1 00 17 ca c3 7e 5f 84 b3 04 b7 50 10   ........~_....P.
0030  fa 60 59 09 00 00
////////////////////

I tried to create a capture filter such as:
tcp [2] == 00 17   And
tcp[2:2] == 00 17

but neither of them work correctly....what am I missing?

Any help would be appreciated.