package edu.uci.iotproject;
import org.pcap4j.core.*;
-import org.pcap4j.packet.*;
-import org.pcap4j.packet.DnsPacket;
-import org.pcap4j.packet.namednumber.DnsResourceRecordType;
import java.io.EOFException;
-import java.net.Inet4Address;
import java.net.UnknownHostException;
-import java.util.*;
import java.util.concurrent.TimeoutException;
/**
public static void main(String[] args) throws PcapNativeException, NotOpenException, EOFException, TimeoutException, UnknownHostException {
- //final String fileName = "/users/varmarken/Desktop/wlan1.local.dns.pcap";
- final String fileName = "/home/rtrimana/pcap_processing/smart_home_traffic/Code/Projects/SmartPlugDetector/pcap/wlan1.local.remote.dns.pcap";
- final String trainingFileName = "/home/rtrimana/pcap_processing/smart_home_traffic/Code/Projects/SmartPlugDetector/pcap/TP_LINK_LOCAL_OFF.pcap";
+ final String fileName = args.length > 0 ? args[0] : "/home/rtrimana/pcap_processing/smart_home_traffic/Code/Projects/SmartPlugDetector/pcap/wlan1.local.remote.dns.pcap";
+ final String trainingFileName = "./pcap/TP_LINK_LOCAL_OFF.pcap";
// ====== Debug code ======
PcapHandle handle;