hping had better reset signal mask to ensure SIGALRM is unblocked
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 3/5
- Tiempo estimado
- 1-2 días
- Aptitud para principiantes
- 45/100
- Tipo de issue
- Error
- Claridad
- Bastante claro
- Estado de actividad
- Estancado
- Stack tecnológico
- c
- Área
- cli, networking
Línea de trabajo
El issue identifica el manejo de SIGALRM de hping3 como el área afectada, pero no menciona ningún archivo fuente ni prueba. Empieza por localizar la inicialización de señales del programa y confirma el comportamiento cuando se inicia con SIGALRM bloqueado; la tarea estará terminada cuando el comando ya no se quede bloqueado en ese escenario y una comprobación de regresión lo cubra.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
We ran into an issue when using Python subprocess to call hping3 command under a Python web app server uWSGI, however the hping3 process hung forever.
It turned out that this malfunction ascribes to signal, uWSGI blocks SIGALRM, and fork(2) + exec(2) inherits the signal mask, so that the forked hping3 process starts with SIGALRM being blocked. Unfortunately SIGALRM plays a significant role in the hping app, and everything cracked.
According to SUSv4, it is recommended that signal sensitive software had better "assume that they start certain signals set unblocked":
This volume of POSIX.1-2017 specifies that signals set to SIG_IGN remain set to SIG_IGN, and that the new process image inherits the signal mask of the thread that called exec in the old process image. This is consistent with historical implementations, and it permits some useful functionality, such as the nohup command. However, it should be noted that many existing applications wrongly assume that they start with certain signals set to the default action and/or unblocked. In particular, applications written with a simpler signal model that does not include blocking of signals, such as the one in the ISO C standard, may not behave properly if invoked with some signals blocked. Therefore, it is best not to block or ignore signals across execs without explicit reason to do so, and especially not to block signals across execs of arbitrary (not closely cooperating) programs.
(from susv4-2018/functions/exec)
Therefore I was wondering if it's appropriate to make some minor improvement to avoid further issues around this cause?
- Lenguaje dominante
- C
- Estrellas
- 1.7k
- Forks
- 367
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Preparar el entorno
Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de antirez/hping
-
fix typo: "tramitted" --> "transmitted"Posiblemente ocupada Un pull request vinculado a esta issue está abierto o ya se fusionó. Abierto
Dificultad 1/5 Menos de una hora Aptitud para principiantes 72/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 48/100
-
Website different?Abierto
Dificultad 5/5 Más de una semana Aptitud para principiantes 20/100
-
Trouble compiling on RPI5Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 25/100
-
IPV6 Support?Abierto
Dificultad 5/5 Más de una semana Aptitud para principiantes 20/100
Todos los issues de antirez/hping
Issues similares
-
HTTP Request Smuggling: non-final chunked Transfer-Encoding not rejected (CWE-444)Posiblemente ocupada @code1a2024 la tomó hoy. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 77/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
jaredgei/wow-forever-android#97 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
on_ctrl_redirect(): iterator never advances — infinite loop stalls the event loop at 100% CPUAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 80/100
openziti/ziti-sdk-c#1254 ·
Los mantenedores suelen responder en 1 día
-
Requisite=graphical-session.target lets a D-Bus activation at logout cancel the target's stopAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
flatpak/xdg-desktop-portal#2215 ·
Los mantenedores suelen responder en 2 días
-
http_fetch tests: the two no-child rows fail, not skip, where a task's children file does not existPosiblemente ocupada Un pull request vinculado a esta issue está abierto o ya se fusionó. Abiertoarea:http kind:gate-defect
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
InauguralSystems/EigenScript#2397 ·
Los mantenedores suelen responder en 1 día