<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Wed, Nov 22, 2017 at 2:49 PM, Trevor Perrin <span dir="ltr"><<a href="mailto:trevp@trevp.net" target="_blank">trevp@trevp.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">The Uno case seems like a slow Poly1305 implementation, though? You<br>
have Poly1305 at ~175% of the speed of ChaCha20, but [1] shows it at<br>
~75% of Salsa20 (similar to ChaCha20). If your numbers were more like<br>
[1], I think ChaChaPoly would be neck-and neck with EAX<Speck> on the<br>
Uno.<br></blockquote><div><br></div><div>I tend to stick to plain C implementations unless the performance is completely atrocious - and only then do I do AVR assembly versions. Plain C is easier to audit and quicker to get going on a new platform. But yes, if I pulled out all the stops I'm sure I could make Poly1305 faster. I'll put it on the list.<br></div><div><br></div><div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<span class="">
> We may want to have a separate discussion as to when it is acceptable to use<br>
> 64-bit block ciphers with Noise. A lot of the research in lightweight<br>
> crypto is focused on that size block. Since data volumes on small devices<br>
> isn't high, maybe 64-bit would be OK?<br>
<br>
</span>The Noise spec currently has a discussion about the (small) security<br>
concern with large data volumes and 128-bit block ciphers like AES.<br>
So I'd prefer if things went the other direction (towards PRFs like<br>
ChaCha with *less* risk than 128-bit PRPs; rather than towards more<br>
risk and tighter limits).<br></blockquote><div><br></div><div>Fair enough. Given that Speck is so fast, it should be possible for someone to design a 256-bit or 512-bit block cipher using the same idea, but I don't have the necessary math skills to try so I won't. Speck got some of its ideas from Threefish. I vaguely recall someone on the cryptography mailing list (Dan Bernstein maybe?) talking about Speck variants with larger block sizes a year or so ago. Maybe someone has a link? I haven't yet implemented Threefish-256 on Arduino but maybe I should give it a try.<br></div><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<span class=""></span>My takeaway is that ChaChaPoly/BLAKE2s looks pretty good on these<br>
devices. The speedup from faster options seems like it comes mostly<br>
just from cutting down the security level, which is probably not<br>
advisable for a general-purpose crypto protocol like Noise.<br></blockquote><div><br></div><div>That's my take at the moment too, but still looking around for other ideas.</div><div><br></div><div>Cheers,</div><div><br></div><div>Rhys.<br></div></div><br></div></div>