Jpcap openDevice错误

时间:2014-07-19 11:44:37

标签: java jpcap

我已经安装了64位版本的jpcap.dll,它似乎工作正常,我可以用JpcapCaptor获取我的设备列表。但我在openDevice有一个错误......这是我的代码:

public class Main {

    public static void main(String[] args) {
        NetworkInterface[] devices = JpcapCaptor.getDeviceList();
        try {
            JpcapCaptor captor = JpcapCaptor.openDevice(devices[1], 65535, false, 20);
        } catch (IOException e) {
            e.printStackTrace();
        }
    }
}

错误说:“java.lang.NoSuchMethodError: setRoutingOption

我不知道我做错了什么。它可能来自dll吗?

编辑: 这是清单:

0: \Device\NPF_{8B9933B7-3C46-4A4E-95D2-653B8602A770}(Sun)
 datalink: EN10MB(Ethernet)
 MAC address:8:0:27:0:f0:e5:
 address:/fe80:0:0:0:b003:4e05:c35f:adc5 null null
 address:/192.168.56.1 /255.255.255.0 /255.255.255.255
1: \Device\NPF_{FDEF9FDE-2BEA-4C5C-8760-AD6DEF0EFC43}(Microsoft)
 datalink: EN10MB(Ethernet)
 MAC address:1c:65:9d:7a:cf:d7:
 address:/fe80:0:0:0:39f5:e1e8:faa5:aac1 null null
 address:/192.168.0.35 /255.255.255.0 /255.255.255.255
2: \Device\NPF_{9035FA42-9672-47A1-A179-98C7ABA89DE8}(Atheros L1C PCI-E Ethernet Controller)
 datalink: EN10MB(Ethernet)
 MAC address:b8:70:f4:ab:f8:be:
 address:/fe80:0:0:0:5d04:6a8d:1c78:5c59 null null
 address:/0.0.0.0 /255.0.0.0 /255.255.255.255

由于

0 个答案:

没有答案