Opened 8 months ago

Closed 3 months ago

#23847 closed enhancement (implemented)

Make sure Tor can shut down via control port, and start again in same process

Reported by: hellais Owned by:
Priority: Medium Milestone: Tor: 0.3.3.x-final
Component: Core Tor/Tor Version:
Severity: Normal Keywords: tor-mobile, s8-api, 034-triage-20180328, 034-removed-20180328
Cc: darkk, brade, mcs, ahf, nickm, mike@…, arthuredelstein, cretz Actual Points:
Parent ID: #23684 Points:
Reviewer: Sponsor: Sponsor8

Description

In order to stop tor and restart it cleanly, we would need a tor control port command to tell it to stop and cleanup all it's state so we can call the tor main again.

This involves ensuring that all static variables are properly reset and cleanup is done correctly.

Having good integration tests can go a long ways in ensuring that nothing breaks here.

Child Tickets

TicketTypeStatusOwnerSummary
#24581defectclosednickmDon't crash when restarting Tor in the same process
#24583enhancementclosednickmMake it easy to debug restart-in-process
#24584defectclosednickmFix memory-leaked event_base_once() users.
#24587defectclosednickmReset bootstrapping state on shutdown

Change History (11)

comment:1 Changed 8 months ago by mtigas

Cc: mike@… added

comment:2 Changed 8 months ago by arthuredelstein

Cc: arthuredelstein added

comment:3 Changed 8 months ago by nickm

This doesn't necessarily need to be a new command; it could also be new behavior for (say) "SIGNAL SHUTDOWN" or "SIGNAL HALT".

comment:4 Changed 8 months ago by nickm

Sponsor: Sponsor8

comment:5 Changed 8 months ago by nickm

Summary: Add shutdown command to Tor control portMake sure Tor can shut down via control port, and start again in same process

comment:6 Changed 8 months ago by ahf

Keywords: s8-api added

comment:7 Changed 5 months ago by cretz

Cc: cretz added

comment:8 Changed 3 months ago by nickm

Keywords: 034-triage-20180328 added

comment:9 Changed 3 months ago by nickm

Keywords: 034-removed-20180328 added

Per our triage process, these tickets are pending removal from 0.3.4.

comment:10 Changed 3 months ago by nickm

Reparenting children to #25510 and closing.

comment:11 Changed 3 months ago by nickm

Milestone: Tor: 0.3.4.x-finalTor: 0.3.3.x-final
Resolution: implemented
Status: newclosed
Note: See TracTickets for help on using tickets.