Ethernaut Part 2 – Fallout and CoinFlip

(This is a continuation of http://www.carlellis.co.uk/2018/10/31/ethernaut-part-1/) Level 2 – Fallout All you are given is a contract, and a hint about the Remix IDE. I didn’t end up using Remix for this level, but the contract is as follows: pragma solidity ^0.4.18; import ‘zeppelin-solidity/contracts/ownership/Ownable.sol’; contract Fallout is Ownable {   mapping (address => uint) allocations;   /* constructor */   function Fal1out() public payable {     owner = msg.sender;     allocations[owner] = msg.value;   }   function allocate() public payable {     allocations[msg.sender] += msg.value;   }   function sendAllocation(address allocator) public {     require(allocations[allocator] > 0);     allocator.transfer(allocations[allocator]);   }   function collectAllocations() public onlyOwner { […]

Ethernaut – Part 1

I recently came across Ethernaut, a game about finding issues with Ethereum smart contracts and breaking them. I do enjoy a capture the flag and I know practically nothing about smart contracts, so it seems like a fun thing to attempt to chip away at. I’ve currently managed to do the first two challenges, the […]