Skip to main content
Graduate II
January 21, 2025
Solved

IP Forwarding

  • January 21, 2025
  • 2 replies
  • 688 views

Hello, I have a question about LWIP functionality.

I'd like to know if it's possible to redirect a tcp request received on the pppos interface, to a device that is connected onto the ethernet interface and listening on the desired port.
Thanks in advance!

    This topic has been closed for replies.
    Best answer by STea

    Hello @RPC ,

    I assume that would be possible as mentioned in LwIP documentation and this can be done by setting 

    #define IP_FORWARD   1
    (add this to lwipopts.h)

    IP_FORWARD==1: Enables the ability to forward IP packets across network interfaces. If you are going to run lwIP on a device with only one network interface, define this to 0. refer to lwIP: IPv4.
    Regards


    2 replies

    STeaAnswer
    ST Employee
    February 18, 2025

    Hello @RPC ,

    I assume that would be possible as mentioned in LwIP documentation and this can be done by setting 

    #define IP_FORWARD   1
    (add this to lwipopts.h)

    IP_FORWARD==1: Enables the ability to forward IP packets across network interfaces. If you are going to run lwIP on a device with only one network interface, define this to 0. refer to lwIP: IPv4.
    Regards