stdout's info
This commit is contained in:
parent
93f3dbdcf9
commit
7a75c1d171
@ -186,12 +186,6 @@ impl ArpInfo {
|
|||||||
let host_netmask = net_bit_len_to_mask(edge.device_config.get_net_bit());
|
let host_netmask = net_bit_len_to_mask(edge.device_config.get_net_bit());
|
||||||
|
|
||||||
if (ip & host_netmask) == (host_ip & host_netmask) {
|
if (ip & host_netmask) == (host_ip & host_netmask) {
|
||||||
println!(
|
|
||||||
"hostip = {:?}, ip={:?}",
|
|
||||||
host_ip.to_be_bytes(),
|
|
||||||
// host_ip.to_be_bytes(),
|
|
||||||
ip.to_be_bytes(),
|
|
||||||
);
|
|
||||||
target_ip = ip;
|
target_ip = ip;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -473,10 +473,6 @@ impl TunTapPacketHandler for Iface {
|
|||||||
let size = msg.len();
|
let size = msg.len();
|
||||||
send_packet_to_net(eee, mac, &msg, pkt_size as u64).await;
|
send_packet_to_net(eee, mac, &msg, pkt_size as u64).await;
|
||||||
// let dstip = u32::from_be_bytes(ipv4hdr.0.destination);
|
// let dstip = u32::from_be_bytes(ipv4hdr.0.destination);
|
||||||
println!(
|
|
||||||
"{:?} => {:?}, size={}",
|
|
||||||
ipv4hdr.0.source, ipv4hdr.0.destination, size
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
_ => {}
|
_ => {}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -225,8 +225,6 @@ impl TunTapPacketHandler for Iface {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
println!("got ip packet");
|
|
||||||
println!("got data: {:?}", rest);
|
|
||||||
match edge.device.send(rest) {
|
match edge.device.send(rest) {
|
||||||
Ok(size) => {
|
Ok(size) => {
|
||||||
debug!("send to tun {} bytes", size);
|
debug!("send to tun {} bytes", size);
|
||||||
@ -350,10 +348,6 @@ impl TunTapPacketHandler for Iface {
|
|||||||
let size = msg.len();
|
let size = msg.len();
|
||||||
send_packet_to_net(eee, mac, &msg, pkt_size as u64).await;
|
send_packet_to_net(eee, mac, &msg, pkt_size as u64).await;
|
||||||
// let dstip = u32::from_be_bytes(ipv4hdr.0.destination);
|
// let dstip = u32::from_be_bytes(ipv4hdr.0.destination);
|
||||||
println!(
|
|
||||||
"{:?} => {:?}, size={}",
|
|
||||||
ipv4hdr.0.source, ipv4hdr.0.destination, size
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
_ => {}
|
_ => {}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user