2025-07-05 14:54:19 -07:00
|
|
|
syntax = "proto3";
|
|
|
|
|
|
2025-07-11 14:46:05 -07:00
|
|
|
package wap.encryption;
|
2025-07-05 14:54:19 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
// TODO: This also encompasses plaintexts, is there a better name?
|
|
|
|
|
// Alternatives: ???
|
|
|
|
|
message EncryptedPayload {
|
|
|
|
|
|
|
|
|
|
oneof encryption {
|
|
|
|
|
encryption.Plaintext plaintext = 1;
|
2025-10-09 18:30:56 -07:00
|
|
|
encryption.Doubleratchet doubleratchet = 2;
|
2025-07-05 14:54:19 -07:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
message Plaintext {
|
|
|
|
|
bytes payload=1;
|
|
|
|
|
}
|
|
|
|
|
|
2025-10-09 18:30:56 -07:00
|
|
|
message Doubleratchet {
|
|
|
|
|
bytes dh = 1; // 32 byte array
|
|
|
|
|
uint32 msgNum = 2;
|
|
|
|
|
uint32 prevChainLen = 3;
|
|
|
|
|
bytes ciphertext = 4;
|
|
|
|
|
string aux = 5;
|
2025-07-05 14:54:19 -07:00
|
|
|
}
|