aboutsummaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
Diffstat (limited to 'contrib')
-rw-r--r--contrib/README.md3
-rw-r--r--contrib/bitcoin-qt.pro2
-rw-r--r--contrib/bitcoind.bash-completion2
-rw-r--r--contrib/bitrpc/README.md8
-rw-r--r--contrib/bitrpc/bitrpc.py335
-rw-r--r--contrib/debian/bitcoin-tx.install1
-rw-r--r--contrib/debian/changelog36
-rw-r--r--contrib/debian/control21
-rw-r--r--contrib/debian/copyright139
-rw-r--r--contrib/debian/examples/bitcoin.conf15
-rw-r--r--contrib/debian/manpages/bitcoin-cli.13
-rw-r--r--contrib/debian/manpages/bitcoin-qt.112
-rw-r--r--contrib/debian/manpages/bitcoin.conf.510
-rw-r--r--contrib/debian/manpages/bitcoind.114
-rw-r--r--contrib/devtools/README.md26
-rwxr-xr-xcontrib/devtools/clang-format.py62
-rwxr-xr-xcontrib/devtools/github-merge.sh6
-rwxr-xr-xcontrib/devtools/optimize-pngs.py16
-rwxr-xr-xcontrib/devtools/security-check.py181
-rwxr-xr-xcontrib/devtools/symbol-check.py30
-rwxr-xr-xcontrib/devtools/test-security-check.py60
-rw-r--r--contrib/gitian-descriptors/gitian-linux.yml2
-rw-r--r--contrib/gitian-descriptors/gitian-osx.yml2
-rw-r--r--contrib/gitian-descriptors/gitian-win.yml2
-rw-r--r--contrib/gitian-downloader/bluematt-key.pgpbin4113 -> 10324 bytes
-rw-r--r--contrib/gitian-downloader/btcdrak-key.pgp142
-rw-r--r--contrib/gitian-downloader/prab-key.pgp102
-rw-r--r--contrib/init/README.md1
-rw-r--r--contrib/init/org.bitcoin.bitcoind.plist15
-rw-r--r--contrib/verify-commits/trusted-git-root2
-rwxr-xr-xcontrib/zmq/zmq_sub.py37
31 files changed, 752 insertions, 535 deletions
diff --git a/contrib/README.md b/contrib/README.md
index 7d4b91e887..125594312b 100644
--- a/contrib/README.md
+++ b/contrib/README.md
@@ -1,9 +1,6 @@
Wallet Tools
---------------------
-### [BitRPC](/contrib/bitrpc) ###
-Allows for sending of all standard Bitcoin commands via RPC rather than as command line args.
-
### [SpendFrom](/contrib/spendfrom) ###
Use the raw transactions API to send coins received on a particular
diff --git a/contrib/bitcoin-qt.pro b/contrib/bitcoin-qt.pro
index 3a72d10f47..b8133bf789 100644
--- a/contrib/bitcoin-qt.pro
+++ b/contrib/bitcoin-qt.pro
@@ -11,7 +11,7 @@ FORMS += \
../src/qt/forms/overviewpage.ui \
../src/qt/forms/receivecoinsdialog.ui \
../src/qt/forms/receiverequestdialog.ui \
- ../src/qt/forms/rpcconsole.ui \
+ ../src/qt/forms/debugwindow.ui \
../src/qt/forms/sendcoinsdialog.ui \
../src/qt/forms/sendcoinsentry.ui \
../src/qt/forms/signverifymessagedialog.ui \
diff --git a/contrib/bitcoind.bash-completion b/contrib/bitcoind.bash-completion
index 3cc959c0a6..1338d2f2b5 100644
--- a/contrib/bitcoind.bash-completion
+++ b/contrib/bitcoind.bash-completion
@@ -96,7 +96,7 @@ _bitcoind() {
esac
case "$cur" in
- -conf=*|-pid=*|-loadblock=*|-wallet=*|-rpcsslcertificatechainfile=*|-rpcsslprivatekeyfile=*)
+ -conf=*|-pid=*|-loadblock=*|-wallet=*)
cur="${cur#*=}"
_filedir
return 0
diff --git a/contrib/bitrpc/README.md b/contrib/bitrpc/README.md
deleted file mode 100644
index f5ef2f0405..0000000000
--- a/contrib/bitrpc/README.md
+++ /dev/null
@@ -1,8 +0,0 @@
-### BitRPC
-Allows for sending of all standard Bitcoin commands via RPC rather than as command line args.
-
-### Looking for Wallet Tools?
-BitRPC.py is able to do the exact same thing as `walletchangepass.py` and `walletunlock.py`. Their respective commands in BitRPC.py are:
-
- bitrpc.py walletpassphrasechange
- bitrpc.py walletpassphrase \ No newline at end of file
diff --git a/contrib/bitrpc/bitrpc.py b/contrib/bitrpc/bitrpc.py
deleted file mode 100644
index c3ce9d7936..0000000000
--- a/contrib/bitrpc/bitrpc.py
+++ /dev/null
@@ -1,335 +0,0 @@
-from jsonrpc import ServiceProxy
-import sys
-import string
-import getpass
-
-# ===== BEGIN USER SETTINGS =====
-# if you do not set these you will be prompted for a password for every command
-rpcuser = ""
-rpcpass = ""
-# ====== END USER SETTINGS ======
-
-
-if rpcpass == "":
- access = ServiceProxy("http://127.0.0.1:8332")
-else:
- access = ServiceProxy("http://"+rpcuser+":"+rpcpass+"@127.0.0.1:8332")
-cmd = sys.argv[1].lower()
-
-if cmd == "backupwallet":
- try:
- path = raw_input("Enter destination path/filename: ")
- print access.backupwallet(path)
- except Exception as inst:
- print inst
-
-elif cmd == "encryptwallet":
- try:
- pwd = getpass.getpass(prompt="Enter passphrase: ")
- pwd2 = getpass.getpass(prompt="Repeat passphrase: ")
- if pwd == pwd2:
- access.encryptwallet(pwd)
- print "\n---Wallet encrypted. Server stopping, restart to run with encrypted wallet---\n"
- else:
- print "\n---Passphrases do not match---\n"
- except Exception as inst:
- print inst
-
-elif cmd == "getaccount":
- try:
- addr = raw_input("Enter a Bitcoin address: ")
- print access.getaccount(addr)
- except Exception as inst:
- print inst
-
-elif cmd == "getaccountaddress":
- try:
- acct = raw_input("Enter an account name: ")
- print access.getaccountaddress(acct)
- except Exception as inst:
- print inst
-
-elif cmd == "getaddressesbyaccount":
- try:
- acct = raw_input("Enter an account name: ")
- print access.getaddressesbyaccount(acct)
- except Exception as inst:
- print inst
-
-elif cmd == "getbalance":
- try:
- acct = raw_input("Enter an account (optional): ")
- mc = raw_input("Minimum confirmations (optional): ")
- try:
- print access.getbalance(acct, mc)
- except:
- print access.getbalance()
- except Exception as inst:
- print inst
-
-elif cmd == "getblockbycount":
- try:
- height = raw_input("Height: ")
- print access.getblockbycount(height)
- except Exception as inst:
- print inst
-
-elif cmd == "getblockcount":
- try:
- print access.getblockcount()
- except Exception as inst:
- print inst
-
-elif cmd == "getblocknumber":
- try:
- print access.getblocknumber()
- except Exception as inst:
- print inst
-
-elif cmd == "getconnectioncount":
- try:
- print access.getconnectioncount()
- except Exception as inst:
- print inst
-
-elif cmd == "getdifficulty":
- try:
- print access.getdifficulty()
- except Exception as inst:
- print inst
-
-elif cmd == "getgenerate":
- try:
- print access.getgenerate()
- except Exception as inst:
- print inst
-
-elif cmd == "gethashespersec":
- try:
- print access.gethashespersec()
- except Exception as inst:
- print inst
-
-elif cmd == "getinfo":
- try:
- print access.getinfo()
- except Exception as inst:
- print inst
-
-elif cmd == "getnewaddress":
- try:
- acct = raw_input("Enter an account name: ")
- try:
- print access.getnewaddress(acct)
- except:
- print access.getnewaddress()
- except Exception as inst:
- print inst
-
-elif cmd == "getreceivedbyaccount":
- try:
- acct = raw_input("Enter an account (optional): ")
- mc = raw_input("Minimum confirmations (optional): ")
- try:
- print access.getreceivedbyaccount(acct, mc)
- except:
- print access.getreceivedbyaccount()
- except Exception as inst:
- print inst
-
-elif cmd == "getreceivedbyaddress":
- try:
- addr = raw_input("Enter a Bitcoin address (optional): ")
- mc = raw_input("Minimum confirmations (optional): ")
- try:
- print access.getreceivedbyaddress(addr, mc)
- except:
- print access.getreceivedbyaddress()
- except Exception as inst:
- print inst
-
-elif cmd == "gettransaction":
- try:
- txid = raw_input("Enter a transaction ID: ")
- print access.gettransaction(txid)
- except Exception as inst:
- print inst
-
-elif cmd == "getwork":
- try:
- data = raw_input("Data (optional): ")
- try:
- print access.gettransaction(data)
- except:
- print access.gettransaction()
- except Exception as inst:
- print inst
-
-elif cmd == "help":
- try:
- cmd = raw_input("Command (optional): ")
- try:
- print access.help(cmd)
- except:
- print access.help()
- except Exception as inst:
- print inst
-
-elif cmd == "listaccounts":
- try:
- mc = raw_input("Minimum confirmations (optional): ")
- try:
- print access.listaccounts(mc)
- except:
- print access.listaccounts()
- except Exception as inst:
- print inst
-
-elif cmd == "listreceivedbyaccount":
- try:
- mc = raw_input("Minimum confirmations (optional): ")
- incemp = raw_input("Include empty? (true/false, optional): ")
- try:
- print access.listreceivedbyaccount(mc, incemp)
- except:
- print access.listreceivedbyaccount()
- except Exception as inst:
- print inst
-
-elif cmd == "listreceivedbyaddress":
- try:
- mc = raw_input("Minimum confirmations (optional): ")
- incemp = raw_input("Include empty? (true/false, optional): ")
- try:
- print access.listreceivedbyaddress(mc, incemp)
- except:
- print access.listreceivedbyaddress()
- except Exception as inst:
- print inst
-
-elif cmd == "listtransactions":
- try:
- acct = raw_input("Account (optional): ")
- count = raw_input("Number of transactions (optional): ")
- frm = raw_input("Skip (optional):")
- try:
- print access.listtransactions(acct, count, frm)
- except:
- print access.listtransactions()
- except Exception as inst:
- print inst
-
-elif cmd == "move":
- try:
- frm = raw_input("From: ")
- to = raw_input("To: ")
- amt = raw_input("Amount:")
- mc = raw_input("Minimum confirmations (optional): ")
- comment = raw_input("Comment (optional): ")
- try:
- print access.move(frm, to, amt, mc, comment)
- except:
- print access.move(frm, to, amt)
- except Exception as inst:
- print inst
-
-elif cmd == "sendfrom":
- try:
- frm = raw_input("From: ")
- to = raw_input("To: ")
- amt = raw_input("Amount:")
- mc = raw_input("Minimum confirmations (optional): ")
- comment = raw_input("Comment (optional): ")
- commentto = raw_input("Comment-to (optional): ")
- try:
- print access.sendfrom(frm, to, amt, mc, comment, commentto)
- except:
- print access.sendfrom(frm, to, amt)
- except Exception as inst:
- print inst
-
-elif cmd == "sendmany":
- try:
- frm = raw_input("From: ")
- to = raw_input("To (in format address1:amount1,address2:amount2,...): ")
- mc = raw_input("Minimum confirmations (optional): ")
- comment = raw_input("Comment (optional): ")
- try:
- print access.sendmany(frm,to,mc,comment)
- except:
- print access.sendmany(frm,to)
- except Exception as inst:
- print inst
-
-elif cmd == "sendtoaddress":
- try:
- to = raw_input("To (in format address1:amount1,address2:amount2,...): ")
- amt = raw_input("Amount:")
- comment = raw_input("Comment (optional): ")
- commentto = raw_input("Comment-to (optional): ")
- try:
- print access.sendtoaddress(to,amt,comment,commentto)
- except:
- print access.sendtoaddress(to,amt)
- except Exception as inst:
- print inst
-
-elif cmd == "setaccount":
- try:
- addr = raw_input("Address: ")
- acct = raw_input("Account:")
- print access.setaccount(addr,acct)
- except Exception as inst:
- print inst
-
-elif cmd == "setgenerate":
- try:
- gen= raw_input("Generate? (true/false): ")
- cpus = raw_input("Max processors/cores (-1 for unlimited, optional):")
- try:
- print access.setgenerate(gen, cpus)
- except:
- print access.setgenerate(gen)
- except Exception as inst:
- print inst
-
-elif cmd == "settxfee":
- try:
- amt = raw_input("Amount:")
- print access.settxfee(amt)
- except Exception as inst:
- print inst
-
-elif cmd == "stop":
- try:
- print access.stop()
- except Exception as inst:
- print inst
-
-elif cmd == "validateaddress":
- try:
- addr = raw_input("Address: ")
- print access.validateaddress(addr)
- except Exception as inst:
- print inst
-
-elif cmd == "walletpassphrase":
- try:
- pwd = getpass.getpass(prompt="Enter wallet passphrase: ")
- access.walletpassphrase(pwd, 60)
- print "\n---Wallet unlocked---\n"
- except Exception as inst:
- print inst
-
-elif cmd == "walletpassphrasechange":
- try:
- pwd = getpass.getpass(prompt="Enter old wallet passphrase: ")
- pwd2 = getpass.getpass(prompt="Enter new wallet passphrase: ")
- access.walletpassphrasechange(pwd, pwd2)
- print
- print "\n---Passphrase changed---\n"
- except Exception as inst:
- print inst
-
-else:
- print "Command not found or not supported"
diff --git a/contrib/debian/bitcoin-tx.install b/contrib/debian/bitcoin-tx.install
new file mode 100644
index 0000000000..2c21052a68
--- /dev/null
+++ b/contrib/debian/bitcoin-tx.install
@@ -0,0 +1 @@
+usr/local/bin/bitcoin-tx usr/bin
diff --git a/contrib/debian/changelog b/contrib/debian/changelog
index 7ce3babc1b..110bfe03ef 100644
--- a/contrib/debian/changelog
+++ b/contrib/debian/changelog
@@ -1,3 +1,33 @@
+bitcoin (0.11.0-precise1) precise; urgency=medium
+
+ * New upstream release.
+
+ -- Matt Corallo (BlueMatt) <matt@mattcorallo.com> Tue, 14 Jul 2015 14:39:00 -1000
+
+bitcoin (0.10.2-precise1) precise; urgency=medium
+
+ * New upstream release.
+
+ -- Matt Corallo (BlueMatt) <matt@mattcorallo.com> Mon, 29 Jun 2015 17:33:00 -1000
+
+bitcoin (0.10.1-precise3) precise; urgency=medium
+
+ * Fix build dep (include python).
+
+ -- Matt Corallo (BlueMatt) <matt@mattcorallo.com> Tue, 5 May 2015 09:28:00 -1000
+
+bitcoin (0.10.1-precise2) precise; urgency=medium
+
+ * Fix miniupnpc dep.
+
+ -- Matt Corallo (BlueMatt) <matt@mattcorallo.com> Tue, 5 May 2015 00:33:00 -1000
+
+bitcoin (0.10.1-precise1) precise; urgency=medium
+
+ * New upstream release.
+
+ -- Matt Corallo (BlueMatt) <matt@mattcorallo.com> Tue, 5 May 2015 00:07:00 -1000
+
bitcoin (0.10.0-precise1) precise; urgency=medium
* New upstream releases.
@@ -149,7 +179,7 @@ bitcoin (0.5.3-natty0) natty; urgency=low
bitcoin (0.5.2-natty1) natty; urgency=low
* Remove mentions on anonymity in package descriptions and manpage.
- These should never have been there, bitcoin isnt anonymous without
+ These should never have been there, bitcoin isn't anonymous without
a ton of work that virtually no users will ever be willing and
capable of doing
@@ -190,7 +220,7 @@ bitcoin (0.5.0~rc1-natty1) natty; urgency=low
* Add test_bitcoin to build test
* Fix clean
- * Remove uneccessary build-dependancies
+ * Remove unnecessary build-dependancies
-- Matt Corallo <matt@bluematt.me> Wed, 26 Oct 2011 14:37:18 -0400
@@ -350,7 +380,7 @@ bitcoin (0.3.20.01~dfsg-1) unstable; urgency=low
bitcoin (0.3.19~dfsg-6) unstable; urgency=low
- * Fix override agressive optimizations.
+ * Fix override aggressive optimizations.
* Fix tighten build-dependencies to really fit backporting to Lenny:
+ Add fallback build-dependency on libdb4.6++-dev.
+ Tighten unversioned Boost build-dependencies to recent versions,
diff --git a/contrib/debian/control b/contrib/debian/control
index 4392bb3385..2fd68583ce 100644
--- a/contrib/debian/control
+++ b/contrib/debian/control
@@ -20,11 +20,12 @@ Build-Depends: debhelper,
qt4-qmake,
libqt4-dev,
libqrencode-dev,
- libprotobuf-dev, protobuf-compiler
+ libprotobuf-dev, protobuf-compiler,
+ python
Standards-Version: 3.9.2
-Homepage: http://www.bitcoin.org/
+Homepage: https://www.bitcoin.org/
Vcs-Git: git://github.com/bitcoin/bitcoin.git
-Vcs-Browser: http://github.com/bitcoin/bitcoin
+Vcs-Browser: https://github.com/bitcoin/bitcoin
Package: bitcoind
Architecture: any
@@ -56,3 +57,17 @@ Description: peer-to-peer network based digital currency - Qt GUI
requires 20+ GB of space, slowly growing.
.
This package provides Bitcoin-Qt, a GUI for Bitcoin based on Qt.
+
+Package: bitcoin-tx
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Description: peer-to-peer digital currency - standalone transaction tool
+ Bitcoin is a free open source peer-to-peer electronic cash system that
+ is completely decentralized, without the need for a central server or
+ trusted parties. Users hold the crypto keys to their own money and
+ transact directly with each other, with the help of a P2P network to
+ check for double-spending.
+ .
+ This package provides bitcoin-tx, a command-line transaction creation
+ tool which can be used without a bitcoin daemon. Some means of
+ exchanging minimal transaction data with peers is still required.
diff --git a/contrib/debian/copyright b/contrib/debian/copyright
index 55ebcaab42..83ce560a79 100644
--- a/contrib/debian/copyright
+++ b/contrib/debian/copyright
@@ -1,19 +1,15 @@
-Format: http://svn.debian.org/wsvn/dep/web/deps/dep5.mdwn?rev=174
+Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
Upstream-Name: Bitcoin
Upstream-Contact: Satoshi Nakamoto <satoshin@gmx.com>
irc://#bitcoin@freenode.net
Source: https://github.com/bitcoin/bitcoin
Files: *
-Copyright: 2009-2012, Bitcoin Core Developers
+Copyright: 2009-2015, Bitcoin Core Developers
License: Expat
Comment: The Bitcoin Core Developers encompasses the current developers listed on bitcoin.org,
as well as the numerous contributors to the project.
-Files: src/json/*
-Copyright: 2007-2009, John W. Wilkinson
-License: Expat
-
Files: debian/*
Copyright: 2010-2011, Jonas Smedegaard <dr@jones.dk>
2011, Matt Corallo <matt@bluematt.me>
@@ -23,60 +19,66 @@ Files: debian/manpages/*
Copyright: Micah Anderson <micah@debian.org>
License: GPL-3+
-Files: src/qt/res/icons/clock*.png, src/qt/res/icons/tx*.png,
- src/qt/res/src/*.svg
-Copyright: Wladimir van der Laan
+Files: src/qt/res/icons/add.png
+ src/qt/res/icons/address-book.png
+ src/qt/res/icons/configure.png
+ src/qt/res/icons/debugwindow.png
+ src/qt/res/icons/edit.png
+ src/qt/res/icons/editcopy.png
+ src/qt/res/icons/editpaste.png
+ src/qt/res/icons/export.png
+ src/qt/res/icons/eye.png
+ src/qt/res/icons/filesave.png
+ src/qt/res/icons/history.png
+ src/qt/res/icons/info.png
+ src/qt/res/icons/key.png
+ src/qt/res/icons/lock_*.png
+ src/qt/res/icons/open.png
+ src/qt/res/icons/overview.png
+ src/qt/res/icons/quit.png
+ src/qt/res/icons/receive.png
+ src/qt/res/icons/remove.png
+ src/qt/res/icons/send.png
+ src/qt/res/icons/synced.png
+ src/qt/res/icons/transaction*.png
+ src/qt/res/icons/tx_output.png
+ src/qt/res/icons/warning.png
+Copyright: Stephen Hutchings (and more)
+ http://typicons.com
License: Expat
-
-Files: src/qt/res/icons/address-book.png, src/qt/res/icons/export.png,
- src/qt/res/icons/history.png, src/qt/res/icons/key.png,
- src/qt/res/icons/lock_*.png, src/qt/res/icons/overview.png,
- src/qt/res/icons/receive.png, src/qt/res/icons/send.png,
- src/qt/res/icons/synced.png, src/qt/res/icons/filesave.png
-Copyright: David Vignoni (david@icon-king.com)
- ICON KING - www.icon-king.com
-License: LGPL
-Comment: NUVOLA ICON THEME for KDE 3.x
- Original icons: kaddressbook, klipper_dock, view-list-text,
- key-password, encrypted/decrypted, go-home, go-down,
- go-next, dialog-ok
- Site: http://www.icon-king.com/projects/nuvola/
+Comment: Site: https://github.com/stephenhutchings/typicons.font
Files: src/qt/res/icons/connect*.png
-Copyright: schollidesign
-License: GPL-3+
-Comment: Icon Pack: Human-O2
- Site: http://findicons.com/icon/93743/blocks_gnome_netstatus_0
-
-Files: src/qt/res/icons/transaction*.png
-Copyright: md2k7
+ src/qt/res/src/connect-*.svg
+Copyright: Marco Falke
License: Expat
-Comment: Site: https://bitcointalk.org/index.php?topic=15276.0
+Comment: Inspired by Stephan Hutchings Typicons
-Files: src/qt/res/icons/configure.png, src/qt/res/icons/quit.png,
- src/qt/res/icons/editcopy.png, src/qt/res/icons/editpaste.png,
- src/qt/res/icons/add.png, src/qt/res/icons/edit.png,
- src/qt/res/icons/remove.png
-Copyright: http://www.everaldo.com
-License: LGPL
-Comment: Icon Pack: Crystal SVG
+Files: src/qt/res/icons/tx_mined.png
+ src/qt/res/src/mine.svg
+Copyright: Jonas Schnelli
+License: Expat
+Comment:
-Files: src/qt/res/icons/bitcoin.png, src/qt/res/icons/toolbar.png
-Copyright: Bitboy (optimized for 16x16 by Wladimir van der Laan)
-License: PUB-DOM
+Files: src/qt/res/icons/clock*.png
+ src/qt/res/icons/eye_*.png
+ src/qt/res/icons/verify.png
+ src/qt/res/icons/tx_in*.png
+ src/qt/res/src/clock_*.svg
+ src/qt/res/src/tx_*.svg
+ src/qt/res/src/verify.svg
+Copyright: Stephan Hutching, Jonas Schnelli
+License: Expat
+Comment: Modifications of Stephan Hutchings Typicons
+
+Files: src/qt/res/icons/about.png
+ src/qt/res/icons/bitcoin.*
+ share/pixmaps/bitcoin*
+ src/qt/res/src/bitcoin.svg
+Copyright: Bitboy, Jonas Schnelli
+License: public-domain
Comment: Site: https://bitcointalk.org/?topic=1756.0
-Files: scripts/img/reload.xcf, src/qt/res/movies/*.png
-Copyright: Everaldo (Everaldo Coelho)
-License: GPL-3+
-Comment: Icon Pack: Kids
- Site: http://findicons.com/icon/17102/reload?id=17102
-
-Files: src/qt/res/images/splash2.jpg
-License: PUB-DOM
-Copyright: Crobbo (forum)
-Comment: Site: https://bitcointalk.org/index.php?topic=32273.0
-
License: Expat
Permission is hereby granted, free of charge, to any person obtaining a
@@ -98,20 +100,6 @@ License: Expat
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-License: ISC
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
- copyright notice and this permission notice appear in all copies.
- .
- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
- WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
- WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR
- BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES
- OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
- WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
- ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
- SOFTWARE.
-
License: GPL-2+
This program is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the
@@ -140,22 +128,5 @@ Comment:
You should have received a copy of the GNU General Public License along
with this program. If not, see <http://www.gnu.org/licenses/>.
-License: LGPL
- This program is free software: you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation, either version 3 of the License, or
- (at your option) any later version.
- .
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-Comment:
- On Debian systems the GNU Lesser General Public License (LGPL) is
- located in '/usr/share/common-licenses/LGPL'.
- .
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>.
-
-License: PUB-DOM
+License: public-domain
This work is in the public domain.
diff --git a/contrib/debian/examples/bitcoin.conf b/contrib/debian/examples/bitcoin.conf
index ade80d60ea..2831c07292 100644
--- a/contrib/debian/examples/bitcoin.conf
+++ b/contrib/debian/examples/bitcoin.conf
@@ -60,7 +60,7 @@
# JSON-RPC options (for controlling a running Bitcoin/bitcoind process)
#
-# server=1 tells Bitcoin-QT and bitcoind to accept JSON-RPC commands
+# server=1 tells Bitcoin-Qt and bitcoind to accept JSON-RPC commands
#server=0
# Bind to given address to listen for JSON-RPC connections. Use [host]:port notation for IPv6.
@@ -73,7 +73,7 @@
# How many seconds bitcoin will wait for a complete RPC HTTP request.
# after the HTTP connection is established.
-#rpctimeout=30
+#rpcclienttimeout=30
# By default, only RPC connections from localhost are allowed.
# Specify as many rpcallowip= settings as you like to allow connections from other hosts,
@@ -82,7 +82,7 @@
# NOTE: opening up the RPC port to hosts outside your local trusted network is NOT RECOMMENDED,
# because the rpcpassword is transmitted over the network unencrypted.
-# server=1 tells Bitcoin-QT to accept JSON-RPC commands.
+# server=1 tells Bitcoin-Qt to accept JSON-RPC commands.
# it is also read by bitcoind to determine if RPC should be enabled
#rpcallowip=10.1.1.34/255.255.255.0
#rpcallowip=1.2.3.4/24
@@ -95,15 +95,6 @@
# running on another host using this option:
#rpcconnect=127.0.0.1
-# Use Secure Sockets Layer (also known as TLS or HTTPS) to communicate
-# with Bitcoin -server or bitcoind
-#rpcssl=1
-
-# OpenSSL settings used when rpcssl=1
-#rpcsslciphers=TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH
-#rpcsslcertificatechainfile=server.cert
-#rpcsslprivatekeyfile=server.pem
-
# Transaction Fee Changes in 0.10.0
# Send transactions as zero-fee transactions if possible (default: 0)
diff --git a/contrib/debian/manpages/bitcoin-cli.1 b/contrib/debian/manpages/bitcoin-cli.1
index f953ae9db7..154b458739 100644
--- a/contrib/debian/manpages/bitcoin-cli.1
+++ b/contrib/debian/manpages/bitcoin-cli.1
@@ -36,9 +36,6 @@ Listen for JSON\-RPC connections on <port> (default: 8332 or testnet: 18332).
.TP
\fB\-rpcconnect=\fR<ip>
Send commands to node running on <ip> (default: 127.0.0.1).
-.TP
-\fB\-rpcssl\fR=\fI1\fR
-Use OpenSSL (https) for JSON\-RPC connections (see the Bitcoin Wiki for SSL setup instructions).
.SH "SEE ALSO"
\fBbitcoind\fP, \fBbitcoin.conf\fP
diff --git a/contrib/debian/manpages/bitcoin-qt.1 b/contrib/debian/manpages/bitcoin-qt.1
index a023582bc0..05eadc94cd 100644
--- a/contrib/debian/manpages/bitcoin-qt.1
+++ b/contrib/debian/manpages/bitcoin-qt.1
@@ -178,18 +178,6 @@ Set maximum block size in bytes (default: 250000)
.HP
\fB\-blockprioritysize=\fR<n> Set maximum size of high\-priority/low\-fee transactions in bytes (default: 27000)
.PP
-SSL options: (see the Bitcoin Wiki for SSL setup instructions)
-.TP
-\fB\-rpcssl\fR
-Use OpenSSL (https) for JSON\-RPC connections
-.TP
-\fB\-rpcsslcertificatechainfile=\fR<file.cert>
-Server certificate file (default: server.cert)
-.TP
-\fB\-rpcsslprivatekeyfile=\fR<file.pem>
-Server private key (default: server.pem)
-.TP
-\fB\-rpcsslciphers=\fR<ciphers>
Acceptable ciphers (default: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)
.SS "UI options:"
.TP
diff --git a/contrib/debian/manpages/bitcoin.conf.5 b/contrib/debian/manpages/bitcoin.conf.5
index 8a0078d5d5..0cf4d991e3 100644
--- a/contrib/debian/manpages/bitcoin.conf.5
+++ b/contrib/debian/manpages/bitcoin.conf.5
@@ -46,16 +46,6 @@ Listen for RPC connections on this TCP port.
\fBrpcconnect=\fR\fI'127.0.0.1'\fR
You can use *bitcoin* or *bitcoind(1)* to send commands to *bitcoin*/*bitcoind(1)* running on another host using this option.
.TP
-\fBrpcssl=\fR\fI'1'\fR
-Use Secure Sockets Layer (also known as TLS or HTTPS) to communicate with *bitcoin* '\-server' or *bitcoind(1)*. Example of OpenSSL settings used when *rpcssl*='1':
-.TP
-\fB\-rpcsslciphers=\fR<ciphers>
-Acceptable ciphers (default: TLSv1+HIGH:\:!SSLv2:\:!aNULL:\:!eNULL:\:!AH:\:!3DES:\:@STRENGTH)
-.TP
-\fBrpcsslcertificatechainfile=\fR\fI'server.cert'\fR
-.TP
-\fBrpcsslprivatekeyfile=\fR\fI'server.pem'\fR
-.TP
.SH MISCELLANEOUS OPTIONS
.TP
\fBgen=\fR[\fI'0'\fR|\fI'1'\fR]
diff --git a/contrib/debian/manpages/bitcoind.1 b/contrib/debian/manpages/bitcoind.1
index c225b9f3e9..5b0f2921aa 100644
--- a/contrib/debian/manpages/bitcoind.1
+++ b/contrib/debian/manpages/bitcoind.1
@@ -62,20 +62,6 @@ Allow JSON\-RPC connections from specified IP address
.TP
\fB\-rpcconnect=\fR<ip>
Send commands to node running on <ip>
-.PP
-SSL options: (see the Bitcoin Wiki for SSL setup instructions)
-.TP
-\fB\-rpcssl\fR=\fI1\fR
-Use OpenSSL (https) for JSON\-RPC connections
-.TP
-\fB\-rpcsslcertificatchainfile=\fR<file.cert>
-Server certificate file (default: server.cert)
-.TP
-\fB\-rpcsslprivatekeyfile=\fR<file.pem>
-Server private key (default: server.pem)
-.TP
-\fB\-rpcsslciphers=\fR<ciphers>
-Acceptable ciphers (default: TLSv1+HIGH:\:!SSLv2:\:!aNULL:\:!eNULL:\:!AH:\:!3DES:\:@STRENGTH)
.TP
\-?
This help message
diff --git a/contrib/devtools/README.md b/contrib/devtools/README.md
index f90afa7f20..278794f14c 100644
--- a/contrib/devtools/README.md
+++ b/contrib/devtools/README.md
@@ -1,9 +1,14 @@
Contents
-===========
+========
This directory contains tools for developers working on this repository.
+clang-format.py
+===============
+
+A script to format cpp source code according to [.clang-format](../../src/.clang-format). This should only be applied to new files or files which are currently not actively developed on. Also, git subtrees are not subject to formatting.
+
github-merge.sh
-==================
+===============
A small script to automate merging pull-requests securely and sign them with GPG.
@@ -37,23 +42,31 @@ Configuring the github-merge tool for the bitcoin repository is done in the foll
git config --global user.signingkey mykeyid (if you want to GPG sign)
fix-copyright-headers.py
-===========================
+========================
Every year newly updated files need to have its copyright headers updated to reflect the current year.
If you run this script from src/ it will automatically update the year on the copyright header for all
.cpp and .h files if these have a git commit from the current year.
For example a file changed in 2014 (with 2014 being the current year):
+
```// Copyright (c) 2009-2013 The Bitcoin Core developers```
would be changed to:
+
```// Copyright (c) 2009-2014 The Bitcoin Core developers```
+optimize-pngs.py
+================
+
+A script to optimize png files in the bitcoin
+repository (requires pngcrush).
+
symbol-check.py
-==================
+===============
A script to check that the (Linux) executables produced by gitian only contain
-allowed gcc, glibc and libstdc++ version symbols. This makes sure they are
+allowed gcc, glibc and libstdc++ version symbols. This makes sure they are
still compatible with the minimum supported Linux distribution versions.
Example usage after a gitian build:
@@ -70,7 +83,7 @@ If there are 'unsupported' symbols, the return value will be 1 a list like this
.../64/test_bitcoin: symbol _ZNSt8__detail15_List_nod from unsupported version GLIBCXX_3.4.15
update-translations.py
-=======================
+======================
Run this script from the root of the repository to update all translations from transifex.
It will do the following automatically:
@@ -93,4 +106,5 @@ maintained:
* for sec/leveldb: https://github.com/bitcoin/leveldb.git (branch bitcoin-fork)
Usage: git-subtree-check.sh DIR COMMIT
+
COMMIT may be omitted, in which case HEAD is used.
diff --git a/contrib/devtools/clang-format.py b/contrib/devtools/clang-format.py
new file mode 100755
index 0000000000..cee99047ac
--- /dev/null
+++ b/contrib/devtools/clang-format.py
@@ -0,0 +1,62 @@
+#!/usr/bin/env python
+'''
+Wrapper script for clang-format
+
+Copyright (c) 2015 MarcoFalke
+Copyright (c) 2015 The Bitcoin Core developers
+Distributed under the MIT software license, see the accompanying
+file COPYING or http://www.opensource.org/licenses/mit-license.php.
+'''
+
+import os
+import sys
+import subprocess
+
+tested_versions = ['3.6.0', '3.6.1', '3.6.2'] # A set of versions known to produce the same output
+accepted_file_extensions = ('.h', '.cpp') # Files to format
+
+def check_clang_format_version(clang_format_exe):
+ try:
+ output = subprocess.check_output([clang_format_exe, '-version'])
+ for ver in tested_versions:
+ if ver in output:
+ print "Detected clang-format version " + ver
+ return
+ raise RuntimeError("Untested version: " + output)
+ except Exception as e:
+ print 'Could not verify version of ' + clang_format_exe + '.'
+ raise e
+
+def check_command_line_args(argv):
+ required_args = ['{clang-format-exe}', '{files}']
+ example_args = ['clang-format-3.x', 'src/main.cpp', 'src/wallet/*']
+
+ if(len(argv) < len(required_args) + 1):
+ for word in (['Usage:', argv[0]] + required_args):
+ print word,
+ print ''
+ for word in (['E.g:', argv[0]] + example_args):
+ print word,
+ print ''
+ sys.exit(1)
+
+def run_clang_format(clang_format_exe, files):
+ for target in files:
+ if os.path.isdir(target):
+ for path, dirs, files in os.walk(target):
+ run_clang_format(clang_format_exe, (os.path.join(path, f) for f in files))
+ elif target.endswith(accepted_file_extensions):
+ print "Format " + target
+ subprocess.check_call([clang_format_exe, '-i', '-style=file', target], stdout=open(os.devnull, 'wb'), stderr=subprocess.STDOUT)
+ else:
+ print "Skip " + target
+
+def main(argv):
+ check_command_line_args(argv)
+ clang_format_exe = argv[1]
+ files = argv[2:]
+ check_clang_format_version(clang_format_exe)
+ run_clang_format(clang_format_exe, files)
+
+if __name__ == "__main__":
+ main(sys.argv)
diff --git a/contrib/devtools/github-merge.sh b/contrib/devtools/github-merge.sh
index ec7a1f4c4b..afb53f0390 100755
--- a/contrib/devtools/github-merge.sh
+++ b/contrib/devtools/github-merge.sh
@@ -161,7 +161,11 @@ if [[ "d$REPLY" =~ ^d[Ss]$ ]]; then
cleanup
exit 1
else
- git commit -q --gpg-sign --amend --no-edit
+ if ! git commit -q --gpg-sign --amend --no-edit; then
+ echo "Error signing, exiting."
+ cleanup
+ exit 1
+ fi
fi
else
echo "Not signing off on merge, exiting."
diff --git a/contrib/devtools/optimize-pngs.py b/contrib/devtools/optimize-pngs.py
index 38aaa00f31..799e0cc7d0 100755
--- a/contrib/devtools/optimize-pngs.py
+++ b/contrib/devtools/optimize-pngs.py
@@ -1,5 +1,8 @@
#!/usr/bin/env python
-
+'''
+Run this script every time you change one of the png files. Using pngcrush, it will optimize the png files, remove various color profiles, remove ancillary chunks (alla) and text chunks (text).
+#pngcrush -brute -ow -rem gAMA -rem cHRM -rem iCCP -rem sRGB -rem alla -rem text
+'''
import os
import sys
import subprocess
@@ -15,17 +18,15 @@ def content_hash(filename):
'''Return hash of RGBA contents of image'''
i = Image.open(filename)
i = i.convert('RGBA')
- data = i.tostring()
+ data = i.tobytes()
return hashlib.sha256(data).hexdigest()
-#optimize png, remove various color profiles, remove ancillary chunks (alla) and text chunks (text)
-#pngcrush -brute -ow -rem gAMA -rem cHRM -rem iCCP -rem sRGB -rem alla -rem text
-
pngcrush = 'pngcrush'
git = 'git'
-folders = ["src/qt/res/movies", "src/qt/res/icons", "src/qt/res/images"]
+folders = ["src/qt/res/movies", "src/qt/res/icons", "share/pixmaps"]
basePath = subprocess.check_output([git, 'rev-parse', '--show-toplevel']).rstrip('\n')
totalSaveBytes = 0
+noHashChange = True
outputArray = []
for folder in folders:
@@ -68,6 +69,7 @@ for fileDict in outputArray:
oldHash = fileDict['sha256Old']
newHash = fileDict['sha256New']
totalSaveBytes += fileDict['osize'] - fileDict['psize']
+ noHashChange = noHashChange and (oldHash == newHash)
print fileDict['file']+"\n size diff from: "+str(fileDict['osize'])+" to: "+str(fileDict['psize'])+"\n old sha256: "+oldHash+"\n new sha256: "+newHash+"\n"
-print "completed. Total reduction: "+str(totalSaveBytes)+" bytes"
+print "completed. Checksum stable: "+str(noHashChange)+". Total reduction: "+str(totalSaveBytes)+" bytes"
diff --git a/contrib/devtools/security-check.py b/contrib/devtools/security-check.py
new file mode 100755
index 0000000000..e96eaa9c38
--- /dev/null
+++ b/contrib/devtools/security-check.py
@@ -0,0 +1,181 @@
+#!/usr/bin/python2
+'''
+Perform basic ELF security checks on a series of executables.
+Exit status will be 0 if succesful, and the program will be silent.
+Otherwise the exit status will be 1 and it will log which executables failed which checks.
+Needs `readelf` (for ELF) and `objdump` (for PE).
+'''
+from __future__ import division,print_function
+import subprocess
+import sys
+import os
+
+READELF_CMD = os.getenv('READELF', '/usr/bin/readelf')
+OBJDUMP_CMD = os.getenv('OBJDUMP', '/usr/bin/objdump')
+
+def check_ELF_PIE(executable):
+ '''
+ Check for position independent executable (PIE), allowing for address space randomization.
+ '''
+ p = subprocess.Popen([READELF_CMD, '-h', '-W', executable], stdout=subprocess.PIPE, stderr=subprocess.PIPE, stdin=subprocess.PIPE)
+ (stdout, stderr) = p.communicate()
+ if p.returncode:
+ raise IOError('Error opening file')
+
+ ok = False
+ for line in stdout.split('\n'):
+ line = line.split()
+ if len(line)>=2 and line[0] == 'Type:' and line[1] == 'DYN':
+ ok = True
+ return ok
+
+def get_ELF_program_headers(executable):
+ '''Return type and flags for ELF program headers'''
+ p = subprocess.Popen([READELF_CMD, '-l', '-W', executable], stdout=subprocess.PIPE, stderr=subprocess.PIPE, stdin=subprocess.PIPE)
+ (stdout, stderr) = p.communicate()
+ if p.returncode:
+ raise IOError('Error opening file')
+ in_headers = False
+ count = 0
+ headers = []
+ for line in stdout.split('\n'):
+ if line.startswith('Program Headers:'):
+ in_headers = True
+ if line == '':
+ in_headers = False
+ if in_headers:
+ if count == 1: # header line
+ ofs_typ = line.find('Type')
+ ofs_offset = line.find('Offset')
+ ofs_flags = line.find('Flg')
+ ofs_align = line.find('Align')
+ if ofs_typ == -1 or ofs_offset == -1 or ofs_flags == -1 or ofs_align == -1:
+ raise ValueError('Cannot parse elfread -lW output')
+ elif count > 1:
+ typ = line[ofs_typ:ofs_offset].rstrip()
+ flags = line[ofs_flags:ofs_align].rstrip()
+ headers.append((typ, flags))
+ count += 1
+ return headers
+
+def check_ELF_NX(executable):
+ '''
+ Check that no sections are writable and executable (including the stack)
+ '''
+ have_wx = False
+ have_gnu_stack = False
+ for (typ, flags) in get_ELF_program_headers(executable):
+ if typ == 'GNU_STACK':
+ have_gnu_stack = True
+ if 'W' in flags and 'E' in flags: # section is both writable and executable
+ have_wx = True
+ return have_gnu_stack and not have_wx
+
+def check_ELF_RELRO(executable):
+ '''
+ Check for read-only relocations.
+ GNU_RELRO program header must exist
+ Dynamic section must have BIND_NOW flag
+ '''
+ have_gnu_relro = False
+ for (typ, flags) in get_ELF_program_headers(executable):
+ # Note: not checking flags == 'R': here as linkers set the permission differently
+ # This does not affect security: the permission flags of the GNU_RELRO program header are ignored, the PT_LOAD header determines the effective permissions.
+ # However, the dynamic linker need to write to this area so these are RW.
+ # Glibc itself takes care of mprotecting this area R after relocations are finished.
+ # See also http://permalink.gmane.org/gmane.comp.gnu.binutils/71347
+ if typ == 'GNU_RELRO':
+ have_gnu_relro = True
+
+ have_bindnow = False
+ p = subprocess.Popen([READELF_CMD, '-d', '-W', executable], stdout=subprocess.PIPE, stderr=subprocess.PIPE, stdin=subprocess.PIPE)
+ (stdout, stderr) = p.communicate()
+ if p.returncode:
+ raise IOError('Error opening file')
+ for line in stdout.split('\n'):
+ tokens = line.split()
+ if len(tokens)>1 and tokens[1] == '(BIND_NOW)':
+ have_bindnow = True
+ return have_gnu_relro and have_bindnow
+
+def check_ELF_Canary(executable):
+ '''
+ Check for use of stack canary
+ '''
+ p = subprocess.Popen([READELF_CMD, '--dyn-syms', '-W', executable], stdout=subprocess.PIPE, stderr=subprocess.PIPE, stdin=subprocess.PIPE)
+ (stdout, stderr) = p.communicate()
+ if p.returncode:
+ raise IOError('Error opening file')
+ ok = False
+ for line in stdout.split('\n'):
+ if '__stack_chk_fail' in line:
+ ok = True
+ return ok
+
+def get_PE_dll_characteristics(executable):
+ '''
+ Get PE DllCharacteristics bits
+ '''
+ p = subprocess.Popen([OBJDUMP_CMD, '-x', executable], stdout=subprocess.PIPE, stderr=subprocess.PIPE, stdin=subprocess.PIPE)
+ (stdout, stderr) = p.communicate()
+ if p.returncode:
+ raise IOError('Error opening file')
+ for line in stdout.split('\n'):
+ tokens = line.split()
+ if len(tokens)>=2 and tokens[0] == 'DllCharacteristics':
+ return int(tokens[1],16)
+ return 0
+
+
+def check_PE_PIE(executable):
+ '''PIE: DllCharacteristics bit 0x40 signifies dynamicbase (ASLR)'''
+ return bool(get_PE_dll_characteristics(executable) & 0x40)
+
+def check_PE_NX(executable):
+ '''NX: DllCharacteristics bit 0x100 signifies nxcompat (DEP)'''
+ return bool(get_PE_dll_characteristics(executable) & 0x100)
+
+CHECKS = {
+'ELF': [
+ ('PIE', check_ELF_PIE),
+ ('NX', check_ELF_NX),
+ ('RELRO', check_ELF_RELRO),
+ ('Canary', check_ELF_Canary)
+],
+'PE': [
+ ('PIE', check_PE_PIE),
+ ('NX', check_PE_NX)
+]
+}
+
+def identify_executable(executable):
+ with open(filename, 'rb') as f:
+ magic = f.read(4)
+ if magic.startswith(b'MZ'):
+ return 'PE'
+ elif magic.startswith(b'\x7fELF'):
+ return 'ELF'
+ return None
+
+if __name__ == '__main__':
+ retval = 0
+ for filename in sys.argv[1:]:
+ try:
+ etype = identify_executable(filename)
+ if etype is None:
+ print('%s: unknown format' % filename)
+ retval = 1
+ continue
+
+ failed = []
+ for (name, func) in CHECKS[etype]:
+ if not func(filename):
+ failed.append(name)
+ if failed:
+ print('%s: failed %s' % (filename, ' '.join(failed)))
+ retval = 1
+ except IOError:
+ print('%s: cannot open' % filename)
+ retval = 1
+ exit(retval)
+
diff --git a/contrib/devtools/symbol-check.py b/contrib/devtools/symbol-check.py
index fad891f800..34f1ed2d17 100755
--- a/contrib/devtools/symbol-check.py
+++ b/contrib/devtools/symbol-check.py
@@ -1,4 +1,4 @@
-#!/usr/bin/python
+#!/usr/bin/python2
# Copyright (c) 2014 Wladimir J. van der Laan
# Distributed under the MIT software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
@@ -15,6 +15,7 @@ from __future__ import division, print_function
import subprocess
import re
import sys
+import os
# Debian 6.0.9 (Squeeze) has:
#
@@ -45,8 +46,10 @@ MAX_VERSIONS = {
IGNORE_EXPORTS = {
'_edata', '_end', '_init', '__bss_start', '_fini'
}
-READELF_CMD = '/usr/bin/readelf'
-CPPFILT_CMD = '/usr/bin/c++filt'
+READELF_CMD = os.getenv('READELF', '/usr/bin/readelf')
+CPPFILT_CMD = os.getenv('CPPFILT', '/usr/bin/c++filt')
+# Allowed NEEDED libraries
+ALLOWED_LIBRARIES = {'librt.so.1','libpthread.so.0','libanl.so.1','libm.so.6','libgcc_s.so.1','libc.so.6','ld-linux-x86-64.so.2'}
class CPPFilt(object):
'''
@@ -98,6 +101,22 @@ def check_version(max_versions, version):
return False
return ver <= max_versions[lib]
+def read_libraries(filename):
+ p = subprocess.Popen([READELF_CMD, '-d', '-W', filename], stdout=subprocess.PIPE, stderr=subprocess.PIPE, stdin=subprocess.PIPE)
+ (stdout, stderr) = p.communicate()
+ if p.returncode:
+ raise IOError('Error opening file')
+ libraries = []
+ for line in stdout.split('\n'):
+ tokens = line.split()
+ if len(tokens)>2 and tokens[1] == '(NEEDED)':
+ match = re.match('^Shared library: \[(.*)\]$', ' '.join(tokens[2:]))
+ if match:
+ libraries.append(match.group(1))
+ else:
+ raise ValueError('Unparseable (NEEDED) specification')
+ return libraries
+
if __name__ == '__main__':
cppfilt = CPPFilt()
retval = 0
@@ -113,6 +132,11 @@ if __name__ == '__main__':
continue
print('%s: export of symbol %s not allowed' % (filename, cppfilt(sym)))
retval = 1
+ # Check dependency libraries
+ for library_name in read_libraries(filename):
+ if library_name not in ALLOWED_LIBRARIES:
+ print('%s: NEEDED library %s is not allowed' % (filename, library_name))
+ retval = 1
exit(retval)
diff --git a/contrib/devtools/test-security-check.py b/contrib/devtools/test-security-check.py
new file mode 100755
index 0000000000..fed7626aab
--- /dev/null
+++ b/contrib/devtools/test-security-check.py
@@ -0,0 +1,60 @@
+#!/usr/bin/python2
+'''
+Test script for security-check.py
+'''
+from __future__ import division,print_function
+import subprocess
+import sys
+import unittest
+
+def write_testcode(filename):
+ with open(filename, 'w') as f:
+ f.write('''
+ #include <stdio.h>
+ int main()
+ {
+ printf("the quick brown fox jumps over the lazy god\\n");
+ return 0;
+ }
+ ''')
+
+def call_security_check(cc, source, executable, options):
+ subprocess.check_call([cc,source,'-o',executable] + options)
+ p = subprocess.Popen(['./security-check.py',executable], stdout=subprocess.PIPE, stderr=subprocess.PIPE, stdin=subprocess.PIPE)
+ (stdout, stderr) = p.communicate()
+ return (p.returncode, stdout.rstrip())
+
+class TestSecurityChecks(unittest.TestCase):
+ def test_ELF(self):
+ source = 'test1.c'
+ executable = 'test1'
+ cc = 'gcc'
+ write_testcode(source)
+
+ self.assertEqual(call_security_check(cc, source, executable, ['-Wl,-zexecstack','-fno-stack-protector','-Wl,-znorelro']),
+ (1, executable+': failed PIE NX RELRO Canary'))
+ self.assertEqual(call_security_check(cc, source, executable, ['-Wl,-znoexecstack','-fno-stack-protector','-Wl,-znorelro']),
+ (1, executable+': failed PIE RELRO Canary'))
+ self.assertEqual(call_security_check(cc, source, executable, ['-Wl,-znoexecstack','-fstack-protector-all','-Wl,-znorelro']),
+ (1, executable+': failed PIE RELRO'))
+ self.assertEqual(call_security_check(cc, source, executable, ['-Wl,-znoexecstack','-fstack-protector-all','-Wl,-znorelro','-pie','-fPIE']),
+ (1, executable+': failed RELRO'))
+ self.assertEqual(call_security_check(cc, source, executable, ['-Wl,-znoexecstack','-fstack-protector-all','-Wl,-zrelro','-Wl,-z,now','-pie','-fPIE']),
+ (0, ''))
+
+ def test_PE(self):
+ source = 'test1.c'
+ executable = 'test1.exe'
+ cc = 'i686-w64-mingw32-gcc'
+ write_testcode(source)
+
+ self.assertEqual(call_security_check(cc, source, executable, []),
+ (1, executable+': failed PIE NX'))
+ self.assertEqual(call_security_check(cc, source, executable, ['-Wl,--nxcompat']),
+ (1, executable+': failed PIE'))
+ self.assertEqual(call_security_check(cc, source, executable, ['-Wl,--nxcompat','-Wl,--dynamicbase']),
+ (0, ''))
+
+if __name__ == '__main__':
+ unittest.main()
+
diff --git a/contrib/gitian-descriptors/gitian-linux.yml b/contrib/gitian-descriptors/gitian-linux.yml
index 440d95a355..a98a71e2f9 100644
--- a/contrib/gitian-descriptors/gitian-linux.yml
+++ b/contrib/gitian-descriptors/gitian-linux.yml
@@ -24,7 +24,7 @@ files: []
script: |
WRAP_DIR=$HOME/wrapped
HOSTS="i686-pc-linux-gnu x86_64-unknown-linux-gnu"
- CONFIGFLAGS="--enable-upnp-default --enable-glibc-back-compat --enable-reduce-exports LDFLAGS=-static-libstdc++"
+ CONFIGFLAGS="--enable-glibc-back-compat --enable-reduce-exports LDFLAGS=-static-libstdc++"
FAKETIME_HOST_PROGS=""
FAKETIME_PROGS="date ar ranlib nm strip"
diff --git a/contrib/gitian-descriptors/gitian-osx.yml b/contrib/gitian-descriptors/gitian-osx.yml
index bad9a0e768..eeeb408ded 100644
--- a/contrib/gitian-descriptors/gitian-osx.yml
+++ b/contrib/gitian-descriptors/gitian-osx.yml
@@ -27,7 +27,7 @@ files:
script: |
WRAP_DIR=$HOME/wrapped
HOSTS="x86_64-apple-darwin11"
- CONFIGFLAGS="--enable-upnp-default --enable-reduce-exports GENISOIMAGE=$WRAP_DIR/genisoimage"
+ CONFIGFLAGS="--enable-reduce-exports GENISOIMAGE=$WRAP_DIR/genisoimage"
FAKETIME_HOST_PROGS=""
FAKETIME_PROGS="ar ranlib date dmg genisoimage"
diff --git a/contrib/gitian-descriptors/gitian-win.yml b/contrib/gitian-descriptors/gitian-win.yml
index 966820ec51..5fa0db6784 100644
--- a/contrib/gitian-descriptors/gitian-win.yml
+++ b/contrib/gitian-descriptors/gitian-win.yml
@@ -26,7 +26,7 @@ files: []
script: |
WRAP_DIR=$HOME/wrapped
HOSTS="x86_64-w64-mingw32 i686-w64-mingw32"
- CONFIGFLAGS="--enable-upnp-default --enable-reduce-exports"
+ CONFIGFLAGS="--enable-reduce-exports"
FAKETIME_HOST_PROGS="g++ ar ranlib nm windres strip"
FAKETIME_PROGS="date makensis zip"
diff --git a/contrib/gitian-downloader/bluematt-key.pgp b/contrib/gitian-downloader/bluematt-key.pgp
index fb6d9eb284..2389d4657f 100644
--- a/contrib/gitian-downloader/bluematt-key.pgp
+++ b/contrib/gitian-downloader/bluematt-key.pgp
Binary files differ
diff --git a/contrib/gitian-downloader/btcdrak-key.pgp b/contrib/gitian-downloader/btcdrak-key.pgp
new file mode 100644
index 0000000000..60d76c0ec7
--- /dev/null
+++ b/contrib/gitian-downloader/btcdrak-key.pgp
@@ -0,0 +1,142 @@
+-----BEGIN P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iNn1gW9IxZwt/Ga9AvZbIAYhL2m/xBbdfMKAG7Ttjzd3Ac+8wrGm3lOesBD
+AJUtBmURu8b1Eyj72IQcV0AJM8gvc1B0H345oX6VBgkBB0bf3nuUVftv6r529jTr
+Jix6yrs4uf25tefzcFuqqE1s1r+pSZFIDpaNsP+jjMgYj/zn4dLOZaq4V3SHvnsU
+v8KOUC2/qNH9U0KC6bh4mw0fVsHzhkaOjOM7SF1Doc8Lz4vZuk4BpumHpkHEG90x
+CLg2k/R9iIDQfcGtKY++1/GitjXakPuKrJctZ1SJuW1KWyzFeF4qvuowmLGMFRVi
++CG5JJSLCUr+cPXa8NbjZv9BwSHqWbn3grr7ZE/j6SFNhuLmByeePPNKRt0cae6a
+3TQkQFh/yvSIkB5BrB1n2x+xNoWMME+GR0zYQCOncCe8W+a5BZ1mTiVGacHgVqSN
+eEaG0RH54+pi4gw=
+=fFMC
+-----END PGP PUBLIC KEY BLOCK-----
diff --git a/contrib/gitian-downloader/prab-key.pgp b/contrib/gitian-downloader/prab-key.pgp
index 0940d15c6a..0870c88b9b 100644
--- a/contrib/gitian-downloader/prab-key.pgp
+++ b/contrib/gitian-downloader/prab-key.pgp
@@ -1,29 +1,81 @@
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: GnuPG v2
-mQINBFI3uQUBEADRjbUQb65n7sfjT5OPnjPO8oUh5onKjNALRGHGJxWwNkwkgmT6
-mZFWjikM8B3ONEp8MfTyoOzv+MbWuBDS1GZxi0Tcb4HU323/7hhwfXV4bcHif7vq
-Sc1ahN/5LIHj0htC6Uj78IWXW+kPWjX9biRJnZ9eerfA/AatC+4KuvYTjAa9uAfa
-BnAs38EG/7ryXzxdz6M8iNB/YjHE72swSH84uTtA3LqI3huVY41eFMK6qXFBMFiq
-H6bMx4pjwKzJj78bibXEQxq88yc6TLxbURs2GF4s11dr7Iq2Y+6FHqX3PfUByZBz
-PQfbEy1Df4RbB3htCBv5puETlqZ0PVe9/B+WrcnaobxrbKEAqt0Dspf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Uil99CVABEBAAGJAiUEGAEIAA8FAlYH
+OocCGwwFCQPCZwAACgkQvNBNjpzMrCr50BAApY22DRYqmtALFieREu78BvjQT/DY
+f9Smkga1YVr9/Ph9NJ5iSVeM8mrVkwZnGRK1UCjk16rsmB70IqlnJnyJGXqPMj7M
+3ioOWY8fCL8fmLI2g0TbXXKl3e0nGByGXW4pwyLYa/hR7XJMco/PxqIGhEKcCIRP
+dxq/6U9T9SYe2IkfXBYZAxfUTE2FkRpw1zSfZN3z32LM7ICZ26NRHRWo4Kv5sij4
+0mYYecFmWdf6ib5pPCI0HmPGpblbmZgR1LoJNmuNxfpgEnPe8BbxtO4mueNW5A39
+y7gLCmDZ8MaOGxvjGByBoXxXP62BiU910iZZZurjSD+3FD+NUX0m4yxVIZCkuInY
+QzLxFACr26IYpcsPHIYGnEjDBFw9hHdP6tzKbjzgVSZESheQf2zwit0YYSjwHQN/
+XGnBy8+p66As61jg8mcAN2Zd8vwFKZOvfEnSsaoK5ssAh8jixhPj+Ujgs0/PB8t/
+ON20yr+YRAwU+RVnC/vfvrM83mjoz4mbmSLapFz/xWNhoS0ZczYEI5CyxE8peGPX
+gd/7tim2OqUuZ3SlH5TZP3pdJcqxTNN7iNaWy1wAY/sb8As3Pge/Vv5hSYmHNjQy
+h/62SSbTf6OZCuUGjy8fvVj51SclVKqGNprmAqVrIy0J+VeTKj4r7PGesPWJavRc
+RFdDYRHByRDDL1I=
+=dOwX
-----END PGP PUBLIC KEY BLOCK-----
diff --git a/contrib/init/README.md b/contrib/init/README.md
index 0d19da3039..eb5d30acce 100644
--- a/contrib/init/README.md
+++ b/contrib/init/README.md
@@ -5,6 +5,7 @@ Upstart: bitcoind.conf
OpenRC: bitcoind.openrc
bitcoind.openrcconf
CentOS: bitcoind.init
+OS X: org.bitcoin.bitcoind.plist
have been made available to assist packagers in creating node packages here.
diff --git a/contrib/init/org.bitcoin.bitcoind.plist b/contrib/init/org.bitcoin.bitcoind.plist
new file mode 100644
index 0000000000..e94cd4466d
--- /dev/null
+++ b/contrib/init/org.bitcoin.bitcoind.plist
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+ <key>Label</key>
+ <string>org.bitcoin.bitcoind</string>
+ <key>ProgramArguments</key>
+ <array>
+ <string>/usr/local/bin/bitcoind</string>
+ <string>-daemon</string>
+ </array>
+ <key>RunAtLoad</key>
+ <true/>
+</dict>
+</plist>
diff --git a/contrib/verify-commits/trusted-git-root b/contrib/verify-commits/trusted-git-root
index eb13f8762e..838b8d1ea8 100644
--- a/contrib/verify-commits/trusted-git-root
+++ b/contrib/verify-commits/trusted-git-root
@@ -1 +1 @@
-053038e5ba116cb319fb85f3cb3e062cf1b3df15
+165e323d851cc87213c7673c6f278e87a6f2e752
diff --git a/contrib/zmq/zmq_sub.py b/contrib/zmq/zmq_sub.py
new file mode 100755
index 0000000000..decf29d42a
--- /dev/null
+++ b/contrib/zmq/zmq_sub.py
@@ -0,0 +1,37 @@
+#!/usr/bin/env python2
+
+import array
+import binascii
+import zmq
+
+port = 28332
+
+zmqContext = zmq.Context()
+zmqSubSocket = zmqContext.socket(zmq.SUB)
+zmqSubSocket.setsockopt(zmq.SUBSCRIBE, "hashblock")
+zmqSubSocket.setsockopt(zmq.SUBSCRIBE, "hashtx")
+zmqSubSocket.setsockopt(zmq.SUBSCRIBE, "rawblock")
+zmqSubSocket.setsockopt(zmq.SUBSCRIBE, "rawtx")
+zmqSubSocket.connect("tcp://127.0.0.1:%i" % port)
+
+try:
+ while True:
+ msg = zmqSubSocket.recv_multipart()
+ topic = str(msg[0])
+ body = msg[1]
+
+ if topic == "hashblock":
+ print "- HASH BLOCK -"
+ print binascii.hexlify(body)
+ elif topic == "hashtx":
+ print '- HASH TX -'
+ print binascii.hexlify(body)
+ elif topic == "rawblock":
+ print "- RAW BLOCK HEADER -"
+ print binascii.hexlify(body[:80])
+ elif topic == "rawtx":
+ print '- RAW TX -'
+ print binascii.hexlify(body)
+
+except KeyboardInterrupt:
+ zmqContext.destroy()