The IoT is changing the way we interact with the world. Very soon, almost all of our daily tasks will be made through self intelligent systems embedded in devices scattered all around us. Their mission is to turn our cities, transportation systems, buildings, homes, and bodies in smart environments. These environments will bring us more comfort, improve our performance, increase our profits, and take away time-consuming tasks. However, besides its great benefits, the IoT is also a big source of concerns, mainly because a good part of its devices will handle private and confidential information. Recently, cases of successful IoT invasions only worsen this scenario and show us that the today's adopted access control systems need to be replaced by more efficiently and secure ones. To overcome these access control problems, in this work, we present the ControlChain. The ControlChain is an access control authorization architecture that is heavily based on Blockchain technology. We also demonstrate the viability of the ControlChain through the E-ControlChain, a proof-of-concept developed to run over the Ethereum network.Our proposals follows the IoT tendency requirements and are user-transparent, user-friendly, fully decentralized, scalable, fault tolerant, and compatible with a wide range of today's access control models already used in the IoT. Finally, we also make a cost and a performance analysis of E-ControlChain, using a Raspberry Pi as an IoT device.