Forum Discussion

usend_209769's avatar
usend_209769
Icon for Nimbostratus rankNimbostratus
Jul 08, 2015

Get data in position from TCP::payload

Hi,

 

I would like to get data from TCP::payload in a specific position.

 

If I try this, it works: binary scan [TCP::payload] "x2H4" data

 

the problem is that the position is variable. I try this but it does not work: binary scan [TCP::payload] "x[$pos]H4" data

 

Is possible to get the data from [TCP::payload] that is in a position stored in a variable?

 

Thanks