Actually, there's a bug in that implementation:

It should be something like:

sha1=: [: process/ H (,~ |.) _512[\]

And, 'process' should be made into a dyad which takes H as y and the
current block as x.

In other words, the current implementation computes independent sha1
sums for each block, instead of computing a single sum for the
sequence of blocks.

Does anyone feel like registering for rosettacode and fixing the page?
Oh, and testing the code to make sure my thinking isn't broken, again?
(If not, I'll get to it sooner or later.)

Thanks,

-- 
Raul


On Wed, Jun 25, 2014 at 3:20 PM, Raul Miller <[email protected]> wrote:
> http://rosettacode.org/wiki/SHA-1#J seems to qualify as an RIPEMD-160
> hash algorithm.
>
> Thanks,
>
> --
> Raul
>
>
> On Wed, Jun 25, 2014 at 11:54 AM, John Baker <[email protected]> wrote:
>> I am wondering if anyone has invoked RIPEMD-160 hash algorithms from J.
>>
>> There is public C source for this hash
>>
>> http://cpansearch.perl.org/src/CHGEUER/RIPEMD160-0.02/rmd160/doc/ripemd160.html
>>
>> and looking through it is enough to convince me that this is best left in
>> C.  It seems most of the implementations are tailored for 32 bit machines
>> and I need to run this from a 64 bit machine. Any suggestions will be
>> welcome.
>>
>>
>> --
>> John D. Baker
>> [email protected]
>> ----------------------------------------------------------------------
>> For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to