  Bitcoin is a popular cryptocurrency that records alltransactions in a
distributed append-only public ledger calledblockchain. The security of Bitcoin
heavily relies on the incentive-compatible proof-of-work (PoW) based
distributed consensus pro-tocol, which is run by network nodes called miners.
In exchangefor the incentive, the miners are expected to honestly maintainthe
blockchain. Since its launch in 2009, Bitcoin economy hasgrown at an enormous
rate, and it is now worth about 170 billions of dollars. This exponential
growth in the market valueof Bitcoin motivates adversaries to exploit
weaknesses for profit,and researchers to discover new vulnerabilities in the
system,propose countermeasures, and predict upcoming trends.In this paper, we
present a systematic survey that covers thesecurity and privacy aspects of
Bitcoin. We start by presenting anoverview of the Bitcoin protocol and its
major components alongwith their functionality and interactions within the
system. Wereview the existing vulnerabilities in Bitcoin and its
underlyingmajor technologies such as blockchain and PoW based
consensusprotocol. These vulnerabilities lead to the execution of
varioussecurity threats to the normal functionality of Bitcoin. Wethen discuss
the feasibility and robustness of the state-of-the-art security solutions.
Additionally, we present current privacyand anonymity considerations in Bitcoin
and discuss the privacy-related threats to Bitcoin users along with the
analysis of theexisting privacy-preserving solutions. Finally, we summarize
thecritical open challenges and suggest directions for future researchtowards
provisioning stringent security and privacy techniquesfor Bitcoin.
