Merged
This commit is contained in:
commit
85e063cb3a
@ -1982,15 +1982,15 @@ namespace EduNetworkBuilder
|
|||||||
{
|
{
|
||||||
if (tPacket.MyType == PacketType.dhcp_answer)
|
if (tPacket.MyType == PacketType.dhcp_answer)
|
||||||
{
|
{
|
||||||
tPacket.AddMessage(DebugLevel.info, hostname + string.Format(NB.Translate("ND_PrepPackGtewyErr")) + " " + tPacket.OutboundIP.GetIP.ToIpString());
|
tPacket.AddMessage(DebugLevel.info, hostname + " " + string.Format(NB.Translate("ND_PrepPackGtewyErr")) + " " + tPacket.OutboundIP.GetIP.ToIpString());
|
||||||
tPacket.Tracking.Status = hostname + string.Format(NB.Translate("ND_PrepPackGtewyErr"));
|
tPacket.Tracking.Status = hostname + " " + string.Format(NB.Translate("ND_PrepPackGtewyErr"));
|
||||||
tPacket.MyStatus = PacketStatus.finished_failed;
|
tPacket.MyStatus = PacketStatus.finished_failed;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
tPacket.AddMessage(DebugLevel.info, hostname + string.Format(NB.Translate("ND_PrepPackRoutErr")) +" "+ tPacket.OutboundIP.GetIP.ToIpString());
|
tPacket.AddMessage(DebugLevel.info, hostname + " " + string.Format(NB.Translate("ND_PrepPackRoutErr")) +" "+ tPacket.OutboundIP.GetIP.ToIpString());
|
||||||
tPacket.Tracking.Status = hostname + NB.Translate("ND_PrepPackRoutErr");
|
tPacket.Tracking.Status = hostname + " " + NB.Translate("ND_PrepPackRoutErr");
|
||||||
tPacket.MyStatus = PacketStatus.finished_failed;
|
tPacket.MyStatus = PacketStatus.finished_failed;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -2003,8 +2003,8 @@ namespace EduNetworkBuilder
|
|||||||
tPacket.OutboundNic = LocalNic(tPacket.OutboundIP);
|
tPacket.OutboundNic = LocalNic(tPacket.OutboundIP);
|
||||||
if (tPacket.OutboundNic == null)
|
if (tPacket.OutboundNic == null)
|
||||||
{
|
{
|
||||||
tPacket.AddMessage(DebugLevel.info, hostname + string.Format(NB.Translate("ND_PrepPackNICErr")) + " :"+ tPacket.OutboundIP.GetIP.ToIpString());
|
tPacket.AddMessage(DebugLevel.info, hostname + " " + string.Format(NB.Translate("ND_PrepPackNICErr")) + " :"+ tPacket.OutboundIP.GetIP.ToIpString());
|
||||||
tPacket.Tracking.Status = hostname + NB.Translate("ND_PrepPackNICErr");
|
tPacket.Tracking.Status = hostname + " " + NB.Translate("ND_PrepPackNICErr");
|
||||||
tPacket.MyStatus = PacketStatus.finished_failed;
|
tPacket.MyStatus = PacketStatus.finished_failed;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -2015,8 +2015,8 @@ namespace EduNetworkBuilder
|
|||||||
tPacket.OutboundIF = tPacket.OutboundNic.LocalInterface(tPacket.OutboundIP, tPacket.Tracking);
|
tPacket.OutboundIF = tPacket.OutboundNic.LocalInterface(tPacket.OutboundIP, tPacket.Tracking);
|
||||||
if (tPacket.OutboundIF == null)
|
if (tPacket.OutboundIF == null)
|
||||||
{
|
{
|
||||||
tPacket.AddMessage(DebugLevel.info, hostname + string.Format(NB.Translate("ND_PrepPackRoutErr")) + " :" + tPacket.OutboundIP.GetIP.ToIpString());
|
tPacket.AddMessage(DebugLevel.info, hostname + " " + string.Format(NB.Translate("ND_PrepPackRoutErr")) + " :" + tPacket.OutboundIP.GetIP.ToIpString());
|
||||||
tPacket.Tracking.Status = hostname + NB.Translate("ND_PrepPackRoutErr");
|
tPacket.Tracking.Status = hostname + " " + NB.Translate("ND_PrepPackRoutErr");
|
||||||
tPacket.MyStatus = PacketStatus.finished_failed;
|
tPacket.MyStatus = PacketStatus.finished_failed;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -2193,7 +2193,7 @@ namespace EduNetworkBuilder
|
|||||||
if(nc == null)
|
if(nc == null)
|
||||||
{
|
{
|
||||||
tPacket.AddMessage(DebugLevel.info, NB.Translate("ND_DoInputFromLink_CardFail1"));
|
tPacket.AddMessage(DebugLevel.info, NB.Translate("ND_DoInputFromLink_CardFail1"));
|
||||||
tPacket.Tracking.Status = hostname + string.Format(NB.Translate("ND_DoInputFromLink_CardFail2"));
|
tPacket.Tracking.Status = hostname + " " + string.Format(NB.Translate("ND_DoInputFromLink_CardFail2"));
|
||||||
tPacket.MyStatus = PacketStatus.finished_failed;
|
tPacket.MyStatus = PacketStatus.finished_failed;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -2232,16 +2232,16 @@ namespace EduNetworkBuilder
|
|||||||
{
|
{
|
||||||
if (tPacket.MyType == PacketType.dhcp_request && !isDHCPServer)
|
if (tPacket.MyType == PacketType.dhcp_request && !isDHCPServer)
|
||||||
{
|
{
|
||||||
tPacket.AddMessage(DebugLevel.debug, hostname + string.Format(NB.Translate("ND_DoInFromLnkDeaf")));
|
tPacket.AddMessage(DebugLevel.debug, hostname + " " +string.Format(NB.Translate("ND_DoInFromLnkDeaf")));
|
||||||
tPacket.Tracking.Status = hostname + string.Format(NB.Translate("ND_DoInFromLnkNoDHCP"));
|
tPacket.Tracking.Status = hostname +" " + string.Format(NB.Translate("ND_DoInFromLnkNoDHCP"));
|
||||||
tPacket.MyStatus = PacketStatus.finished_failed;
|
tPacket.MyStatus = PacketStatus.finished_failed;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if ((tPacket.MyType == PacketType.ping_answer || tPacket.MyType== PacketType.ping_request) &&
|
if ((tPacket.MyType == PacketType.ping_answer || tPacket.MyType== PacketType.ping_request) &&
|
||||||
!RoutesPackets() && (!HasIPAddress(tPacket.destIP) && !HasBroadcastAddress(tPacket.destIP)))
|
!RoutesPackets() && (!HasIPAddress(tPacket.destIP) && !HasBroadcastAddress(tPacket.destIP)))
|
||||||
{
|
{
|
||||||
tPacket.AddMessage(DebugLevel.debug, hostname + string.Format(NB.Translate("ND_NotRouter")));
|
tPacket.AddMessage(DebugLevel.debug, hostname + " " +string.Format(NB.Translate("ND_NotRouter")));
|
||||||
tPacket.Tracking.Status = hostname + string.Format(NB.Translate("ND_NotRouter2"));
|
tPacket.Tracking.Status = hostname + " " + string.Format(NB.Translate("ND_NotRouter2"));
|
||||||
tPacket.MyStatus = PacketStatus.finished_failed;
|
tPacket.MyStatus = PacketStatus.finished_failed;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -2251,7 +2251,7 @@ namespace EduNetworkBuilder
|
|||||||
myType != NetworkComponentType.wrouter)
|
myType != NetworkComponentType.wrouter)
|
||||||
{
|
{
|
||||||
tPacket.AddMessage(DebugLevel.debug, hostname + string.Format(NB.Translate("ND_NoLocIP")));
|
tPacket.AddMessage(DebugLevel.debug, hostname + string.Format(NB.Translate("ND_NoLocIP")));
|
||||||
tPacket.Tracking.Status = hostname + string.Format(NB.Translate("ND_NoLocIP2"));
|
tPacket.Tracking.Status = hostname + " " + string.Format(NB.Translate("ND_NoLocIP2"));
|
||||||
tPacket.MyStatus = PacketStatus.finished_failed;
|
tPacket.MyStatus = PacketStatus.finished_failed;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -340,8 +340,8 @@ namespace EduNetworkBuilder
|
|||||||
myDirection = nb_direction.to_dst;
|
myDirection = nb_direction.to_dst;
|
||||||
else
|
else
|
||||||
myDirection = nb_direction.to_src;
|
myDirection = nb_direction.to_src;
|
||||||
Console.WriteLine(NB.Translate("Starting on link.") + string.Format(" SMAC: {0} DMAC: {1}",sourceMAC,destMAC));
|
Console.WriteLine(NB.Translate("P_StartingOnLink") + string.Format(" SMAC: {0} DMAC: {1}",sourceMAC,destMAC));
|
||||||
AddMessage(DebugLevel.debug, " " + "Starting on link");
|
AddMessage(DebugLevel.debug, " " + NB.Translate("P_StartingOnLink"));
|
||||||
}
|
}
|
||||||
|
|
||||||
public void StartOnDevice(NetworkDevice theDevice)
|
public void StartOnDevice(NetworkDevice theDevice)
|
||||||
@ -366,9 +366,9 @@ namespace EduNetworkBuilder
|
|||||||
}
|
}
|
||||||
if(MyType == PacketType.arp_request && MyStatus == PacketStatus.finished_failed)
|
if(MyType == PacketType.arp_request && MyStatus == PacketStatus.finished_failed)
|
||||||
{
|
{
|
||||||
Tracking.AddMessage(DebugLevel.info, "Packet",
|
Tracking.AddMessage(DebugLevel.info, NB.Translate("P_Packet"),
|
||||||
string.Format("Packet failed to reach any IP. No such IP on network: {0}", destIP.GetIPString));
|
NB.Translate("P_PacketFailedToReach") + ": " + destIP.GetIPString);
|
||||||
Tracking.Status = string.Format("Packet failed to reach IP: {0}",destIP.GetIPString);
|
Tracking.Status = NB.Translate("P_PacketFailedToReach2") + ": "+ destIP.GetIPString;
|
||||||
MyStatus = PacketStatus.finished_failed;
|
MyStatus = PacketStatus.finished_failed;
|
||||||
}
|
}
|
||||||
if (MyStatus != PacketStatus.finished)
|
if (MyStatus != PacketStatus.finished)
|
||||||
@ -448,7 +448,7 @@ namespace EduNetworkBuilder
|
|||||||
{
|
{
|
||||||
if (!typeof(T).IsSerializable)
|
if (!typeof(T).IsSerializable)
|
||||||
{
|
{
|
||||||
throw new ArgumentException("The type must be serializable.", "source");
|
throw new ArgumentException(NB.Translate("NC_CloneSerialzable"), NB.Translate("NC_source"));
|
||||||
}
|
}
|
||||||
|
|
||||||
// Don't serialize a null object, simply return the default for that object
|
// Don't serialize a null object, simply return the default for that object
|
||||||
|
Binary file not shown.
@ -1505,4 +1505,20 @@
|
|||||||
<value>Not found.</value>
|
<value>Not found.</value>
|
||||||
<comment>RTFW_NotFound = Not found.</comment>
|
<comment>RTFW_NotFound = Not found.</comment>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="P_Packet" xml:space="preserve">
|
||||||
|
<value>Packet</value>
|
||||||
|
<comment>P_Packet = Packet</comment>
|
||||||
|
</data>
|
||||||
|
<data name="P_PacketFailedToReach" xml:space="preserve">
|
||||||
|
<value>Packet failed to reach any IP. No such IP on network</value>
|
||||||
|
<comment>P_PacketFailedToReach = Packet failed to reach any IP. No such IP on network</comment>
|
||||||
|
</data>
|
||||||
|
<data name="P_PacketFailedToReach2" xml:space="preserve">
|
||||||
|
<value>Packet failed to reach IP</value>
|
||||||
|
<comment>P_PacketFailedToReach2 = Packet failed to reach IP</comment>
|
||||||
|
</data>
|
||||||
|
<data name="P_StartingOnLink" xml:space="preserve">
|
||||||
|
<value>Starting on link.</value>
|
||||||
|
<comment>P_StartingOnLink = Starting on link.</comment>
|
||||||
|
</data>
|
||||||
</root>
|
</root>
|
@ -63,16 +63,11 @@ Packet.cs:32: PacketDump(" " + status, DebugPausePoint.packet
|
|||||||
Packet.cs:125: Tracking.AddMessage(DebugLevel.routing, start, string.Format(" MAC: {0} -> {1}", source, dest));
|
Packet.cs:125: Tracking.AddMessage(DebugLevel.routing, start, string.Format(" MAC: {0} -> {1}", source, dest));
|
||||||
Packet.cs:138: Tracking.AddMessage(DebugLevel.routing, start, string.Format(" IP: {0} -> {1}", source, dest));
|
Packet.cs:138: Tracking.AddMessage(DebugLevel.routing, start, string.Format(" IP: {0} -> {1}", source, dest));
|
||||||
Packet.cs:157: Tracking.AddMessage(DebugLevel.routing, start, string.Format(" IP:{0} -> {1}", sourceIP.GetIP.ToIpString(), dest.GetIP.ToIpString()));
|
Packet.cs:157: Tracking.AddMessage(DebugLevel.routing, start, string.Format(" IP:{0} -> {1}", sourceIP.GetIP.ToIpString(), dest.GetIP.ToIpString()));
|
||||||
Packet.cs:344: AddMessage(DebugLevel.debug, " " + "Starting on link");
|
|
||||||
Packet.cs:369: Tracking.AddMessage(DebugLevel.info, "Packet",
|
|
||||||
Packet.cs:370: string.Format("Packet failed to reach any IP. No such IP on network: {0}", destIP.GetIPString));
|
|
||||||
Packet.cs:371: Tracking.Status = string.Format("Packet failed to reach IP: {0}",destIP.GetIPString);
|
|
||||||
Packet.cs:435: Console.WriteLine("Pausing");
|
Packet.cs:435: Console.WriteLine("Pausing");
|
||||||
Packet.cs:439: Console.WriteLine(string.Format("{0}: {1} PACKET: dstIP: {2} destMAC: {3}", hostname, position, dIP, destMAC));
|
Packet.cs:439: Console.WriteLine(string.Format("{0}: {1} PACKET: dstIP: {2} destMAC: {3}", hostname, position, dIP, destMAC));
|
||||||
Packet.cs:440: Console.WriteLine(string.Format("{0}: {1} PACKET: srcIP: {2} srcMAC: {3}", hostname, position, sIP, sourceMAC));
|
Packet.cs:440: Console.WriteLine(string.Format("{0}: {1} PACKET: srcIP: {2} srcMAC: {3}", hostname, position, sIP, sourceMAC));
|
||||||
Packet.cs:441: Console.WriteLine("---");
|
Packet.cs:441: Console.WriteLine("---");
|
||||||
Packet.cs:443: AddMessage(DebugLevel.packet, string.Format("{0}: {1} PACKET: dstIP: {2} destMAC: {3}", hostname, position, dIP, destMAC));
|
Packet.cs:443: AddMessage(DebugLevel.packet, string.Format("{0}: {1} PACKET: dstIP: {2} destMAC: {3}", hostname, position, dIP, destMAC));
|
||||||
Packet.cs:444: AddMessage(DebugLevel.packet, string.Format("{0}: {1} PACKET: srcIP: {2} srcMAC: {3}", hostname,position,sIP,sourceMAC));
|
Packet.cs:444: AddMessage(DebugLevel.packet, string.Format("{0}: {1} PACKET: srcIP: {2} srcMAC: {3}", hostname,position,sIP,sourceMAC));
|
||||||
Packet.cs:451: throw new ArgumentException("The type must be serializable.", "source");
|
|
||||||
PacketMessage.cs:91: tString = tmessage.HostName + " \t" + tmessage.WhatLevel.ToString() + "\t" + tmessage.Message;
|
PacketMessage.cs:91: tString = tmessage.HostName + " \t" + tmessage.WhatLevel.ToString() + "\t" + tmessage.Message;
|
||||||
PacketMessage.cs:103: tString = time.ToString() + " ms " + Status;
|
PacketMessage.cs:103: tString = time.ToString() + " ms " + Status;
|
||||||
|
Loading…
Reference in New Issue
Block a user