|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectverinec.importer.analysis.PortDescriptor
public class PortDescriptor
A descriptor for each port number on a host.
The HostCommRenderer keeps a mapping of port numbers and PortDescriptors
It contains the number of packets sent and received,
and an XML element for the service running on that port as described by the
generic-service element of node.xsd
| Field Summary | |
|---|---|
private String |
Description
|
private int |
packetCount
Number of packets for that port in sniffing phase. |
private Element |
portXML
|
| Constructor Summary | |
|---|---|
PortDescriptor(String protocol,
int portid,
String state)
Create a minimalistic port description. |
|
| Method Summary | |
|---|---|
int |
getCount()
Fetch the packet counter. |
Element |
getPortXML()
Fetch the service description. |
void |
incrementCounter()
Increment the packet counter (packets sent to this port). |
void |
setPortFromNmap(Element nmapPort)
Convert an nmap port element to the node.xsd schema generic-service. |
void |
setPortXML(Element portXML)
Set the service description element of the service running on this portnumber. |
String |
toString()
Retruns a String containing the number and the description of the ports. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
private int packetCount
private Element portXML
private String Description
| Constructor Detail |
|---|
public PortDescriptor(String protocol,
int portid,
String state)
protocol - The protocol running on this port. One of tcp, udp or ip.portid - The port number.state - The port state (nmap values)| Method Detail |
|---|
public void setPortXML(Element portXML)
portXML - A generic-service element as in node.xsd.public void setPortFromNmap(Element nmapPort)
nmapPort - Nmap XML output port element.public Element getPortXML()
public void incrementCounter()
public int getCount()
public String toString()
toString in class Object
|
Copyright © 2005 Verinec, DIUF | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||