Back to Home

Sweeper

0xf5c9fd63dee7...34ec2d03f1e5
ByzantiumExact Bytecode MatchEdit this contract
Deployed January 11, 2018 (8 years ago)Block 4,891,899

Two-role token sweeper that builds the ERC-20 transfer selector at runtime.

Byzantium EraVerified Source

Historical Significance

Deriving a function selector from a string literal at runtime, rather than letting the compiler compute it, was a common idiom before typed interface calls became routine. It costs gas and code size on every call to save writing an interface.

Key Facts
Deployment Block
4,891,899
Deployment Date
Jan 11, 2018, 06:03 PM
Code Size
558.0 B

Description

A sweeper holding an owner in the first storage slot and an authorized caller in the second. The owner can rotate either role through changeOwner(address) and changeAuthorizedCaller(address). sweep(uint256,address), callable only by the authorized caller, computes the ERC-20 transfer selector at runtime by hashing the string literal "transfer(address,uint256)" and taking its first four bytes, then calls the token to move the balance to the authorized caller. The function naming follows the Bittrex controller lineage. The runtime code matches the deployed bytecode byte for byte; only the trailing swarm metadata hash differs, because the EthereumHistory attribution comment changes the source text. Sourcify records this as a partial match and Etherscan shows it as verified.

Source Verified

SolidityExact bytecode match(558 bytes)
Compiler: v0.4.18

Bytecode Overview

Opcodes558
Unique Opcodes102
Jump Instructions25
Storage Operations10

External Links