Basic implementation of the Bitcoin P2P Wire Protocol. If you use it, expect to blow up the Bitcoin Network.
BitWire relies on a asynchronous PHP-Framework called qcEvents. Make sure
to have it in place if you try to use BitWire. The BitWire_Peer-Class acts
as a consumer on top of qcEvents's Sockets (or any other kind of sources, but
only sockets make sense at the moment):
$eventBase = new \quarxConnect\Events\Base ();
$eventSocket = new \quarxConnect\Events\Socket ($eventBase);
$wirePeer = new \BitBaendiger\BitWire\Peer ();
$eventSocket->connect ('...', 8333, $eventSocket::TYPE_TCP);
$eventSocket->pipeStream ($wirePeer);
$eventBase->loop ();
Incoming messages may be checked by setting
\BitBaendiger\BitWire\Message::$debugMessages to true.
(DEPRECATED)
There is a constant called BITWIRE_DEBUG. When set to true BitWire will
start to output debugging-information related to its work.
Most notably: Whenever Messages/Payloads are received BitWire will try to re-encode these and compare the output with its original input to make sure that BitWire is able to create a bitwise identical representation.
This software is completly on its own. We are not affiliated or related to any bitcoin mining pool or bitcoin exchange. The purpose of this software is to gather statistical data out of the bitcoin network and to use it for personal purposes.
We are NOT affiliated or related in any way to bitwire.co or bitwire.biz. These are completely independant projects and do not have any relation with us.