Свойство | Тип | Описание | |
---|---|---|---|
AppNode | |||
Ethernet | |||
Info | |||
PublicInfo | |||
PublicNode |
Свойство | Тип | Описание | |
---|---|---|---|
_address_resolver | IAddressResolver | ||
_broadcast | bool | ||
_checked_out | |||
_conn_handler | ConnectionHandler | ||
_dhcp_client_port | int | ||
_dhcp_config | |||
_dhcp_server | Ipop.DhcpServer | ||
_dhcp_server_port | int | ||
_dns | Dns | ||
_ether_to_dhcp_server | DhcpServer>.Dictionary | ||
_ether_to_ip | MemBlock>.Dictionary | ||
_ip_to_ether | MemBlock>.Dictionary | ||
_ipop_config | |||
_last_check_node | System.DateTime | ||
_lock | int | ||
_multicast | bool | ||
_static_dhcp_server | Ipop.DhcpServer | ||
_static_mapping | SimpleTimer>.Dictionary | ||
_sync | object | ||
_translator | ITranslator |
Метод | Описание | |
---|---|---|
CalculateNetmaskCidr ( string netmask ) : int |
Converts from a.b.c.d to the number of 1s in a.b.c.d (CIDR notation).
|
|
HandleData ( MemBlock b, ISender ret, object state ) : void |
This method handles all incoming packets into the IpopNode, both abroad and local. This is done to reduce unnecessary extra classes and circular dependencies. This method probably shouldn't be called directly.
|
|
HandleIPIn ( MemBlock packet, ISender ret ) : void |
This method handles IPPackets that come from Brunet, i.e., abroad.
|
|
HandleRpc ( ISender caller, string method, IList args, object rs ) : void | ||
IpopNode ( |
Creates an IpopNode given a NodeConfig and an IpopConfig. Also sets up the Information, Ethernet device, and subscribes to Brunet for IP Packets
|
|
Run ( ) : void |
Starts the execution of the IpopNode, this passes the caller to execute the Brunet.Connect to eventually become Brunet.AnnounceThread.
|
Метод | Описание | |
---|---|---|
CheckInDhcpServer ( Ipop.DhcpServer dhcp_server ) : void |
The request on the IP allocation space (DHT) has returned. So we're done with the server.
|
|
CheckNode ( object o, |
||
CheckOutDhcpServer ( MemBlock ether_addr ) : Ipop.DhcpServer |
Static addresses are handled nearly identically to dynamic, so we use one shared method to pull a dhcp server from the list of dhcp servers. We only want one request per Ethernet / IP at a time.
|
|
GetDhcpConfig ( ) : void |
We need to get the DHCPConfig as soon as possible so that we can allocate static addresses, this method helps us do that.
|
|
GetDhcpServer ( ) : Ipop.DhcpServer |
Used to retrieve an instance of the DhcpServer associated with this type of node.
|
|
HandleArp ( MemBlock packet ) : void |
Parses Arp Packets and writes to the Ethernet the translation. IpopRouter makes nodes think they are in the same Layer 2 network so that two nodes in the same network can communicate directly with each other. IpopRouter masquerades for those that are not local. |
|
HandleBroadcast ( |
This method is called by HandleIPOut if the destination address is the broadcast address. If you want Broadcast, implement this method, output will most likely be sent via the SendIP() method in the IpopNode base class.
|
|
HandleDhcp ( |
This is used to process a dhcp packet on the node side, that includes placing data such as the local Brunet Address, Ipop Namespace, and other optional parameters in our request to the dhcp server. When receiving the results, if it is successful, the results are written to the TAP device.
|
|
HandleDns ( |
If a request is sent to address a.b.c.255 with the dns port (53), this method will be called by HandleIPOut. If you want Dns, implement this method, responses should be written directly to the tap interface using Ethernet.Send()
|
|
HandleIPOut ( |
This method handles IPPackets that come from the TAP Device, i.e., local system. Currently this supports HandleMulticast (ip[0] >= 244 && ip[0]<=239), HandleDns (dport = 53 and ip[3] == 1), dhcp (sport 68 and dport 67. |
|
HandleMulticast ( |
This method is called by HandleIPOut if the destination address is within the multicast address range. If you want Multicast, implement this method, output will most likely be sent via the SendIP() method in the IpopNode base class.
|
|
HandleNewStaticIP ( MemBlock ether_addr, MemBlock ip ) : void |
Let's see if we can route for an IP. Default is do nothing!
|
|
IsLocalIP ( MemBlock ip ) : bool |
Is this our IP? Are we routing for it?
|
|
MappingMissing ( MemBlock ip ) : bool | ||
MissedMapping ( string ip, Brunet.Address addr ) : void | ||
SendIP ( Brunet.Address target, MemBlock packet ) : void |
Sends the IP Packet to the specified target address.
|
|
SendIcmpRequest ( MemBlock dest_ip ) : void |
This sends an Icmp Request to the specified address, we want him to respond to us, so we can guarantee that by pretending to be the Server (i.e. x.y.z.1). We'll get a response in our main thread.
|
|
SetDns ( ) : void | ||
SetTAAuth ( ) : void | ||
SupportedDns ( string dns ) : bool | ||
UpdateMapping ( MemBlock ether_addr, MemBlock ip_addr ) : void |
Called when an ethernet address has had its IP address changed or set for the first time.
|
|
WriteIP ( ICopyable packet ) : void |
Writes an IPPacket as is to the TAP device.
|
public static CalculateNetmaskCidr ( string netmask ) : int | ||
netmask | string | |
Результат | int |
protected CheckInDhcpServer ( Ipop.DhcpServer dhcp_server ) : void | ||
dhcp_server | Ipop.DhcpServer | |
Результат | void |
protected CheckNode ( object o, |
||
o | object | |
ea | ||
Результат | void |
protected CheckOutDhcpServer ( MemBlock ether_addr ) : Ipop.DhcpServer | ||
ether_addr | MemBlock | |
Результат | Ipop.DhcpServer |
protected abstract GetDhcpServer ( ) : Ipop.DhcpServer | ||
Результат | Ipop.DhcpServer |
protected HandleArp ( MemBlock packet ) : void | ||
packet | MemBlock | |
Результат | void |
protected HandleBroadcast ( |
||
ipp | The IPPacket the contains the broadcast message | |
Результат | bool |
public HandleData ( MemBlock b, ISender ret, object state ) : void | ||
b | MemBlock | The incoming packet |
ret | ISender | An ISender to return data from the original sender. |
state | object | always will be null |
Результат | void |
protected HandleDhcp ( |
||
ipp | The IPPacket that contains the Dhcp Request | |
Результат | bool |
protected HandleDns ( |
||
ipp | The IPPacket contain the Dns packet | |
Результат | bool |
public HandleIPIn ( MemBlock packet, ISender ret ) : void | ||
packet | MemBlock | The packet from Brunet. |
ret | ISender | An ISender to send data to the Brunet node that sent /// the packet. |
Результат | void |
protected HandleIPOut ( |
||
packet | The packet from the TAP device | |
ret | ISender | |
Результат | void |
protected HandleMulticast ( |
||
ipp | The IPPacket the contains the multicast message | |
Результат | bool |
protected HandleNewStaticIP ( MemBlock ether_addr, MemBlock ip ) : void | ||
ether_addr | MemBlock | |
ip | MemBlock | The IP in question. |
Результат | void |
public HandleRpc ( ISender caller, string method, IList args, object rs ) : void | ||
caller | ISender | |
method | string | |
args | IList | |
rs | object | |
Результат | void |
public IpopNode ( |
||
node_config | The path to a NodeConfig xml file | |
ipop_config | The path to a IpopConfig xml file | |
dhcp_config | ||
Результат | Brunet |
protected IsLocalIP ( MemBlock ip ) : bool | ||
ip | MemBlock | The IP in question. |
Результат | bool |
protected MappingMissing ( MemBlock ip ) : bool | ||
ip | MemBlock | |
Результат | bool |
protected MissedMapping ( string ip, Brunet.Address addr ) : void | ||
ip | string | |
addr | Brunet.Address | |
Результат | void |
protected SendIP ( Brunet.Address target, MemBlock packet ) : void | ||
target | Brunet.Address | the Brunet Address of the target |
packet | MemBlock | the data to send to the recepient |
Результат | void |
protected SendIcmpRequest ( MemBlock dest_ip ) : void | ||
dest_ip | MemBlock | |
Результат | void |
protected SupportedDns ( string dns ) : bool | ||
dns | string | |
Результат | bool |
protected UpdateMapping ( MemBlock ether_addr, MemBlock ip_addr ) : void | ||
ether_addr | MemBlock | |
ip_addr | MemBlock | |
Результат | void |
protected WriteIP ( ICopyable packet ) : void | ||
packet | ICopyable | The IPPacket! |
Результат | void |
public ApplicationNode,Brunet.Applications AppNode | ||
Результат |
public Information,Brunet.Applications Info | ||
Результат |
public Information,Brunet.Applications PublicInfo | ||
Результат |
public ApplicationNode,Brunet.Applications PublicNode | ||
Результат |
protected IAddressResolver _address_resolver | ||
Результат | IAddressResolver |
protected Hashtable,System.Collections _checked_out | ||
Результат |
protected ConnectionHandler _conn_handler | ||
Результат | ConnectionHandler |
protected Dictionary |
||
Результат | DhcpServer>.Dictionary |
protected DateTime,System _last_check_node | ||
Результат | System.DateTime |
protected DhcpServer,Ipop _static_dhcp_server | ||
Результат | Ipop.DhcpServer |
protected Dictionary |
||
Результат | SimpleTimer>.Dictionary |