valence icon indicating copy to clipboard operation
valence copied to clipboard

Update `aes` and `cfb8` dependencies

Open rj00a opened this issue 2 years ago • 3 comments

aes and cfb8 crates are at 0.8 currently but they are 0.7 in Valence. I tried updating a while back but couldn't figure out how to use the new API (It's very different).

Not much urgency on this one.

rj00a avatar Sep 09 '22 06:09 rj00a

It turns out there are some breaking changes here. I'll throw up a draft PR of what I have so far: #44

dyc3 avatar Sep 09 '22 20:09 dyc3

I think the best way to upgrade this is to create a couple of new types that implement AsyncRead and AsyncWrite that can encrypt and decrypt blocks on demand. That way, we can use decrypt_block_mut() which doesn't consume the cipher. I'm not familiar enough with async rust to be able to do this myself.

In other words, we need our own BufReader/Writer that maintains the state of of the cipher and implements AsyncRead/Write, and outputs a decrypted/encrypted stream, respectively.

dyc3 avatar Sep 10 '22 21:09 dyc3

Neither am I.

rj00a avatar Sep 12 '22 05:09 rj00a