Skip to content

Add an optional flag for the export circuit id protocol on the port-by-port basis

Summary

Previously we have HiddenServiceExportCircuitID which allows us to export the circuit id using haproxy. However, such directive is applied globally in the service. We need a way to export the circuit id only for some virtual ports.

We can do that by adding an optional flag to the HiddenServicePort directive to specify that we will export the circuit id for such port.

The new syntax for HiddenServicePort directive will be:

HiddenServicePort VIRTPORT [TARGET [EXPORT-CIRCUIT-ID-PROTOCOL]]

where EXPORT-CIRCUIT-ID-PROTOCOL can be haproxy, none, or empty.

What is the expected behavior?

If the EXPORT-CIRCUIT-ID-PROTOCOL in HiddenServicePort is none or empty, the export circuit id protocol that will be used for that virtual port will be specified in HiddenServiceExportCircuitID.

If not, the export circuit id protocol will be as specified by EXPORT-CIRCUIT-ID-PROTOCOL in HiddenServicePort.

Edited by haxxpop
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information