nmap port scanning and server.handleClient()

tyconpowered
Posts: 1
Joined: Sat Mar 16, 2024 4:31 pm

nmap port scanning and server.handleClient()

Postby tyconpowered » Sat Mar 16, 2024 4:51 pm

Hi Everyone,
I put together some simple code for a motion detection system. The system is setup as a http server with the esp32 WROOM board. I was playing with detecting new devices on a network with nmap (https://nmap.org/) when I realized the motion detection routine stops firing during certain parts of the scan. I have an LED flash during the reading of GPIO motion detection pins (2 times a second) but it stops for several seconds when I start the scan from my pc on the network.
Am I basically doing a denial of service attack on myself? Is there a simple way around this? I could probably setup the GPIO as interrupts but wanted to see if anyone had any other ideas. Ideally the system is not missing motion events.
Main loop looks like this:

Code: Select all

void loop(void) 
{
 
  timerTwo.update();//sample GPIO pins 
   check_wifi_connection.update();  //check connection and reconnect every 2 min
   web_agent.update();//wrapper to call  server.handleClient(); once a second
}

Who is online

Users browsing this forum: Google [Bot] and 98 guests