This document describes a binary consensus algorithm for cooperative spectrum sensing in cognitive radio networks. The algorithm uses a fully connected graph model where secondary users cooperatively sense for the presence or absence of a primary user and reach a global decision. Each secondary user makes an initial local binary decision and then iteratively updates its decision by taking the average of its own decision and the decisions received from neighboring nodes. The algorithm is analyzed using a Markov chain representation and the convergence time is related to the second largest eigenvalue of the transition matrix. Simulation results show that the algorithm can accurately detect the presence or absence of a primary user as the number of iterations increases.