In order to get a better understanding I'm trying to write a simple journal tool on the Ethereum blockchain. The goal is to have a journal that for every entry does prove three things:
- The EOA who created the entry
- The timestamp the entry was created
- The entry itself, which is just a string
The code is as simple as this:
contract Journal {
event Log(string entry);
function writeLog(string memory entry) public {
emit Log(entry);
}
}
Are the following assumptions corect?
- is guaranteed because the event is referencing the transaction hash which is referencing the signer
- is guaranteed because the event is referencing the block which has a timestamp
- is guaranteed because the event contains the entry
I basically have two questions:
- Is this a secure and safe way to have a trustworthy journal?
- Is there a better approach to achieve the same goal?