Persistent state directory for PtMgr
In PtMgr
there is currently an unused state_dir
that is set to a TempDir. But Tor's pt-spec says:
"TOR_PT_STATE_LOCATION"
Specifies an absolute path to a directory where the PT is
allowed to store state that will be persisted across
invocations. The directory is not required to exist when
the PT is launched, however PT implementations SHOULD be
able to create it as required.
PTs MUST only store files in the path provided, and MUST NOT
create or modify files elsewhere on the system.
There are three things to do here:
- We need to ensure that this directory is placed within our
state
directory. It should not be a tempdir. - We should also (ideally) give out a different state directory per transport.
- We need to pass this location as part of the PtParameters in the
state_location
argument.
Edited by Nick Mathewson