Website

Website accounts, content on this website, etc..

Website moving to a new server

The website is moving to a new server over next few days. Apologies up front for any disruption of service.

No URI changes, just physically moving all content to newer hardware.

Website will continue to be accessible at: http://jnetpcap.com

Sincerely,
mark...

openOffline Method to access from Android Internal Storage

Hi everyone,

I am using JnetPcap library to extract the packets from a Mobile Wireshark application required for Android project analysis. I have to capture the IP address from the pcap file and display the same on the Google Maps.

I am facing an issue reading the Internal Storage of the Android phone using the openOffline method... Can this method be used for Android Internal Storage File Directory ?? The same code is working if the directory path is specified in Windows OS running on a PC....

Any inputs would be highly appreciated...

Please find below the code for the same.

package appprofiler.appprofilerv1;

/**
* Created by soory_000 on 11/30/2015.
*/

import android.os.Environment;

import java.io.File;
import java.util.ArrayList;
import java.util.Date;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import org.jnetpcap.Pcap;
import org.jnetpcap.nio.JMemory;
import org.jnetpcap.packet.JFlow;
import org.jnetpcap.packet.JFlowKey;
import org.jnetpcap.packet.JFlowMap;
import org.jnetpcap.packet.JPacket;
import org.jnetpcap.packet.JPacketHandler;
import org.jnetpcap.packet.JScanner;
import org.jnetpcap.packet.PcapPacket;
import org.jnetpcap.protocol.network.Ip4;
import org.jnetpcap.protocol.tcpip.Http;
import org.jnetpcap.protocol.tcpip.Tcp;

public class IPExtract {
final static List ipaddress = new ArrayList();
private static String FILENAME;

public IPExtract(String Filename) {
this.FILENAME = Filename;
}

public static void main(String[] args) {
final StringBuilder errbuf = new StringBuilder();
final Pcap pcap = Pcap.openOffline(FILENAME, errbuf); // While trying to debug I am getting a Library error
if (pcap == null) {
System.err.println(errbuf);
return;
}

Account approval required from now on!

I have enabled account approval setting on the website. This will allow me to review new member accounts before approving.

Unfortunately we have been hit by heavy spam on the website. I increased CAPTCHA test to high settings in hopes of preventing SPAM accounts but it did not work. Lately we've been getting up to a dozen spam articles per day and its just too much at this point.

Eventually things may calm down and I will relax the approval process for new users.

Outgoing and Incoming Tcp Packets

Hi Mark,

I dont have a lot of experience with jnetpcap.
I'm writing a program and I need to get the outgoing an the incoming Tcp packets. The communication is between my Computer and a WebService at Port 80.

I was thinking of smth like that:

tcp.source = 80; for the outgoing packets

It doesn't work Sad

Can you help me please??

Regards Ona

question about filters

Hi, I have a question... I just need to capture VOIP packets(core protocols of jnetpcap), can I use PcapBpfProgram??, if I can, how is the expression in :

PcapBpfProgram program = new PcapBpfProgram();
pcap.compile(program, "xxxxxxxxxxxx", 0, 0);

xxxxxx = ???
the solution can be .... xxxxx= "port sip || port rtp || port sdp" ??????

or another one?

...thanks .....

Atte. Richar F.V.

Syndicate content