[erlang-questions] A pointless problem?
Joe Armstrong
erlang@REDACTED
Sat Nov 17 18:33:22 CET 2012
On Sat, Nov 17, 2012 at 6:02 PM, Steve Davis <steven.charles.davis@REDACTED
> wrote:
> I am intrigued by what is arguably a pointless problem.
>
Not really
>
> Looking at the tiny encryption algorithm aka XXTEA it seemed easy enough
> to implement in Erlang. I have an implementation (attached with source and
> all references inside the module) which encodes and decodes successfully...
> BUT the cipher text doesn't match the test vectors...
>
I had exactly the same problem with tea a few years ago ...
I'd really like to see:
a) an algebraic spec
b) reference implementations in more than one language that I can reproduce
I'm more interested in inter-operability than performance - (think client
in Javascript
backend in C / Erlang) - so compliance with the spec is more important than
performance.
(which is why I like RSA implemented in erlang bignums - no chance of
backdoors in the code)
>
> What makes this pointless is that I should "just make it a NIF" etc. But
> it's likely that I am misunderstanding some aspect of either Erlang or C,
> however I am confounded as to what that problem is... why does the attached
> implementation not generate the same ciphertext as in the test vectors from
> the C implementation? Can anyone spot my error?
>
>
Before you ask this you might ask "can the test vectors be reproduced in
any other
language/implementation than the reference implementation?"
Cheers
/Joe
> Thanks,
> /s
>
>
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://erlang.org/mailman/listinfo/erlang-questions
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20121117/41fae55c/attachment.htm>
More information about the erlang-questions
mailing list