From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from sog-mx-3.v43.ch3.sourceforge.com ([172.29.43.193] helo=mx.sourceforge.net) by sfs-ml-2.v29.ch3.sourceforge.com with esmtp (Exim 4.76) (envelope-from ) id 1ViFzT-0002dC-IC for bitcoin-development@lists.sourceforge.net; Mon, 18 Nov 2013 03:59:11 +0000 Received-SPF: pass (sog-mx-3.v43.ch3.sourceforge.com: domain of gmail.com designates 209.85.220.50 as permitted sender) client-ip=209.85.220.50; envelope-from=christophe.biocca@gmail.com; helo=mail-pa0-f50.google.com; Received: from mail-pa0-f50.google.com ([209.85.220.50]) by sog-mx-3.v43.ch3.sourceforge.com with esmtps (TLSv1:RC4-SHA:128) (Exim 4.76) id 1ViFzS-0008BL-Gi for bitcoin-development@lists.sourceforge.net; Mon, 18 Nov 2013 03:59:11 +0000 Received: by mail-pa0-f50.google.com with SMTP id kp14so4512811pab.23 for ; Sun, 17 Nov 2013 19:59:04 -0800 (PST) MIME-Version: 1.0 X-Received: by 10.68.13.104 with SMTP id g8mr19072380pbc.33.1384747144692; Sun, 17 Nov 2013 19:59:04 -0800 (PST) Received: by 10.68.146.72 with HTTP; Sun, 17 Nov 2013 19:59:04 -0800 (PST) In-Reply-To: <63B3BF21-C487-4D62-8BB8-18C90F2C3F4C@rbrune.de> References: <63B3BF21-C487-4D62-8BB8-18C90F2C3F4C@rbrune.de> Date: Sun, 17 Nov 2013 22:59:04 -0500 Message-ID: From: Christophe Biocca To: bitcoin-development@lists.sourceforge.net Content-Type: multipart/alternative; boundary=bcaec520ea79a9ced604eb6b9116 X-Spam-Score: -0.6 (/) X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. 0.0 URIBL_BLOCKED ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [URIs: doubleclick.net] -1.5 SPF_CHECK_PASS SPF reports sender host as permitted sender for sender-domain 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (christophe.biocca[at]gmail.com) -0.0 SPF_PASS SPF: sender matches SPF record 1.0 HTML_MESSAGE BODY: HTML included in message -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature X-Headers-End: 1ViFzS-0008BL-Gi Subject: Re: [Bitcoin-development] Bitcoin Network Simulator X-BeenThere: bitcoin-development@lists.sourceforge.net X-Mailman-Version: 2.1.9 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 18 Nov 2013 03:59:11 -0000 --bcaec520ea79a9ced604eb6b9116 Content-Type: text/plain; charset=ISO-8859-1 Beat me to it. My own implementation is here: https://github.com/christophebiocca/bitcoin-network-simulator Same basic principles, but I've been following the protocol message structure as much as possible/Theoretical support for transaction propagation (I really want to see zero-conf stuff, and whether it works). Running a network of 1000 full nodes (with 100 miners) for a week of simulated time (with a normal hashrate) and empty blocks (except for the coinbase transaction) takes about 30-60 seconds. Uses nodejs, with the ultimate goal of having a network/chain visualization running in the browser (with the actual simulation running on a WebWorker to keep things responsive). On Sun, Nov 17, 2013 at 11:43 AM, Rafael Brune wrote: > Over the last days I spent some time working on a simple Bitcoin network > simulator. > It is a stochastic event-based continuous-time simulation of Bitcoin miners > exchanging messages and building block chains. It simulates latency, > bandwidth > and also verification speed but it currently does not simulate > propagation/inclusion > of transactions and instead uses random block sizes. > > The simulator includes two examples, one for a 51% attack and the other is > an > implementation of selfish mining (pretty much 1:1 as described in the > paper). > With the random parameters I picked it seems like it pays off to mine > selfish with > >=30% of the hashing power - but take this with a huge grain of salt as > this > is with a very small network and randomly chosen parameters. And of course > it > is not a perfect replica of the real world network. > > Since this is based on my understanding of the Bitcoin network and > protocol it > would be great if others would take a look and help improve it. > > The project can be found on my github: > https://github.com/rbrune/btcsim > > Regards, > Rafael Brune > > ------------------------------------------------------------------------------ > DreamFactory - Open Source REST & JSON Services for HTML5 & Native Apps > OAuth, Users, Roles, SQL, NoSQL, BLOB Storage and External API Access > Free app hosting. Or install the open source package on any LAMP server. > Sign up and see examples for AngularJS, jQuery, Sencha Touch and Native! > http://pubads.g.doubleclick.net/gampad/clk?id=63469471&iu=/4140/ostg.clktrk > _______________________________________________ > Bitcoin-development mailing list > Bitcoin-development@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/bitcoin-development > --bcaec520ea79a9ced604eb6b9116 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Beat me to it. My own implementation is her= e: https://github.com/christophebiocca/bitcoin-network-simulator
Same basic principles, but I've been following the protocol message str= ucture as much as possible/Theoretical support for transaction propagation = (I really want to see zero-conf stuff, and whether it works).
Running a network of 1000 full nodes (with 100 miners) for a week of simula= ted time (with a normal hashrate) and empty blocks (except for the coinbase= transaction) takes about 30-60 seconds.
Uses nodejs, with the ultimate = goal of having a network/chain visualization running in the browser (with t= he actual simulation running on a WebWorker to keep things responsive).


O= n Sun, Nov 17, 2013 at 11:43 AM, Rafael Brune <mail@rbrune.de> = wrote:
Over the last days I spent some time working= on a simple Bitcoin network simulator.
It is a stochastic event-based continuous-time simulation of Bitcoin miners=
exchanging messages and building block chains. It simulates latency, bandwi= dth
and also verification speed but it currently does not simulate propagation/= inclusion
of transactions and instead uses random block sizes.

The simulator includes two examples, one for a 51% attack and the other is = an
implementation of selfish mining (pretty much 1:1 as described in the paper= ).
With the random parameters I picked it seems like it pays off to mine selfi= sh with
>=3D30% of the hashing power - but take this with a huge grain of salt a= s this
is with a very small network and randomly chosen parameters. And of course = it
is not a perfect replica of the real world network.

Since this is based on my understanding of the Bitcoin network and protocol= it
would be great if others would take a look and help improve it.

The project can be found on my github:
https://gith= ub.com/rbrune/btcsim

Regards,
=A0Rafael Brune
---------------------------------------------------------------------------= ---
DreamFactory - Open Source REST & JSON Services for HTML5 & Native = Apps
OAuth, Users, Roles, SQL, NoSQL, BLOB Storage and External API Access
Free app hosting. Or install the open source package on any LAMP server. Sign up and see examples for AngularJS, jQuery, Sencha Touch and Native! http://pubads.g.doubleclick.net/gam= pad/clk?id=3D63469471&iu=3D/4140/ostg.clktrk
_______________________________________________
Bitcoin-development mailing list
Bitcoin-develo= pment@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bitcoin-de= velopment

--bcaec520ea79a9ced604eb6b9116--