Openwall GNU/*/Linux - a small security-enhanced Linux distro for servers
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date: Mon, 19 Mar 2012 20:24:41 +0530
From: Dhiru Kholia <dhiru.kholia@...il.com>
To: john-dev@...ts.openwall.com
Cc: Erik Winkler <ewinkler@...ls.com>
Subject: vncpcap2john.cpp + Mac OS X

On Mon, Mar 19, 2012 at 7:45 PM, Erik Winkler <ewinkler@...ls.com> wrote:
> Dhiru,
>
> A note on vncpcap2john.cpp.  This will not work on BSD platforms (like MacOS X) because it uses the non-portable Linux only tcphdr for raw sockets.  I get the following compile error:
>
> vncpcap2john.cpp: In member function ‘bool Packet_Reader::kick()’:
> vncpcap2john.cpp:128: error: ‘const struct tcphdr’ has no member named ‘doff’
> vncpcap2john.cpp:143: error: ‘const struct tcphdr’ has no member named ‘source’
> vncpcap2john.cpp:143: error: ‘const struct tcphdr’ has no member named ‘source’
> vncpcap2john.cpp:143: error: ‘const struct tcphdr’ has no member named ‘source’
> vncpcap2john.cpp:143: error: ‘const struct tcphdr’ has no member named ‘source’
> vncpcap2john.cpp:148: error: ‘const struct tcphdr’ has no member named ‘dest’
> vncpcap2john.cpp:148: error: ‘const struct tcphdr’ has no member named ‘dest’
> vncpcap2john.cpp:148: error: ‘const struct tcphdr’ has no member named ‘dest’
> vncpcap2john.cpp:148: error: ‘const struct tcphdr’ has no member named ‘dest’
>
> See this note (http://en.wikipedia.org/wiki/Tcphdr)
>
> You would need to modify the code to use the BSD format as Linux supports both of versions.  You can then set Linux to choose the BSD format with the #define __USE_BSD and #define __FAVOR_BSD flags in the source code.

Thanks for the report Erik. I don't know much about socket
programming. I am forwarding this to the list, so that someone else
can have a look too.

-- 
Cheers,
Dhiru

Powered by blists - more mailing lists

Your e-mail address:

Powered by Openwall GNU/*/Linux - Powered by OpenVZ