File tree Expand file tree Collapse file tree 3 files changed +32
-67
lines changed
Expand file tree Collapse file tree 3 files changed +32
-67
lines changed Original file line number Diff line number Diff line change @@ -21,7 +21,7 @@ import {ScrollChain} from "../../src/L1/rollup/ScrollChain.sol";
2121import {ScrollOwner} from "../../src/misc/ScrollOwner.sol " ;
2222import {Whitelist} from "../../src/L2/predeploys/Whitelist.sol " ;
2323
24- import {SystemSignerRegistry } from "../../src/L1/system-contract/SystemSignerRegistry .sol " ;
24+ import {SystemConfig } from "../../src/L1/system-contract/SystemConfig .sol " ;
2525
2626
2727// solhint-disable max-states-count
@@ -282,7 +282,7 @@ contract InitializeL1ScrollOwner is Script {
282282
283283 function configSystemContract () internal {
284284 // If we already have deployed it, just do:
285- SystemSignerRegistry sys = SystemSignerRegistry (SYSTEM_CONTRACT_ADDR);
285+ SystemConfig sys = SystemConfig (SYSTEM_CONTRACT_ADDR);
286286
287287 // sys has a normal constructor that set the "owner" to `ScrollOwner`.
288288 // Now we want to let the Security Council call `addSigner(...)` with no delay.
Original file line number Diff line number Diff line change 1+ // SPDX-License-Identifier: MIT
2+ pragma solidity = 0.8.24 ;
3+
4+ import "@openzeppelin/contracts/access/Ownable.sol " ;
5+
6+ contract SystemConfig is Ownable {
7+
8+ address public currentSigner;
9+
10+ constructor (address _owner ) {
11+ _transferOwnership (_owner);
12+ }
13+
14+ /**
15+ * @dev Update the current signer.
16+ * Only the owner can call this function.
17+ * @param _newSigner The address of the new authorized signer.
18+ */
19+ function updateSigner (address _newSigner ) external onlyOwner {
20+ currentSigner = _newSigner;
21+ }
22+
23+ /**
24+ * @dev Return the current authorized signer.
25+ * @return The authorized signer address.
26+ */
27+ function getSigner () external view returns (address ) {
28+ return currentSigner;
29+ }
30+ }
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments