On Tue, Jan 26, 2016 at 10:35 AM, Tobias Klauser <tklau...@distanz.ch> wrote:
> On 2016-01-26 at 00:11:57 +0100, Vadim Kochan <vadi...@gmail.com> wrote:
>> Added trafgen syntax to set UDP header fields:
>>
>>     { udp(sport=111, dport=222) }
>>
>> Signed-off-by: Vadim Kochan <vadi...@gmail.com>
>> ---
>>  trafgen_lexer.l  |  4 ++++
>>  trafgen_parser.y | 29 +++++++++++++++++++++++++++++
>>  2 files changed, 33 insertions(+)
>>
>> diff --git a/trafgen_lexer.l b/trafgen_lexer.l
>> index 26876b4..98afc91 100644
>> --- a/trafgen_lexer.l
>> +++ b/trafgen_lexer.l
>> @@ -131,9 +131,13 @@ ip_addr          ([0-9]+\.[0-9]+\.[0-9]+\.[0-9]+)
>>  "df"         { return K_DF; }
>>  "mf"         { return K_MF; }
>>
>> +"sp"|"sport" { return K_SPORT; }
>> +"dp"|"dport" { return K_DPORT; }
>
> What about the length and checksum fields?

The keywords for them were already defined by IPv4 header syntax patch
so I just used them in trafgen_parser.y

-- 
You received this message because you are subscribed to the Google Groups 
"netsniff-ng" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to netsniff-ng+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to