Install foundry.
Run forge test -vvv
The system contracts of Shutterized Optimism
Install foundry.
Run forge test -vvv
Whenever a keyper set is finalized and added to the KeyperSetManager listening clients want to use the information of the keyper set (member addresses, threshold, activation block number) to schedule the activation of a new keyper set and use a different eon public key.
Currently the event only emits information that links to the keyper-set contract.
However upon receiving this event, clients have to read multiple fields of that contract in order to acquire the needed information. This results in multiple eth_call
JSON-RPC calls before all information has been gathered.
shop-contracts/src/KeyperSetManager.sol
Lines 21 to 22 in bca6efd
shop-contracts/src/KeyperSet.sol
Lines 8 to 12 in bca6efd
@fredo Is it possible and would it make sense to add the following information from the KeyperSet and the KeyperSetManager contract?
The sequencer system address which is able to pause shutter is predefined by the shutter code base.
We can pass this address in the constructor to automatically set the pauser and sequencer role.
The inbox contract will receive encrypted transactions by the users. From this place the reveal tx type will pick up txs encrypted for the current block, decrypt and execute them and clear the storage.
The contract has the following interface
interface IInbox {
function submitEncryptedTransaction(
uint64 eon,
uint64 blockNumber,
bytes memory encryptedTransaction,
uint256 gasLimit
) external payable;
// PSEUDO
function getTransactions(uint64 blockNumber) external view;
function clear() external;
function withdraw() external;
When scheduling a new keyper set, the only condition for the activation slot is to be greater or equal than the latest keyper set.
However, this allows activation slots to be in the past.
From a logical perspective this doesn't make sense, cause we are scheduling a keyper set for blocks which are already finalized. Furthermore, the state of the contracts and the chain will look weird, cause the contract state which set should have been used and the actual eon key used for a given block might differ.
In order to unwind this, one would have to know when the latest keyper set was scheduled and that it was scheduled to past blocks.
I don't see that the liveness would be attacked in this scenario, but I also really don't see a benefit of allowing such a behavior. Effectively, what would happen is, that the keyper set would be active from the next block on (because past blocks are already created), which would be the same if we would just schedule it for the next block.
The default AdminRole should be set by the constructor. Affected contracts are Inbox and KeyperSetManager
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.