diff --git a/content/en/admin/optional/tor.md b/content/en/admin/optional/tor.md index 9706abad0..a280b9ca5 100644 --- a/content/en/admin/optional/tor.md +++ b/content/en/admin/optional/tor.md @@ -175,7 +175,23 @@ When this happens you may uncomment the following line in your nginx.conf: # server_names_hash_bucket_size 64; ``` -If you still have problems you may consider increasing the size up to 128. +If you still have problems you may consider increasing the size up to 128. + +### Alternative Service {#alt-svc} + +You can choose to advertise the existence of the onion service with an [Alt-Svc Header]. This informs clients that the service can be accessed via Tor, and some clients with support will choose to connect that way when they see this header. An example nginx configuration could look like: + +```nginx +add_header Alt-Svc 'h2="qKnF…sKq7.onion:443"; ma=86400; persist=1'; +``` + +Notes about configuring: + +- Replace the truncated onion name with your own +- The example uses port 443, but that is not required and could be configured differently +- Because the TLS connection does not terminate at the onion service, HTTPS can use a normal non-onion TLS certificate + +[Alt-Svc Header]: https://developer.mozilla.org/en-US/docs/Web/HTTP/Reference/Headers/Alt-Svc ## Gotchas {#gotchas}