- IPOut(const IPAddr& ip, RouteTable& rtable, std::ostream& log = std::cout);
+ IPOut(const IPAddr& ip, RouteTable& rtable, Dev& forward_que,
+ std::ostream& log = std::cout);
/// Descarta un paquete
void drop(const std::string& msg, const std::string& buf);
void drop(const std::string& msg, const IPHeader& iph);
/// Descarta un paquete
void drop(const std::string& msg, const std::string& buf);
void drop(const std::string& msg, const IPHeader& iph);
bool send(const std::string& data, uint8_t proto, IPAddr dst,
IPAddr src = 0, bool df = 0, uint8_t ttl = 64, uint16_t id = 0)
throw (std::runtime_error);
bool send(const std::string& data, uint8_t proto, IPAddr dst,
IPAddr src = 0, bool df = 0, uint8_t ttl = 64, uint16_t id = 0)
throw (std::runtime_error);
+ /// Envía un paquete IP ya armado
+ bool send(IPHeader iph, std::string data) throw (std::runtime_error);
+
+ /// Realiza el forwarding de paquetes (en un loop infinito)
+ void forward_loop() throw (std::runtime_error);
+