Bitcoin Forum
May 04, 2024, 10:16:00 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Bitcoin's p2p networking files  (Read 824 times)
clarity510 (OP)
Newbie
*
Offline Offline

Activity: 7
Merit: 0


View Profile
February 04, 2016, 11:12:50 PM
 #1

Hey,

I'm working on an p2p application, and I don't really know how to do it well, so I was thinking I could use bitcoin's p2p code as a learning tool.

Where in the source is all of the p2p stuff? I found bitcoin/src/net.cpp, and that looks like it has a lot of it, but is there more files?

Thanks!
Ryan
Once a transaction has 6 confirmations, it is extremely unlikely that an attacker without at least 50% of the network's computation power would be able to reverse it.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1714860960
Hero Member
*
Offline Offline

Posts: 1714860960

View Profile Personal Message (Offline)

Ignore
1714860960
Reply with quote  #2

1714860960
Report to moderator
1714860960
Hero Member
*
Offline Offline

Posts: 1714860960

View Profile Personal Message (Offline)

Ignore
1714860960
Reply with quote  #2

1714860960
Report to moderator
achow101
Moderator
Legendary
*
expert
Offline Offline

Activity: 3388
Merit: 6581


Just writing some code


View Profile WWW
February 04, 2016, 11:18:55 PM
 #2

Yes. protocol.cpp and protocol.h has stuff there with the p2p messages and main.cpp and main.h has stuff related to receiving and handling network messages.

You should also look at the documentation about the p2p network on bitcoin.org: https://bitcoin.org/en/developer-reference#p2p-network

clarity510 (OP)
Newbie
*
Offline Offline

Activity: 7
Merit: 0


View Profile
February 05, 2016, 03:56:24 PM
 #3

Thanks for the response. This is really helpful.

--Ryan
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!