1LOG2PCAP(1)                      User Commands                     LOG2PCAP(1)
2
3
4

NAME

6       log2pcap - Extract network traces from Samba log files
7

SYNOPSIS

9       log2pcap [-h] [-q] [logfile] [pcap_file]
10

DESCRIPTION

12       This tool is part of the samba(7) suite.
13
14       log2pcap reads in a samba log file and generates a pcap file (readable
15       by most sniffers, such as ethereal or tcpdump) based on the packet
16       dumps in the log file.
17
18       The log file must have a log level of at least 5 to get the SMB
19       header/parameters right, 10 to get the first 512 data bytes of the
20       packet and 50 to get the whole packet.
21

OPTIONS

23       -h
24           If this parameter is specified the output file will be a hex dump,
25           in a format that is readable by the text2pcap utility.
26
27       -q
28           Be quiet. No warning messages about missing or incomplete data will
29           be given.
30
31       logfile
32           Samba log file. log2pcap will try to read the log from stdin if the
33           log file is not specified.
34
35       pcap_file
36           Name of the output file to write the pcap (or hexdump) data to. If
37           this argument is not specified, output data will be written to
38           stdout.
39
40       -?|--help
41           Print a summary of command line options.
42

EXAMPLES

44       Extract all network traffic from all samba log files:
45
46                          $ log2pcap < /var/log/* > trace.pcap
47
48
49       Convert to pcap using text2pcap:
50
51                $ log2pcap -h samba.log | text2pcap -T 139,139 - trace.pcap
52
53

VERSION

55       This man page is part of version 4.12.2 of the Samba suite.
56

BUGS

58       Only SMB data is extracted from the samba logs, no LDAP, NetBIOS lookup
59       or other data.
60
61       The generated TCP and IP headers don't contain a valid checksum.
62

SEE ALSO

64       text2pcap(1), ethereal(1)
65

AUTHOR

67       The original Samba software and related utilities were created by
68       Andrew Tridgell. Samba is now developed by the Samba Team as an Open
69       Source project similar to the way the Linux kernel is developed.
70
71       This manpage was written by Jelmer Vernooij.
72
73
74
75Samba 4.12.2                      04/28/2020                       LOG2PCAP(1)
Impressum