Open passcod opened 9 years ago
Its not currently possible, although I believe that constructing a new Salsa20 struct with a different offset would work. I'd certainly be happy to accept a patch to add this functionality - no one has gotten around to doing it quite yet, though.
Seeking is also very useful for parallel processing
I've found that https://peterreid.github.io/chacha/chacha/index.html provides some desirable features:
The wikipedia page states it is possible to "efficiently seek to any position in the output stream in constant time." This SO answer seems to indicate that the eSTREAM code uses an IV which contains both the nonce and the offset. The
Salsa20
struct in rust-crypto has an offset field, but it is not accessible through normal functions (although I suppose one could initialise the struct oneself with a custom offset).Am I missing something or is seeking not directly/easily possible when using this library?