Hello.
We are developing an application that uses JNetPCap, and we want to develop a version of that application for other operating systems.
Here are a few questions:
1.- Can JNetPCap be used in other OS's different from windows (Unix, Linux, etc.)
2.- If yes, which WinPCap alternative must be used?
3.- What JNetPCap classes/objects/methods must be modified, we use the following classes:
org.jnetpcap.Pcap;
org.jnetpcap.PcapIf;
org.jnetpcap.packet.PcapPacket;
org.jnetpcap.packet.PcapPacketHandler;
org.jnetpcap.protocol.network.Ip4;
org.jnetpcap.protocol.tcpip.Http;
org.jnetpcap.protocol.tcpip.Tcp;
thanks.
You can probably make jnetpcap work on any os that supports Java, JNI and libpcap or WinPcap, a gcc compiler.
Thanks.
So, there's no need for code modification when changing the O.S.?
There is only 1 function which looks up the MAC address of an interface that is OS specific. Everything else is libpcap and OS neutral. That method has now been ported to all of the platforms (well, pretty much all of them) even though jnetpcap is not available for them all as a whole yet.
If this is going to be a private port and you don't need the MAC address function, you could theoretically omit it if needed or no easy way to implement it (I'm thinking mobile OS here). I don't know your exact requirements.
Other then that, only build scripts would have to be updated to provide a build target for your new platform.