Browse Source

rpcd: fix respawn settings

Commit 432ec292ccc8 ("rpcd: add respawn param") has introduced infinite
restarting of the service which could be reached over network. This is
not recommended security practice as it might give potential adversary
infinite number of tries in case there might be some issue in the rpcd
or its surrounding stack.

So lets remove the currently bogus `respawn_retry` variable (it wasn't
possible to override it anyway), reverting to the previous default max.
of 5 service restarts which could be now overriden via system's UCI
settings if desired.

Cc: Jo-Philip Wich <[email protected]>
Cc: Florian Eckert <[email protected]>
Cc: Hauke Mehrtens <[email protected]>
Fixes: 432ec292ccc8 ("rpcd: add respawn param")
Signed-off-by: Petr Štetiar <[email protected]>
Petr Štetiar 5 years ago
parent
commit
52e6fb1369
1 changed files with 1 additions and 1 deletions
  1. 1 1
      package/system/rpcd/files/rpcd.init

+ 1 - 1
package/system/rpcd/files/rpcd.init

@@ -12,7 +12,7 @@ start_service() {
 
 	procd_open_instance
 	procd_set_param command "$PROG" ${socket:+-s "$socket"} ${timeout:+-t "$timeout"}
-	procd_set_param respawn ${respawn_retry:-0}
+	procd_set_param respawn
 	procd_close_instance
 }