-
Notifications
You must be signed in to change notification settings - Fork 94
Description
Hi thank you for this wonderful library it works perfectly in esp23 from arduino ide but not in esp8266, Maybe you can give me any insights about the error in the handshake where it returns err_t -8 ERR_USE or Address in use, I have managed to overcome this by using the original lwip-wireguard implementation ping works fine but when i try to curl to the esp8266 error comes out Failed to connect to 10.1.0.4 port 80: Connection timed out, the esp8266 seems to receive the packets i can see it on the serial monitor but failed to respond back, I thought this might be some issues of NAT I tried your implementation of ->underlying_netif adn udp_sendto_if but handshake fails saying -8 ERR_USE or Address in use. Thank you, My implementation is a fork of your library with minor changes hope I can make this work soon on esp8266.
Here are some changes to make it compile in esp8266.
//in wireguardif.c wireguardif_init
#ifdef ESP8266
underlying_netif = eagle_lwip_getif(STATION_IF);
#else
tcpip_adapter_get_netif(TCPIP_ADAPTER_IF_STA, &underlying_netif);
#endifUsing hydrogen x22519.h to prevent crashing esp8266 and replacing it in crypto.h
moving all crypto files to root
removing all ESP_LOG or just doing #define ESP_LOGI(...) printf(VA_ARGS) ESP_LOGV(...) printf(VA_ARGS) etc
uncommenting esp32 includes thats isnt compatible with esp8266