Boost logo

Boost :

From: Ames Andreas (Andreas.Ames_at_[hidden])
Date: 2007-03-23 06:33:57

> -----Original Message-----
> From: boost-bounces_at_[hidden]
> [mailto:boost-bounces_at_[hidden]] On Behalf Of Sergey
> Sent: Thursday, March 22, 2007 11:10 PM
> To: boost_at_[hidden]
> Subject: [boost] Cryptographic library for Boost
> template<class iIt, class oIt>
> oIt process(iIt begin, iIt end, oIt out);
> Criticism is welcomed :)

No criticism, just a thought/suggestion:

As it stands, 'process' is linear. OTOH, there are 'restartable' or incremental (I don't know the right terminology) hash functions, see, esp. Update(5). From a 10.000 meters perspective it takes just one portion of the whole input at once, computes a hash for that portion and holds or, preferably, returns a state, that needs to be used for the next iteration. Supporting such use cases might possibly be more general than the proposed linear approach. The linear approach could possibly be just a layer above an iterative interface, which might be much more appropriate for asynchronously received data (be it files or via sockets).

If an iterative interface is implemented, it might be nice to be able to run different iterations in different threads.



Andreas Ames | Programmer | Comergo GmbH | ames AT avaya DOT com
Sitz der Gesellschaft: Stuttgart
Registergericht: Amtsgericht Stuttgart - HRB 22107
Geschäftsführer: Andreas von Meyer zu Knonow, Udo Bühler, Thomas Kreikemeier

Boost list run by bdawes at, gregod at, cpdaniel at, john at