Skip to content
This repository has been archived by the owner on Mar 25, 2024. It is now read-only.

Add security contact #99

Open
wants to merge 1 commit into
base: sb-short-term-fee-model
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions contracts/interfaces/IComplexUpgrader.sol
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@

pragma solidity 0.8.20;

/**
* @author Matter Labs
* @custom:security-contact security@matterlabs.dev
* @notice The interface for the ComplexUpgrader contract.
*/
interface IComplexUpgrader {
function upgrade(address _delegateTo, bytes calldata _calldata) external payable;
}
6 changes: 6 additions & 0 deletions contracts/interfaces/ICompressor.sol
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@ uint8 constant LENGTH_BITS_OFFSET = 3;
// The maximal length in bytes that an enumeration index can have.
uint8 constant MAX_ENUMERATION_INDEX_SIZE = 8;

/**
* @author Matter Labs
* @custom:security-contact security@matterlabs.dev
* @notice The interface for the Compressor contract, responsible for verifying the correctness of
* the compression of the state diffs and bytecodes.
*/
interface ICompressor {
function publishCompressedBytecode(
bytes calldata _bytecode,
Expand Down
6 changes: 6 additions & 0 deletions contracts/interfaces/IKnownCodesStorage.sol
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@

pragma solidity 0.8.20;

/**
* @author Matter Labs
* @custom:security-contact security@matterlabs.dev
* @notice The interface for the KnownCodesStorage contract, which is responsible
* for storing the hashes of the bytecodes that have been published to the network.
*/
interface IKnownCodesStorage {
event MarkedAsKnown(bytes32 indexed bytecodeHash, bool indexed sendBytecodeToL1);

Expand Down
5 changes: 5 additions & 0 deletions contracts/interfaces/IL1Messenger.sol
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,11 @@ bytes32 constant L2_L1_LOGS_TREE_DEFAULT_LEAF_HASH = 0x72abee45b59e344af8a6e5202
/// @dev The current version of state diff compression being used.
uint256 constant STATE_DIFF_COMPRESSION_VERSION_NUMBER = 1;

/**
* @author Matter Labs
* @custom:security-contact security@matterlabs.dev
* @notice The interface of the L1 Messenger contract, responsible for sending messages to L1.
*/
interface IL1Messenger {
// Possibly in the future we will be able to track the messages sent to L1 with
// some hooks in the VM. For now, it is much easier to track them with L2 events.
Expand Down
1 change: 1 addition & 0 deletions contracts/interfaces/ISystemContext.sol
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ pragma solidity 0.8.20;

/**
* @author Matter Labs
* @custom:security-contact security@matterlabs.dev
* @notice Contract that stores some of the context variables, that may be either
* block-scoped, tx-scoped or system-wide.
*/
Expand Down
1 change: 1 addition & 0 deletions contracts/interfaces/ISystemContextDeprecated.sol
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ pragma solidity 0.8.20;

/**
* @author Matter Labs
* @custom:security-contact security@matterlabs.dev
* @notice The interface with deprecated functions of the SystemContext contract. It is aimed for backward compatibility.
*/
interface ISystemContextDeprecated {
Expand Down
15 changes: 11 additions & 4 deletions contracts/interfaces/ISystemContract.sol
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,17 @@ pragma solidity 0.8.20;
import {SystemContractHelper} from "../libraries/SystemContractHelper.sol";
import {BOOTLOADER_FORMAL_ADDRESS} from "../Constants.sol";

/// @dev Solidity does not allow exporting modifiers via libraries, so
/// the only way to do reuse modifiers is to have a base contract
/// @dev Never add storage variables into this contract as some
/// system contracts rely on this abstract contract as on interface!


/**
* @author Matter Labs
* @custom:security-contact security@matterlabs.dev
* @notice An abstract contract that is used to reuse modifiers across the system contracts.
* @dev Solidity does not allow exporting modifiers via libraries, so
* the only way to do reuse modifiers is to have a base contract
* @dev Never add storage variables into this contract as some
* system contracts rely on this abstract contract as on interface!
*/
abstract contract ISystemContract {
/// @notice Modifier that makes sure that the method
/// can only be called via a system call.
Expand Down
Loading