At the moment a temporal file is written (and deleted) at each encryption/decryption operation.
Because we know the HMAC after encryption, the InformationContainer can only be serialized at this moment. This ensures that this poor design has been implemented for the first prototype.
----------
File Signature
---------
Length of Serialized ProtoBuf
---------
Serialized ProtoBuf (see InformationContainer)
- among other things the HMAC
---------
Encrypted Data
---------
[ProtoContract]
internal class InformationContainer : ProtoBase<InformationContainer>
{
[ProtoMember(1)]
public PublicInformation PublicInformation { get; set; }
[ProtoMember(2)]
public PasswordDerivationSettings DerivationSettings { get; set; }
[ProtoMember(3)]
public byte[] SecretInformationData { get; set; }
[ProtoMember(4)]
public EllipticCurveEncryptionInformation EllipticCurveEncryptionInformation { get; set; }
}
----------
File Signature
---------
Length of Serialized ProtoBuf
---------
Serialized ProtoBuf (see InformationContainer)
---------
HMAC
---------
Encrypted Data
---------