Don’t “Go Freaking Do It“ - Smart Contract Analysis

Jesper
Jesper
Dec 4, 2017 · 3 min read

Intro

What is “Go Freaking Do It”

Low Severity Problems Found

function setGoal() {
(...snip for brevity...)
bytes32 hash = keccak256(msg.sender, _description, msg.value, _deadline); Goal memory goal = Goal(...snip for brevity...); goals[hash] = goal; (...snip for brevity...)
}
Goal[] public activeGoals;

High Severity Problems Found

function setGoalFailed(uint _index, bytes32 _hash) {
assert(goals[_hash].amount > 0);
// assert(goals[_hash].emailSent == true);
goals[_hash].completed = false;
activeGoals[_index].completed = false;
owner.transfer(goals[_hash].amount); // send ether to contract owner setGoalFailedEvent(_hash, false);
}

Who we are

Notes

Update

HackerNoon.com

how hackers start their afternoons.

Jesper

Written by

Jesper

Founder, Monkey Test It (https://monkeytest.it). Free automated website testing for everyone.

HackerNoon.com

how hackers start their afternoons.