<div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div>Before moving on from Alt-Svc, one idea that I thought would be great is adding a new ALPN protocol ID [1] for HTTP/2 over onions, similar to "h2" for HTTP/2 over TLS. Alec's post [2] reminded me of this and I'm sure someone has considered this before, but if not now's a good time.<br></div><div><br></div><div>First, let's all agree that all non-onion websites have to use https, otherwise none of this matters.</div><div dir="ltr"><br></div><div><b>Here's the gist of it:</b></div><div><b><br></b></div><div>Let's consider the case of "h2" ALPN for HTTP/2 over TLS:<br>1. browser requests "<a href="https://foo.com">https://foo.com</a>", receives 'alt-svc: h2="bar.onion:443"'<br>3. browser connects to bar.onion:443 port (this fails if tor socks isn't set up)<br>4. the host must pass authentication [3], which for "h2" means giving a valid certificate for "<a href="http://foo.com">foo.com</a>"<br>5. if authentication succeeds, browser displays "<a href="http://foo.com">foo.com</a>" but connects using "bar.onion" and shows "bar.onion" in the circuit display.<br><br>This scenario is great for common websites because the cookie space is always "<a href="http://foo.com">foo.com</a>", so the onion address can be transitory. In particular, even if the website doesn't own the private key to the onion service, authentication depends on TLS certificate for "<a href="http://foo.com">foo.com</a>", which the website owns.</div><div><br></div><div><br>Now, the idea is to add "h2o" ALPN for HTTP/2 over TCP via an onion service:<br>1. browser requests"<a href="https://foo.com">https://foo.com</a>", receives 'alt-svc: <b>h2o</b>="bar.onion:80'<br>3. normal browsers would ignore this, but Tor Browser connects to bar.onion:80<br>4. the host <b>must still pass an authentication</b> step for "h2o" that Tor Browser can invent<br>5. if authentication succeeds, <b>Tor Browser redirects to "bar.onion"</b>, optionally noting "<a href="http://foo.com">foo.com</a>" in the circuit display.<br><br>For the "h2o" authentication step, TBB could:</div><div>1. Use a HTTPS Everywhere type extension<br>2. Require UI announcement + confirmation<br><br>This scenario is great for websites that want to separate cookie spaces "<a href="http://foo.com">foo.com</a>" and "bar.onion" (you probably don't want a whistle-blower logged in to your onion service suddenly send cookies over an exit node) or don't want https+onion. Also, this is pretty much compatible with the Alt-Svc specifications, so it doesn't require adding a new header.</div><div><br>Note that in this case the onion address is no longer transitory, so it's important that the website should own the private key. This is critical because unlike IP addresses, domain names, or even HTTPS certificates, the private key to onion addresses doesn't expire (until offline/delegate keys are implemented).</div><div><br></div><div>Thoughts?</div><div dir="ltr"><div><br></div><div>[1] <a href="https://www.iana.org/assignments/tls-extensiontype-values/tls-extensiontype-values.xhtml#tls-extensiontype-values-1" target="_blank">https://www.iana.org/assignments/tls-extensiontype-values/tls-extensiontype-values.xhtml#tls-extensiontype-values-1</a><br></div><div>[2] <a href="https://medium.com/@alecmuffett/onion-synopsis-for-susan-hennesey-b28a92f0e974" target="_blank">https://medium.com/@alecmuffett/onion-synopsis-for-susan-hennesey-b28a92f0e974</a></div><div>[3] <a href="https://tools.ietf.org/html/draft-ietf-httpbis-alt-svc-12#section-2.1" target="_blank">https://tools.ietf.org/html/draft-ietf-httpbis-alt-svc-12#section-2.1</a><br></div></div></div></div></div></div></div></div><br><div class="gmail_quote"><div dir="ltr">On Sat, Sep 22, 2018 at 2:55 PM nusenu <<a href="mailto:nusenu-lists@riseup.net" target="_blank">nusenu-lists@riseup.net</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">(changed the subject to make clear that this is NOT about Alt-Svc anymore)<br>
<br>
I assume this is limited to onions for sites that do not aim for server side location anonymity.<br>
<br>
> FYI: the proposal is now the first Tor Browser proposal:<br>
> <a href="https://gitweb.torproject.org/tor-browser-spec.git/tree/proposals/100-onion-location-header.txt" rel="noreferrer" target="_blank">https://gitweb.torproject.org/tor-browser-spec.git/tree/proposals/100-onion-location-header.txt</a><br>
<br>
in the light of the fact that this proposal has been started before<br>
Tor Browser 8 with Alt-Svc support for .onions was a thing (and CF jumping on it [0])<br>
I'm wondering how you think about it compared to what benefits Alt-Svc provides<br>
over what Onion-Location provides?<br>
<br>
Are you unsatisfied with what RFC 7838 - HTTP Alternative Services<br>
provides or is "onion address is displayed in URL bar" one of your goals/requirements of this proposal?<br>
<br>
Although Alt-Svc does not work reliably _yet_ and the UI part is missing [3]<br>
I find it addresses some rather important issues that 'Onion-Location' does not:<br>
<br>
- users get the transport security benefits of .onions without Tor Browser displaying <br>
hard/impossible to remember/recognize randomly looking strings.<br>
<br>
Long randomly looking  strings in the domain part of the URL that would probably <br>
confuse many users and make it harder to answer the question "Am I still on the page I want to be?" <br>
(I consider it a major UX improvement that you can display the non <br>
.onion domain name while the traffic actually goes to the .onion)<br>
<br>
<br>
- users will use onions transparently <br>
without asking them questions they probably don't understand or don't want<br>
to be bothered with everytime they visit a website [1]<br>
I believe asking fewer questions, safe defaults and configuration options for advanced users<br>
are some reasonable goals.<br>
<br>
- it solves the ".onions can't get DV certs (yet)" issue<br>
<br>
<br>
<br>
<br>
<br>
<br>
[0] <a href="https://blog.cloudflare.com/cloudflare-onion-service/" rel="noreferrer" target="_blank">https://blog.cloudflare.com/cloudflare-onion-service/</a><br>
[1] <a href="https://trac.torproject.org/projects/tor/attachment/ticket/21952/21952.png" rel="noreferrer" target="_blank">https://trac.torproject.org/projects/tor/attachment/ticket/21952/21952.png</a><br>
[2] <a href="https://trac.torproject.org/projects/tor/ticket/27590" rel="noreferrer" target="_blank">https://trac.torproject.org/projects/tor/ticket/27590</a><br>
[3] <a href="https://trac.torproject.org/projects/tor/ticket/27590#comment:2" rel="noreferrer" target="_blank">https://trac.torproject.org/projects/tor/ticket/27590#comment:2</a><br>
<br>
-- <br>
<a href="https://twitter.com/nusenu_" rel="noreferrer" target="_blank">https://twitter.com/nusenu_</a><br>
<a href="https://mastodon.social/@nusenu" rel="noreferrer" target="_blank">https://mastodon.social/@nusenu</a><br>
<br>
<br>
<br>
_______________________________________________<br>
tor-dev mailing list<br>
<a href="mailto:tor-dev@lists.torproject.org" target="_blank">tor-dev@lists.torproject.org</a><br>
<a href="https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-dev" rel="noreferrer" target="_blank">https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-dev</a><br>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="m_-7437533324309335270m_-2911047112915825947m_-1289653454655230058m_2967126315234336355m_-714718963163009756gmail_signature" data-smartmail="gmail_signature"><div dir="ltr">mahrud <<a href="http://algorithms.jux-foundation.org/~mahrud/blog" target="_blank">algorithms.jux-foundation.org/~mahrud/blog</a>><br></div></div>