+ def printpacket(self,packet):
+ s="";
+ i=0;
+ for foo in packet:
+ s="%s %02x" % (s,ord(foo));
+ print "#%s" % s;
+
+ def printdissect(self,packet):
+ try:
+ from scapy.all import Dot15d4
+ except ImportError:
+ print "To use packet disection, Scapy must be installed and have the Dot15d4 extension present."
+ print "try: hg clone http://hg.secdev.org/scapy-com";
+ print " sudo ./setup.py install";
+ self.printpacket(packet);
+ try:
+ scapyd = Dot15d4(packet[1:]);
+ scapyd.show();
+ except:
+ pass;