Skip to content

digest: implement stream cipher trait for XOF readers #510

Open
@newpavlov

Description

@newpavlov

Probably depends on introduction of a block-level trait for (synchronous) stream ciphers. After that a feature-gated blanket implementation will look somewhat like this:

impl<R: XofReaderCore> XofReader for XofReaderCoreWrapper<R> { .. }
impl<R: StreamCipherCore> StreamCipher for XofReaderCoreWrapper<R> { .. }

It would mean that core XOF reader types would have to implement both XofReaderCore and StreamCipherCore and there will be a bit of code duplication with a wrapper defined in cipher, but it should not be a big problem.

Metadata

Metadata

Assignees

No one assigned

    Labels

    digestHash function crate

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions