Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

V1.1.0.0 #28

Merged
merged 29 commits into from
Jan 28, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
bafe2ee
Block Version Increase/CheckLockTimeVerify/Warning Fix/[WIP]ENUM for …
spencerlievens Jan 27, 2017
c5ed59a
working E164 version
spencerlievens Jan 27, 2017
d2a4406
Increased DAP limit 10x, and activate DAP only when public GW
spencerlievens Jan 27, 2017
f958da3
Fix typos/format
spencerlievens Jan 27, 2017
d5ca882
Bump Version
spencerlievens Jan 27, 2017
94bb961
Fix Crash in GetStake
spencerlievens Jan 27, 2017
2007356
[RPC]Add wallet lock info to getinfo()
spencerlievens Jan 27, 2017
d864d50
qt: double click on name page table will do copy all values action
spencerlievens Jan 27, 2017
ee08d73
empty value in name_update will keep previous value
spencerlievens Jan 27, 2017
5186c61
Fix Warnings/Errors
spencerlievens Jan 27, 2017
3be5b63
Fix Gitian Descriptor Paths and Versions
spencerlievens Jan 27, 2017
c85df8a
Update Date in Desriptor
spencerlievens Jan 27, 2017
06f3d45
[RPC]fix currency display, fix currency input to match bitcoin
spencerlievens Jan 27, 2017
540122c
Revert currency input to old behaviour
spencerlievens Jan 27, 2017
82fe483
Fix Prev Commit and Fix Missing Function Needed by Windows for SLKDNS
spencerlievens Jan 27, 2017
d81e76f
Fix Qt link in depends
spencerlievens Jan 27, 2017
2ce004f
Fix Warnings and include path
spencerlievens Jan 27, 2017
0239071
Fix further warnings
spencerlievens Jan 27, 2017
13fc6ea
Revert travis.yml
spencerlievens Jan 27, 2017
b3e8f18
Amend name_operation function
spencerlievens Jan 27, 2017
fb02b98
[RPC]add hex and base64 input/output to name_show, name_new, name_update
spencerlievens Jan 27, 2017
6902c69
[RPC]add hex and base64 output to the rest on name commands
spencerlievens Jan 27, 2017
7f1a5aa
[RPC]add legacy json mode (enabled by default)
spencerlievens Jan 27, 2017
e295e9a
depends fix
SvenKercher Jan 27, 2017
ccdcf94
Update Protobuf 2.5.0 -> 2.6.1
SvenKercher Jan 27, 2017
cd3e27b
Merge pull request #29 from coin-info-net/patch-2
SCDeveloper Jan 27, 2017
d90c912
Merge pull request #30 from coin-info-net/patch-1
SCDeveloper Jan 27, 2017
56a4276
Add Checkpoints
spencerlievens Jan 28, 2017
7309d94
Locks/Better Logging/Typos
spencerlievens Jan 28, 2017
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
language: cpp
compiler: gcc

os: linux

sudo: required
dist: trusty

install:
- sudo apt-get -qq update
- sudo apt-get install -y build-essential libtool autotools-dev autoconf pkg-config libssl-dev libcrypto++-dev
Expand Down
2 changes: 2 additions & 0 deletions Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,8 @@ check-local:
@qa/pull-tester/run-silkd-for-test.sh $(JAVA) -jar $(JAVA_COMPARISON_TOOL) qa/tmp/compTool $(COMPARISON_TOOL_REORG_TESTS) 2>&1
endif

dist_noinst_SCRIPTS = autogen.sh

EXTRA_DIST = $(top_srcdir)/share/genbuild.sh qa/pull-tester/rpc-tests.sh qa/pull-tester/run-silk-cli qa/rpc-tests $(DIST_DOCS) $(WINDOWS_PACKAGING) $(OSX_PACKAGING)

CLEANFILES = $(OSX_DMG) $(SILK_WIN_INSTALLER)
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# **Silk-Core (SLK) v1.0.1.2**
# **Silk-Core (SLK) v1.1.0.0**
[![Deploy](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy)


Expand Down
10 changes: 5 additions & 5 deletions configure.ac
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
dnl require autoconf 2.60 (AS_ECHO/AS_ECHO_N)
AC_PREREQ([2.60])
define(_CLIENT_VERSION_MAJOR, 1)
define(_CLIENT_VERSION_MINOR, 0)
define(_CLIENT_VERSION_REVISION, 1)
define(_CLIENT_VERSION_BUILD, 2)
define(_CLIENT_VERSION_MINOR, 1)
define(_CLIENT_VERSION_REVISION, 0)
define(_CLIENT_VERSION_BUILD, 0)
define(_CLIENT_VERSION_IS_RELEASE, true)
define(_COPYRIGHT_YEAR, 2017)
AC_INIT([Silk Core],[_CLIENT_VERSION_MAJOR._CLIENT_VERSION_MINOR._CLIENT_VERSION_REVISION],[silk])
Expand Down Expand Up @@ -399,8 +399,8 @@ if test x$use_lcov = xyes; then
[AC_MSG_ERROR("lcov testing requested but --coverage flag does not work")])
fi

dnl Check for endianness
AC_C_BIGENDIAN
dnl Require little endian
### ??? AC_C_BIGENDIAN([AC_MSG_ERROR("Big Endian not supported")])

dnl Check for pthread compile/link requirements
AX_PTHREAD
Expand Down
7 changes: 4 additions & 3 deletions contrib/gitian-descriptors/gitian-linux.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
---
name: "silk-linux-0.5"
name: "silk-linux-1.1"
enable_cache: true
suites:
- "trusty"
architectures:
- "amd64"
packages:
- "curl"
- "g++-multilib"
- "git-core"
- "pkg-config"
Expand All @@ -15,9 +16,9 @@ packages:
- "faketime"
- "bsdmainutils"
- "binutils-gold"
reference_datetime: "2016-01-01 00:00:00"
reference_datetime: "2017-01-01 00:00:00"
remotes:
- "url": "https://github.com/Silk/silk.git"
- "url": "https://github.com/silknetwork/silk-core.git"
"dir": "silk"
files: []
script: |
Expand Down
5 changes: 3 additions & 2 deletions contrib/gitian-descriptors/gitian-osx.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
---
name: "silk-osx-0.5"
name: "silk-osx-1.1"
enable_cache: true
suites:
- "trusty"
architectures:
- "amd64"
packages:
- "g++-multilib"
- "curl"
- "git-core"
- "pkg-config"
- "autoconf"
Expand All @@ -20,7 +21,7 @@ packages:
- "libbz2-dev"
reference_datetime: "2017-01-01 00:00:00"
remotes:
- "url": "https://github.com/Silk/silk.git"
- "url": "https://github.com/silknetwork/silk-core.git"
"dir": "silk"
files:
- "MacOSX10.7.sdk.tar.gz"
Expand Down
3 changes: 2 additions & 1 deletion contrib/gitian-descriptors/gitian-win.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
---
name: "silk-win-0.5"
name: "silk-win-1.1"
enable_cache: true
suites:
- "trusty"
architectures:
- "amd64"
packages:
- "curl"
- "g++"
- "git-core"
- "pkg-config"
Expand Down
2 changes: 1 addition & 1 deletion depends/builders/darwin.mk
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ build_darwin_OTOOL: = $(shell xcrun -f otool)
build_darwin_NM: = $(shell xcrun -f nm)
build_darwin_INSTALL_NAME_TOOL:=$(shell xcrun -f install_name_tool)
build_darwin_SHA256SUM = shasum -a 256
build_darwin_DOWNLOAD = curl --connect-timeout $(DOWNLOAD_CONNECT_TIMEOUT) --retry $(DOWNLOAD_RETRIES) -L -o
build_darwin_DOWNLOAD = curl --location --fail --connect-timeout $(DOWNLOAD_CONNECT_TIMEOUT) --retry $(DOWNLOAD_RETRIES) -o

#darwin host on darwin builder. overrides darwin host preferences.
darwin_CC=$(shell xcrun -f clang) -mmacosx-version-min=$(OSX_MIN_VERSION)
Expand Down
2 changes: 1 addition & 1 deletion depends/builders/linux.mk
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
build_linux_SHA256SUM = sha256sum
build_linux_DOWNLOAD = wget --timeout=$(DOWNLOAD_CONNECT_TIMEOUT) --tries=$(DOWNLOAD_RETRIES) -nv -O
build_linux_DOWNLOAD = curl --location --fail --connect-timeout $(DOWNLOAD_CONNECT_TIMEOUT) --retry $(DOWNLOAD_RETRIES) -o
2 changes: 1 addition & 1 deletion depends/config.guess
Original file line number Diff line number Diff line change
Expand Up @@ -1099,7 +1099,7 @@ EOF
# uname -m prints for DJGPP always 'pc', but it prints nothing about
# the processor, so we play safe by assuming i586.
# Note: whatever this is, it MUST be the same as what config.sub
# prints for the "djgpp" host, or else GDB configury will decide that
# prints for the "djgpp" host, or else GDB configure will decide that
# this is a cross-build.
echo i586-pc-msdosdjgpp
exit ;;
Expand Down
4 changes: 2 additions & 2 deletions depends/packages/miniupnpc.mk
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package=miniupnpc
$(package)_version=1.9.20140701
$(package)_version=1.9.20151008
$(package)_download_path=http://miniupnp.free.fr/files
$(package)_file_name=$(package)-$($(package)_version).tar.gz
$(package)_sha256_hash=26f3985bad7768b8483b793448ae49414cdc4451d0ec83e7c1944367e15f9f07
$(package)_sha256_hash=e444ac3b587ce82709c4d0cfca1fe71f44f9fc433e9f946b12b9e1bfe667a633

define $(package)_set_vars
$(package)_build_opts=CC="$($(package)_cc)"
Expand Down
6 changes: 3 additions & 3 deletions depends/packages/native_protobuf.mk
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package=native_protobuf
$(package)_version=2.5.0
$(package)_download_path=https://protobuf.googlecode.com/files
$(package)_version=2.6.1
$(package)_download_path=https://github.com/google/protobuf/releases/download/v$($(package)_version)
$(package)_file_name=protobuf-$($(package)_version).tar.bz2
$(package)_sha256_hash=13bfc5ae543cf3aa180ac2485c0bc89495e3ae711fc6fab4f8ffe90dfb4bb677
$(package)_sha256_hash=ee445612d544d885ae240ffbcbf9267faa9f593b7b101f21d58beceb92661910

define $(package)_set_vars
$(package)_config_opts=--disable-shared
Expand Down
2 changes: 1 addition & 1 deletion depends/packages/openssl.mk
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ $(package)_config_opts=--prefix=$(host_prefix) --openssldir=$(host_prefix)/etc/o
$(package)_config_opts+=no-krb5 no-camellia no-capieng no-cast no-cms no-dtls1 no-gost no-gmp no-heartbeats no-idea no-jpake no-md2
$(package)_config_opts+=no-mdc2 no-rc5 no-rdrand no-rfc3779 no-rsax no-sctp no-seed no-sha0 no-static_engine no-whirlpool no-rc2 no-rc4 no-ssl2 no-ssl3
$(package)_config_opts+=$($(package)_cflags) $($(package)_cppflags)
$(package)_config_opts_linux=-fPIC
$(package)_config_opts_linux=-fPIC -Wa,--noexecstack
$(package)_config_opts_x86_64_linux=linux-x86_64
$(package)_config_opts_i686_linux=linux-generic32
$(package)_config_opts_arm_linux=linux-generic32
Expand Down
2 changes: 1 addition & 1 deletion depends/packages/qt.mk
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
PACKAGE=qt
$(package)_version=5.2.1
$(package)_download_path=http://download.qt-project.org/official_releases/qt/5.2/$($(package)_version)/single
$(package)_download_path=http://download.qt.io/archive/qt/5.2/$($(package)_version)/single
$(package)_file_name=$(package)-everywhere-opensource-src-$($(package)_version).tar.gz
$(package)_sha256_hash=84e924181d4ad6db00239d87250cc89868484a14841f77fb85ab1f1dbdcd7da1
$(package)_dependencies=openssl
Expand Down
2 changes: 1 addition & 1 deletion doc/Doxyfile
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ PROJECT_NAME = Silk
# This could be handy for archiving the generated documentation or
# if some version control system is used.

PROJECT_NUMBER = 1.0.0.0
PROJECT_NUMBER = 1.0.1.3

# Using the PROJECT_BRIEF tag one can provide an optional one line description
# for a project that appears at the top of each page and should give viewer
Expand Down
5 changes: 0 additions & 5 deletions qa/pull-tester/rpc-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,6 @@ CURDIR=$(cd $(dirname "$0"); pwd)
export SILKCLI=${BUILDDIR}/qa/pull-tester/run-silk-cli
export SILKD=${REAL_SILKD}

if [ "x${EXEEXT}" = "x.exe" ]; then
echo "Win tests currently disabled"
exit 0
fi

#Run the tests

if [ "x${ENABLE_SILKD}${ENABLE_UTILS}${ENABLE_WALLET}" = "x111" ]; then
Expand Down
175 changes: 175 additions & 0 deletions qa/rpc-tests/bip65-cltv-p2p.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,175 @@
#!/usr/bin/env python2
#
# Distributed under the MIT/X11 software license, see the accompanying
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
#

from test_framework.test_framework import ComparisonTestFramework
from test_framework.util import *
from test_framework.mininode import CTransaction, NetworkThread
from test_framework.blocktools import create_coinbase, create_block
from test_framework.comptool import TestInstance, TestManager
from test_framework.script import CScript, OP_1NEGATE, OP_NOP2, OP_DROP
from binascii import hexlify, unhexlify
import cStringIO
import time

def cltv_invalidate(tx):
'''Modify the signature in vin 0 of the tx to fail CLTV

Prepends -1 CLTV DROP in the scriptSig itself.
'''
tx.vin[0].scriptSig = CScript([OP_1NEGATE, OP_NOP2, OP_DROP] +
list(CScript(tx.vin[0].scriptSig)))

'''
This test is meant to exercise BIP65 (CHECKLOCKTIMEVERIFY)
Connect to a single node.
Mine 2 (version 3) blocks (save the coinbases for later).
Generate 98 more version 3 blocks, verify the node accepts.
Mine 749 version 4 blocks, verify the node accepts.
Check that the new CLTV rules are not enforced on the 750th version 4 block.
Check that the new CLTV rules are enforced on the 751st version 4 block.
Mine 199 new version blocks.
Mine 1 old-version block.
Mine 1 new version block.
Mine 1 old version block, see that the node rejects.
'''

class BIP65Test(ComparisonTestFramework):

def __init__(self):
self.num_nodes = 1

def setup_network(self):
# Must set the blockversion for this test
self.nodes = start_nodes(1, self.options.tmpdir,
extra_args=[['-debug', '-whitelist=127.0.0.1', '-blockversion=3']],
binary=[self.options.testbinary])

def run_test(self):
test = TestManager(self, self.options.tmpdir)
test.add_all_connections(self.nodes)
NetworkThread().start() # Start up network handling in another thread
test.run()

def create_transaction(self, node, coinbase, to_address, amount):
from_txid = node.getblock(coinbase)['tx'][0]
inputs = [{ "txid" : from_txid, "vout" : 0}]
outputs = { to_address : amount }
rawtx = node.createrawtransaction(inputs, outputs)
signresult = node.signrawtransaction(rawtx)
tx = CTransaction()
f = cStringIO.StringIO(unhexlify(signresult['hex']))
tx.deserialize(f)
return tx

def get_tests(self):

self.coinbase_blocks = self.nodes[0].setgenerate(True, 2)
self.tip = int ("0x" + self.nodes[0].getbestblockhash() + "L", 0)
self.nodeaddress = self.nodes[0].getnewaddress()
self.last_block_time = time.time()

''' 98 more version 3 blocks '''
test_blocks = []
for i in xrange(98):
block = create_block(self.tip, create_coinbase(2), self.last_block_time + 1)
block.nVersion = 3
block.rehash()
block.solve()
test_blocks.append([block, True])
self.last_block_time += 1
self.tip = block.sha256
yield TestInstance(test_blocks, sync_every_block=False)

''' Mine 749 version 4 blocks '''
test_blocks = []
for i in xrange(749):
block = create_block(self.tip, create_coinbase(2), self.last_block_time + 1)
block.nVersion = 4
block.rehash()
block.solve()
test_blocks.append([block, True])
self.last_block_time += 1
self.tip = block.sha256
yield TestInstance(test_blocks, sync_every_block=False)

'''
Check that the new CLTV rules are not enforced in the 750th
version 3 block.
'''
spendtx = self.create_transaction(self.nodes[0],
self.coinbase_blocks[0], self.nodeaddress, 1.0)
cltv_invalidate(spendtx)
spendtx.rehash()

block = create_block(self.tip, create_coinbase(2), self.last_block_time + 1)
block.nVersion = 4
block.vtx.append(spendtx)
block.hashMerkleRoot = block.calc_merkle_root()
block.rehash()
block.solve()

self.last_block_time += 1
self.tip = block.sha256
yield TestInstance([[block, True]])

'''
Check that the new CLTV rules are enforced in the 751st version 4
block.
'''
spendtx = self.create_transaction(self.nodes[0],
self.coinbase_blocks[1], self.nodeaddress, 1.0)
cltv_invalidate(spendtx)
spendtx.rehash()

block = create_block(self.tip, create_coinbase(1), self.last_block_time + 1)
block.nVersion = 4
block.vtx.append(spendtx)
block.hashMerkleRoot = block.calc_merkle_root()
block.rehash()
block.solve()
self.last_block_time += 1
yield TestInstance([[block, False]])

''' Mine 199 new version blocks on last valid tip '''
test_blocks = []
for i in xrange(199):
block = create_block(self.tip, create_coinbase(1), self.last_block_time + 1)
block.nVersion = 4
block.rehash()
block.solve()
test_blocks.append([block, True])
self.last_block_time += 1
self.tip = block.sha256
yield TestInstance(test_blocks, sync_every_block=False)

''' Mine 1 old version block '''
block = create_block(self.tip, create_coinbase(1), self.last_block_time + 1)
block.nVersion = 3
block.rehash()
block.solve()
self.last_block_time += 1
self.tip = block.sha256
yield TestInstance([[block, True]])

''' Mine 1 new version block '''
block = create_block(self.tip, create_coinbase(1), self.last_block_time + 1)
block.nVersion = 4
block.rehash()
block.solve()
self.last_block_time += 1
self.tip = block.sha256
yield TestInstance([[block, True]])

''' Mine 1 old version block, should be invalid '''
block = create_block(self.tip, create_coinbase(1), self.last_block_time + 1)
block.nVersion = 3
block.rehash()
block.solve()
self.last_block_time += 1
yield TestInstance([[block, False]])

if __name__ == '__main__':
BIP65Test().main()
Loading