Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- "pragma solidity ^0.4.18;
- contract ctf {
- address public owner;
- // uint public secret;
- uint private flag; //no public, it's a secret;
- /* CONSTRUCTOR */
- function ctf(uint _flag) public {
- owner = msg.sender;
- flag = _flag;
- }
- /* let me change the secret just in case I want to */
- // deployed at https://etherscan.io/address/0xeec8a45a3406c8cf1de7ba0083b1c8dd2e31a27f
- function change_flag(uint newflag, uint key) public {
- require(msg.sender == owner); //make sure it's me
- flag = newflag^key;
- }
- function() payable public {
- return;
- }
- // don't need it anymore
- function kill(address _to) public {
- require(msg.sender == owner);
- selfdestruct(_to);
- }
- }"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement