Bitcoin implementation in Scala