News for hackers. Stuff that matters.

Show HN: Live Bitcoin Transactions from around the globe in WebGL

http://www.earthbit.net

I built this over the weekend. Any feedback is appreciated. Please note you will need a WebGL enabled browser. Thank you for checking it out.

--UPDATE-- HN Traffic is strangling earthbit. There is sporadic downtime due to the web services I am using, if no transactions appear after a few seconds, then please try again in an hour.

( 35 comments | 34 points | on HN )
Re:Show HN: Live Bitcoin Transactions from around the globe ... by Terk on Tuesday November 26, 2013 @08:11AM (#6800919)
There's no way to geolocate bitcoin transactions. Blockchain itself doesn't store IP addressees. Well-connected nodes like blockchain.info can only detect the IP address of a node that was first to relay a transaction to their (blockchain.info's) node. That might be IP of the original sender, but most likely it's not. Most of the time it's either another well-connected node or some online wallet.

Explaination: http://millybitcoin.com/is-ip-address-associated-with-transa...

Re:Show HN: Live Bitcoin Transactions from around the globe ... by ionwake on Tuesday November 26, 2013 @08:15AM (#6800942)
It is an approximation. The IP addresses are taken from the nearest relays of each of the transactions. See : https://blockchain.info/unconfirmed-transactions.
Re:Show HN: Live Bitcoin Transactions from around the globe ... by Terk on Tuesday November 26, 2013 @08:57AM (#6801198)
This is a P2P network. “Nearest” relay has nothing to do with geographic neighborhood.

I made IP whois stats of nodes I am currently connected to and they are: 8x USA (3x NY, 2x Texas, 1x California, 1x Virginia, 1x Georgia), 2x France, 2x China, 2x Russia, 2x Poland, 2x Switzerland, 1x Czech Republic, 1x Germany, 1x Portugal, 1x Sweden, 1x New Zealand, 1x Netherlands.

My transaction will be relayed to these nodes and then one of them will be first to relay it further to blockchain.info - and it's the IP of this lucky relay node what you'll show. Which one will be the first depends most likely on [temporary speed of connection between me and relay nodes + processing speed of relay nodes + temporary speed of connection between relay nodes and blockchain.info nodes] and such combination will make it semi-random. You will detect my transaction as being located in NYC or in Beijing or in Paris or wherever, but it has totally nothing to do with my actual location and calling it approximation is a misunderstanding.

Or I'll use online wallet in which case it will be even less related to my geographic location (it will be semi-random based of nodes connected to my online wallet's server).

What you show is a nice visualization, but it's rather a map of the best-connected nodes and it has nothing to do with geographic location of senders of bitcoin transactions.

Re:Show HN: Live Bitcoin Transactions from around the globe ... by ionwake on Tuesday November 26, 2013 @09:12AM (#6801283)
Thank you for your feedback but it is my understanding that the nearest nodes will generally be the ones with the least latency Hence the clients node choice is not "semi-random" - and thus quite a good indicator of the area in which the transaction took place. However , as the nearest node is used, the zoom level is capped, as is the resolution of the map. The visual is meant to be a relatively "general indicator".

You are right about online wallets. If you use your blockchain wallet, I do believe the IP of the relay will register as 127.0.0.1, and for this reason I have them omitted from the presentation.

EDIT - everything is going down. I also just uploaded an incorrect older version which is sending GETs with 127.... sigh give it a few days. Ignore my last paragraph Thanks again for your feedback and explanation regarding nodes.

Re:Show HN: Live Bitcoin Transactions from around the globe ... by Terk on Tuesday November 26, 2013 @09:43AM (#6801516)
> Thank you for your feedback but it is my understanding that the nearest nodes will generally be the ones with the least latency

The latency you mention is actually [my latency to relay node] + [relay node latency to blockchain.info]. I have 20 ms to node A and it has 100 ms to blockchain.info for a total latency of 120 ms. I have 100 ms to node B and it has 10 ms to blockchain.info for a total latency of 110 ms. Node B will most likely relay my transaction to blockchain.info before node A, even if it's five times “farther” from me (100 ms) than node A (20 ms). The combination of latencies makes the relaying IP reported by blockchain.info semi-random.

I don't mean to bring you down or criticize. This is a really cool visualization! It simply visualizes different thing that most people think it does.

Re:Show HN: Live Bitcoin Transactions from around the globe ... by spenvo on Tuesday November 26, 2013 @07:39AM (#6800751)
A curious thing just happened. I enabled WebGL in Safari and visited the site, after which I saw this -> (screenshot): http://imgur.com/yY1vEC8

What you're seeing there (behind the globe) is pieces of my desktop, code in a text editor, even snippets of another tab open in safari! How is this even remotely secure? Would this be possible in other implementations of WebGL or just Safari's implementation? I understand that it allows for greater access to your computer's resources, but either way, after this user-experience I'm far less inclined to include it in future projects.

Original comment: Cool idea, although I kept waiting for additional/contextual info to load on the globe [a geographic or node-based map; weighted lines between points (or, wait, that doesn't make sense); a click-to-learn-more on the transactions themselves, etc.], just something to delve-into that would make it one-iota more interesting. Either way it's a soothing visualization.

Are the sounds' frequencies tied to the size of the transactions? If so, that's a great idea -- random-but-informative background noise! Kudos - keep refining it! (A bunch of 'texture unit not renderable' messages in console. Tried in Chrome Canary 33.0.1720.0 for Mac version 10.9.)

Tried your other link http://www.craftfortress.com/earthbit/index2.html and the textures loaded no problem (I see the map of countries projected on the globe) -- but transactions aren't loading in now.

Re:Show HN: Live Bitcoin Transactions from around the globe ... by ionwake on Tuesday November 26, 2013 @08:08AM (#6800907)
I have never had someone be able to load textures but not get transactions .... perhaps if you had lots of windows open - your IP got temporarily banned from the geolocation web service? If this is the case it should start working after an hour timeout.

Sound, Color and Size of the column depend on the transaction size.

I will be adding further information such as wallet address and other variables in the future. Thanks for your feedback = )

Re:Show HN: Live Bitcoin Transactions from around the globe ... by ionwake on Tuesday November 26, 2013 @09:26AM (#6801373)
--Regarding your screenshot--

That is awesome! I do believe that is a video driver malfunction and it doesn't pose a security risk

Re:Show HN: Live Bitcoin Transactions from around the globe ... by joezydeco on Tuesday November 26, 2013 @10:30AM (#6801853)
Yeah I'd submit that to /r/glitch_art
Re:Show HN: Live Bitcoin Transactions from around the globe ... by spenvo on Tuesday November 26, 2013 @11:33AM (#6802321)
I have, and they love it! :)
Re:Show HN: Live Bitcoin Transactions from around the globe ... by joezydeco on Tuesday November 26, 2013 @12:24PM (#6802690)
Hah! Awesome!
Re:Show HN: Live Bitcoin Transactions from around the globe ... by chromaton on Tuesday November 26, 2013 @10:54AM (#6802010)
It has a sort of Max Headroom feel to it.
Re:Show HN: Live Bitcoin Transactions from around the globe ... by mrspeaker on Tuesday November 26, 2013 @12:13PM (#6802613)
I was seeing this a lot in Chrome Canary on mac when doing a bunch of Canvas and WebGL games. The scary thing is you can see your emails and other sensitive information in some of the glitches - damn memory, always memorising stuff!
Re:Show HN: Live Bitcoin Transactions from around the globe ... by modeless on Tuesday November 26, 2013 @12:05PM (#6802563)
That is a Safari bug, not a feature of WebGL. Apple has lagged in implementing WebGL (which is sad, they invented the canvas tag after all). Their implementation is disabled by default due to bugs like this.
Re:Show HN: Live Bitcoin Transactions from around the globe ... by lectrick on Tuesday November 26, 2013 @08:13AM (#6800937)
Latest Chrome on Windows here.

I see the globe and hear the music but I don't see transactions.

I'd recommend disabling the music load for now while HN hits it. It will save on some unnecessary traffic. You can always re-enable it again in a few days.

Re:Show HN: Live Bitcoin Transactions from around the globe ... by ionwake on Tuesday November 26, 2013 @08:26AM (#6800994)
Ok the server got flooded with requests and came down - I am just reuploading a version which uses a different web service.

The PROXY I use for the JSONP request got taken down by the traffic - can anyone offer a suitable replacement JSONP proxy URL for me ot use? Help would be greatly appreciated!

Re:Show HN: Live Bitcoin Transactions from around the globe ... by wereHamster on Tuesday November 26, 2013 @07:36AM (#6800733)
Textures don't show up on the globe, warnings in the developer console: https://gist.github.com/wereHamster/58eb96d184dffd096e3f.
Re:Show HN: Live Bitcoin Transactions from around the globe ... by kristaps on Tuesday November 26, 2013 @07:51AM (#6800815)
At least the autoplay background music works.
Re:Show HN: Live Bitcoin Transactions from around the globe ... by karanbhangui on Tuesday November 26, 2013 @07:38AM (#6800740)
seems to be broken in chrome on osx, works in safari 7 with webgl enabled.
Re:Show HN: Live Bitcoin Transactions from around the globe ... by ionwake on Tuesday November 26, 2013 @07:54AM (#6800832)
Problems in Firefox? Try:

URL > about:config , search for WebGL, make sure webgl_enabled parameter is set to "True".

Still now working? Try this link: http://www.craftfortress.com/earthbit/index2.html

Re:Show HN: Live Bitcoin Transactions from around the globe ... by mwilcox on Tuesday November 26, 2013 @08:02AM (#6800878)
I was getting the same issue, just a black globe with no activity. Your second version here loads the textures but I'm still not seeing any activity. Chrome 33 dev on W8.

Edit: just refreshed, it's working now. Awesome project!

Re:Show HN: Live Bitcoin Transactions from around the globe ... by m12k on Tuesday November 26, 2013 @07:58AM (#6800861)
There's a surprisingly large number of bitcoin transactions coming from the Australian outback, around the area of the Gibbon Desert and Great Sandy Desert. I'm pretty sure that's a very, very sparsely populated area, so either there's something wrong with the data, or there's some equipment out there which is somehow getting geolocated. A secret bitcoin mining operation in the desert?
Re:Show HN: Live Bitcoin Transactions from around the globe ... by knowaveragejoe on Tuesday November 26, 2013 @11:20AM (#6802221)
Is there any definitive way to tell if a transaction is someone exchanging USD <-> bitcoin on an exchange versus actual trade? I remain unconvinced that actual trade with bitcoin is growing at an appreciable rate with the current volatility and deflation.
Re:Show HN: Live Bitcoin Transactions from around the globe ... by ionwake on Tuesday November 26, 2013 @11:56AM (#6802479)
You want to know which transactions occur that involve merchants? (leaving out exchanges?)
Re:Show HN: Live Bitcoin Transactions from around the globe ... by knowaveragejoe on Friday November 29, 2013 @12:24PM (#6820201)
Late, but yes. AFAIK there's no way to distinguish such a thing unless the exchanges use the same wallets for escrow.
Re:Show HN: Live Bitcoin Transactions from around the globe ... by qt_scientist on Tuesday November 26, 2013 @08:21AM (#6800967)
Default url doesn't function properly here as well, but I did find a cat. Can you find it too?

craftfortress link works fine

Re:Show HN: Live Bitcoin Transactions from around the globe ... by ionwake on Tuesday November 26, 2013 @07:18AM (#6800655)
I just finished building this "weekend project" yesterday. Please let me know what you think.

Thank you

Re:Show HN: Live Bitcoin Transactions from around the globe ... by fuj on Tuesday November 26, 2013 @08:12AM (#6800929)
There is a problem with the Access-Control-Allow-Origin
Re:Show HN: Live Bitcoin Transactions from around the globe ... by ionwake on Tuesday November 26, 2013 @08:51AM (#6801155)
Yep - my CORS proxy went down - I need another! :(
Re:Show HN: Live Bitcoin Transactions from around the globe ... by simondlr on Tuesday November 26, 2013 @07:38AM (#6800741)
This is beautiful. Earth is just black though. Not seeing any countries. Is this intentional?
Re:Show HN: Live Bitcoin Transactions from around the globe ... by ionwake on Tuesday November 26, 2013 @07:54AM (#6800837)
Please try the fix I just posted above - thank you.
Re:Show HN: Live Bitcoin Transactions from around the globe ... by simondlr on Tuesday November 26, 2013 @09:55AM (#6801606)
Thanks. Link 2 works. What's the legend? What's the difference between green, black and blue stripes?
Re:Show HN: Live Bitcoin Transactions from around the globe ... by eterm on Tuesday November 26, 2013 @07:55AM (#6800840)
In firefox I'm getting a globe with the map showing but no transactions displayed.
Re:Show HN: Live Bitcoin Transactions from around the globe ... by ionwake on Tuesday November 26, 2013 @07:58AM (#6800858)
The transactions should kick in after about 10 seconds
Re:Show HN: Live Bitcoin Transactions from around the globe ... by impostervt on Tuesday November 26, 2013 @12:17PM (#6802640)
Any chance of sharing the source code?