Skip to content

Incremental hashing / signing  #7

@Gozala

Description

@Gozala

APIs proposed here address the problem of hashing / signing / verifying content that is too large to hold in memory, which is great. Unfortunately it does not address use cases where you need to do those operations incrementally e.g. when large stream of data is transferred over some channel you may want to send checksums along the way.

With the drafted API it would require replaying all the previous bytes. In contrast node's crypto APIs provide you with .copy() method on a hasher so you can continue writing into hasher.

Perhaps something along the same lines could be done here as well, e.g. instead of hashing / signing / verifying readable stream, one could create hasher / signer / verifier instance from readable stream, with a method method digest / sign / verify to compute result for the bytes that had been written so far.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions