<div dir="ltr">Thank you Ivan,<div><br></div><div>I don't want to trust the host, that's why I'm looking for something that the _network_ agrees upon, not something the host can provide or generate itself. If the host fetches the Facebook hidden service descriptor and provides it to the card, the card can check the signature on it, then look at the time it was generated and compute the time period for it, then set its internal "clock" to that time. Unless the host can trick Facebook into using the wrong date (a future date), this should work fine. </div><div><br></div><div>An alternative that I don't want to use is to simply run a hidden service of my own that simply returns a signed statement of time ("current time at this server is HH:MM:DD"  + RSA Signature). But I don't want the system to depend on a centralized service like this, if the network already agrees on what is the current time (or time period), I want to use that.</div><div><br></div><div>I'll take a look at the doc you've linked to, thank you!</div><div><br></div><div>Razvan<br></div><div><br></div><div>--</div><div>Razvan Dragomirescu</div><div>Chief Technology Officer</div><div>Cayenne Graphics SRL</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Jun 20, 2016 at 7:51 PM, Ivan Markin <span dir="ltr"><<a href="mailto:twim@riseup.net" target="_blank">twim@riseup.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello Razan,<br>
<br>
Razvan Dragomirescu:<br>
<span class="">> I am working on a smartcard-based hidden service publishing solution and<br>
> since I'm tying the hidden service descriptor to the physical smartcard, I<br>
> want to make sure that the host is not asking the smartcard to generate<br>
> hidden service descriptors in advance, to be used when the card is no<br>
> longer inserted into the host/reader.<br>
<br>
</span>Just for the record, currently it's a problem that is going to be solved<br>
by introducing shared random randomness [1].<br>
<span class=""><br>
> The smartcard has no internal clock or time source and it's not supposed to<br>
> trust the host it's inserted into, so I need an external trusted source<br>
> that indicates the current time period. I'm not 100% familiar with the Tor<br>
> protocol (minus the hidden service parts I've been reading about recently),<br>
> so is there any way to get a feel of what the network thinks is the current<br>
> time or the current time-period? An idea would be to fetch the Facebook<br>
> hidden service descriptor or some other trusted 3rd party hidden service at<br>
> a known address and see if the time period given to the smartcard is valid<br>
> for that Facebook descriptor too. An operator could set up  one or more<br>
> trusted hidden services to match against the time-period (inside the<br>
> smartcard) before it signs a given descriptor.<br>
<br>
</span>Hmm, you seem to trust untrusted host here since you trust tor daemon<br>
running on the host for clock fetching.<br>
Anyway you're proposing to offload more tor logic onto the smartcard<br>
thus making it trusted host. For me it seems to be unreasonable for such<br>
tiny amount of resources it has. The only functon of a smartcard is to<br>
store private keys in secure manner (do not expose them, only use them).<br>
<br>
I think that a possible solution to this is to have some trusted<br>
air-gapped host with the smartcard that generates chunks of signed<br>
descriptors. This trusted host can check if the digest is legit. Then<br>
you can transfer the digests to a "postman" machine which just uploads<br>
these descriptors.<br>
[ha-ha, ironically, I'm currently creating such setup right now. I'm<br>
transferring signed digests via UART]<br>
<br>
<br>
[1]<br>
<a href="https://gitweb.torproject.org/torspec.git/tree/proposals/250-commit-reveal-consensus.txt" rel="noreferrer" target="_blank">https://gitweb.torproject.org/torspec.git/tree/proposals/250-commit-reveal-consensus.txt</a><br>
--<br>
Healthy bulbs,<br>
Ivan Markin<br>
_______________________________________________<br>
tor-dev mailing list<br>
<a href="mailto:tor-dev@lists.torproject.org">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></div>