-
Notifications
You must be signed in to change notification settings - Fork 270
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(Keys_Incoming): Decrypt incoming ciphertext #5868
Comments
Related information in #5901 (comment). |
This should be addressed along with #5901 to not have too many conflicts. The There should be a constructor(eph_public_key: Fr, header: EncryptedLogHeader, body: EncryptedLogBody) {}
static fromEncryptedBuffer(data: Buffer, incomingViewingSecretKey: GrumpkinPrivateKey): L1NotePayload | undefined {
const reader = BufferReader.asReader(data);
const ephPK = Fr.fromBuffer(reader);
const header = EncryptedLogHeader.fromCiphertext(data, incomingViewingSecretKey, ephPK);
const appSecretKey = Fr.random();
// slice data
const body = EncryptedLogBody.fromCiphertext(data, appSecretKey, ephPK);
return new L1NotePayload(ephPK, header, body);
} Similar changes should happen in the note processor to get this going. Places to look:
|
Implementation in
typescript
Following #5867 and #5899 we need to also be able to decode. This don't need to happen in a circuit so we simply do it in typescript. This should be able to take a look back at aztec-connect to see if it can get some information from there as it was also using AES.
Take into account #5901.
In aztec connect the ciphertext was called the
viewing_key
so should be helpful for finding the information.Very close to #5902
The text was updated successfully, but these errors were encountered: