Skip to content

Commit 8212916

Browse files
authored
Merge pull request #10 from ElectraProtocol/dev
Release v1.0.3.0
2 parents 257f601 + ef13c82 commit 8212916

File tree

198 files changed

+23910
-8257
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

198 files changed

+23910
-8257
lines changed

.appveyor.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ environment:
1010
QT_DOWNLOAD_URL: 'https://github.com/sipsorcery/qt_win_binary/releases/download/qt598x64_vs2019_v1681/qt598_x64_vs2019_1681.zip'
1111
QT_DOWNLOAD_HASH: '00cf7327818c07d74e0b1a4464ffe987c2728b00d49d4bf333065892af0515c3'
1212
QT_LOCAL_PATH: 'C:\Qt5.9.8_x64_static_vs2019'
13-
VCPKG_TAG: '2020.11-1'
13+
VCPKG_TAG: '75522bb1f2e7d863078bcd06322348f053a9e33f'
1414
install:
1515
# Disable zmq test for now since python zmq library on Windows would cause Access violation sometimes.
1616
# - cmd: pip install zmq

README.md

Lines changed: 28 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,34 @@
1-
XEP Core integration/staging tree
2-
=====================================
3-
4-
https://bitcoincore.org
5-
61
What is XEP?
7-
----------------
2+
============
83

9-
XEP is an experimental digital currency that enables instant payments to
10-
anyone, anywhere in the world. XEP uses peer-to-peer technology to operate
11-
with no central authority: managing transactions and issuing money are carried
12-
out collectively by the network. XEP Core is the name of open source
13-
software which enables the use of this currency.
4+
The Electra Protocol has been developed with invaluable features in mind to allow merchants, customers, and casual users to incorporate Electra Protocol’s global payment
5+
system into their everyday lives. Since the beginning, Electra has kept its users at the forefront of Project decisions throughout the development process, intending to
6+
transform how the world views payments through cryptocurrency and blockchain technologies.
147

158
For more information, as well as an immediately usable, binary version of
16-
the XEP Core software, see https://bitcoincore.org/en/download/, or read the
17-
[original whitepaper](https://bitcoincore.org/xep.pdf).
9+
the XEP Core software, see https://www.electraprotocol.com/, or read the
10+
[whitepaper](https://www.electraprotocol.com/whitepaper/).
11+
12+
<table>
13+
<tr> <td>Ticker</td><td>XEP</td></tr>
14+
<tr> <td>Algorithm</td><td>SHA-256</td></tr>
15+
<tr> <td>Consensus</td><td>Proof-of-Stake 3.0e</td></tr>
16+
<tr> <td>Circulating supply</td><td>https://explorer.electraprotocol.network/</td></tr>
17+
<tr> <td>Block Time</td><td>80 Seconds</td></tr>
18+
<tr> <td>Block Size</td><td>10 MB (Dynamic)</td></tr>
19+
<tr> <td>Staking Reward</td><td>3% yearly</td></tr>
20+
<tr> <td>Transactions Per Second</td><td>up to 1600</td></tr>
21+
<tr> <td>Retarget</td><td>Every Block</td></tr>
22+
<tr> <td>Coin Maturation Time</td><td>12 Hours & 600 confirmations</td></tr>
23+
<tr> <td>Max Coin Age</td><td>30 Days</td></tr>
24+
<tr> <td>Electronic Payment</td><td>ElectraPay</td></tr>
25+
<tr> <td>SegWit</td><td>Native</td></tr>
26+
<tr> <td>Lightning Network</td><td>Native</td></tr>
27+
<tr> <td>Taproot</td><td>Native</td></tr>
28+
<tr> <td>Atomic Swap</td><td>Yes</td></tr>
29+
<tr> <td>Premine</td><td>3B*</td></tr>
30+
</table>
31+
* 1.5B the first year, then 0.5 each subsequent years. (This is the maximum amount and can be burned eventually.)
1832

1933
License
2034
-------
@@ -26,55 +40,5 @@ Development Process
2640
-------------------
2741

2842
The `master` branch is regularly built (see `doc/build-*.md` for instructions) and tested, but it is not guaranteed to be
29-
completely stable. [Tags](https://github.com/bitcoin/bitcoin/tags) are created
43+
completely stable. [Tags](https://github.com/ElectraProtocol/XEP-Core/tags) are created
3044
regularly from release branches to indicate new official, stable release versions of XEP Core.
31-
32-
The https://github.com/xep-core/gui repository is used exclusively for the
33-
development of the GUI. Its master branch is identical in all monotree
34-
repositories. Release branches and tags do not exist, so please do not fork
35-
that repository unless it is for development reasons.
36-
37-
The contribution workflow is described in [CONTRIBUTING.md](CONTRIBUTING.md)
38-
and useful hints for developers can be found in [doc/developer-notes.md](doc/developer-notes.md).
39-
40-
Testing
41-
-------
42-
43-
Testing and code review is the bottleneck for development; we get more pull
44-
requests than we can review and test on short notice. Please be patient and help out by testing
45-
other people's pull requests, and remember this is a security-critical project where any mistake might cost people
46-
lots of money.
47-
48-
### Automated Testing
49-
50-
Developers are strongly encouraged to write [unit tests](src/test/README.md) for new code, and to
51-
submit new unit tests for old code. Unit tests can be compiled and run
52-
(assuming they weren't disabled in configure) with: `make check`. Further details on running
53-
and extending unit tests can be found in [/src/test/README.md](/src/test/README.md).
54-
55-
There are also [regression and integration tests](/test), written
56-
in Python, that are run automatically on the build server.
57-
These tests can be run (if the [test dependencies](/test) are installed) with: `test/functional/test_runner.py`
58-
59-
The Travis CI system makes sure that every pull request is built for Windows, Linux, and macOS, and that unit/sanity tests are run automatically.
60-
61-
### Manual Quality Assurance (QA) Testing
62-
63-
Changes should be tested by somebody other than the developer who wrote the
64-
code. This is especially important for large or high-risk changes. It is useful
65-
to add a test plan to the pull request description if testing the changes is
66-
not straightforward.
67-
68-
Translations
69-
------------
70-
71-
Changes to translations as well as new translations can be submitted to
72-
[XEP Core's Transifex page](https://www.transifex.com/xep/xep/).
73-
74-
Translations are periodically pulled from Transifex and merged into the git repository. See the
75-
[translation process](doc/translation_process.md) for details on how this works.
76-
77-
**Important**: We do not accept translation changes as GitHub pull requests because the next
78-
pull from Transifex would automatically overwrite them again.
79-
80-
Translators should also subscribe to the [mailing list](https://groups.google.com/forum/#!forum/xep-translators).

build-aux/m4/l_socket.m4

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# Illumos/SmartOS requires linking with -lsocket if
2+
# using getifaddrs & freeifaddrs
3+
4+
m4_define([_CHECK_SOCKET_testbody], [[
5+
#include <sys/types.h>
6+
#include <ifaddrs.h>
7+
8+
int main() {
9+
struct ifaddrs *ifaddr;
10+
getifaddrs(&ifaddr);
11+
freeifaddrs(ifaddr);
12+
}
13+
]])
14+
15+
AC_DEFUN([CHECK_SOCKET], [
16+
17+
AC_LANG_PUSH(C++)
18+
19+
AC_MSG_CHECKING([whether ifaddrs funcs can be used without link library])
20+
21+
AC_LINK_IFELSE([AC_LANG_SOURCE([_CHECK_SOCKET_testbody])],[
22+
AC_MSG_RESULT([yes])
23+
],[
24+
AC_MSG_RESULT([no])
25+
LIBS="$LIBS -lsocket"
26+
AC_MSG_CHECKING([whether getifaddrs needs -lsocket])
27+
AC_LINK_IFELSE([AC_LANG_SOURCE([_CHECK_SOCKET_testbody])],[
28+
AC_MSG_RESULT([yes])
29+
],[
30+
AC_MSG_RESULT([no])
31+
AC_MSG_FAILURE([cannot figure out how to use getifaddrs])
32+
])
33+
])
34+
35+
AC_LANG_POP
36+
])

build_msvc/libxep_qt/libxep_qt.vcxproj

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,7 @@
104104
<ClCompile Include="$(GeneratedFilesOutDir)\moc\moc_transactiondesc.cpp" />
105105
<ClCompile Include="$(GeneratedFilesOutDir)\moc\moc_transactiondescdialog.cpp" />
106106
<ClCompile Include="$(GeneratedFilesOutDir)\moc\moc_transactionfilterproxy.cpp" />
107+
<ClCompile Include="$(GeneratedFilesOutDir)\moc\moc_transactionoverviewwidget.cpp" />
107108
<ClCompile Include="$(GeneratedFilesOutDir)\moc\moc_transactionrecord.cpp" />
108109
<ClCompile Include="$(GeneratedFilesOutDir)\moc\moc_transactiontablemodel.cpp" />
109110
<ClCompile Include="$(GeneratedFilesOutDir)\moc\moc_transactionview.cpp" />

configure.ac

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
AC_PREREQ([2.69])
22
define(_CLIENT_VERSION_MAJOR, 1)
33
define(_CLIENT_VERSION_MINOR, 0)
4-
define(_CLIENT_VERSION_REVISION, 2)
4+
define(_CLIENT_VERSION_REVISION, 3)
55
define(_CLIENT_VERSION_BUILD, 0)
66
define(_CLIENT_VERSION_RC, 0)
77
define(_CLIENT_VERSION_IS_RELEASE, true)
@@ -866,7 +866,7 @@ fi
866866

867867
AC_CHECK_HEADERS([endian.h sys/endian.h byteswap.h stdio.h stdlib.h unistd.h strings.h sys/types.h sys/stat.h sys/select.h sys/prctl.h sys/sysctl.h vm/vm_param.h sys/vmmeter.h sys/resources.h])
868868

869-
AC_CHECK_DECLS([getifaddrs, freeifaddrs],,,
869+
AC_CHECK_DECLS([getifaddrs, freeifaddrs],[CHECK_SOCKET],,
870870
[#include <sys/types.h>
871871
#include <ifaddrs.h>]
872872
)

contrib/gitian-descriptors/gitian-osx-signer.yml

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,13 @@ architectures:
77
- "amd64"
88
packages:
99
- "faketime"
10+
- "python3-pip"
1011
remotes:
1112
- "url": "https://github.com/xep-core/xep-detached-sigs.git"
1213
"dir": "signature"
14+
- "url": "https://github.com/achow101/signapple.git"
15+
"dir": "signapple"
16+
"commit": "b084cbbf44d5330448ffce0c7d118f75781b64bd"
1317
files:
1418
- "xep-osx-unsigned.tar.gz"
1519
script: |
@@ -30,11 +34,19 @@ script: |
3034
chmod +x ${WRAP_DIR}/${prog}
3135
done
3236
33-
UNSIGNED=xep-osx-unsigned.tar.gz
37+
# Install signapple
38+
cd signapple
39+
python3 -m pip install -U pip setuptools
40+
python3 -m pip install .
41+
export PATH="$HOME/.local/bin":$PATH
42+
cd ..
43+
44+
UNSIGNED_TARBALL=xep-osx-unsigned.tar.gz
45+
UNSIGNED_APP=dist/XEP-Qt.app
3446
SIGNED=xep-osx-signed.dmg
3547
36-
tar -xf ${UNSIGNED}
48+
tar -xf ${UNSIGNED_TARBALL}
3749
OSX_VOLNAME="$(cat osx_volname)"
38-
./detached-sig-apply.sh ${UNSIGNED} signature/osx
50+
./detached-sig-apply.sh ${UNSIGNED_APP} signature/osx/dist
3951
${WRAP_DIR}/genisoimage -no-cache-inodes -D -l -probe -V "${OSX_VOLNAME}" -no-pad -r -dir-mode 0755 -apple -o uncompressed.dmg signed-app
4052
${WRAP_DIR}/dmg dmg uncompressed.dmg ${OUTDIR}/${SIGNED}

contrib/gitian-descriptors/gitian-osx.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,8 +138,6 @@ script: |
138138
cp contrib/macdeploy/detached-sig-apply.sh unsigned-app-${i}
139139
cp contrib/macdeploy/detached-sig-create.sh unsigned-app-${i}
140140
cp ${BASEPREFIX}/${i}/native/bin/dmg ${BASEPREFIX}/${i}/native/bin/genisoimage unsigned-app-${i}
141-
cp ${BASEPREFIX}/${i}/native/bin/${i}-codesign_allocate unsigned-app-${i}/codesign_allocate
142-
cp ${BASEPREFIX}/${i}/native/bin/${i}-pagestuff unsigned-app-${i}/pagestuff
143141
mv dist unsigned-app-${i}
144142
pushd unsigned-app-${i}
145143
find . | sort | tar --mtime="$REFERENCE_DATETIME" --no-recursion --mode='u+rw,go+r-w,a+X' --owner=0 --group=0 -c -T - | gzip -9n > ${OUTDIR}/${DISTNAME}-osx-unsigned.tar.gz

contrib/macdeploy/detached-sig-apply.sh

Lines changed: 3 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,9 @@ set -e
88

99
UNSIGNED="$1"
1010
SIGNATURE="$2"
11-
ARCH=x86_64
1211
ROOTDIR=dist
13-
TEMPDIR=signed.temp
1412
OUTDIR=signed-app
13+
SIGNAPPLE=signapple
1514

1615
if [ -z "$UNSIGNED" ]; then
1716
echo "usage: $0 <unsigned app> <signature>"
@@ -23,35 +22,6 @@ if [ -z "$SIGNATURE" ]; then
2322
exit 1
2423
fi
2524

26-
rm -rf ${TEMPDIR} && mkdir -p ${TEMPDIR}
27-
tar -C ${TEMPDIR} -xf ${UNSIGNED}
28-
cp -rf "${SIGNATURE}"/* ${TEMPDIR}
29-
30-
if [ -z "${PAGESTUFF}" ]; then
31-
PAGESTUFF=${TEMPDIR}/pagestuff
32-
fi
33-
34-
if [ -z "${CODESIGN_ALLOCATE}" ]; then
35-
CODESIGN_ALLOCATE=${TEMPDIR}/codesign_allocate
36-
fi
37-
38-
find ${TEMPDIR} -name "*.sign" | while read i; do
39-
SIZE=$(stat -c %s "${i}")
40-
TARGET_FILE="$(echo "${i}" | sed 's/\.sign$//')"
41-
42-
echo "Allocating space for the signature of size ${SIZE} in ${TARGET_FILE}"
43-
${CODESIGN_ALLOCATE} -i "${TARGET_FILE}" -a ${ARCH} ${SIZE} -o "${i}.tmp"
44-
45-
OFFSET=$(${PAGESTUFF} "${i}.tmp" -p | tail -2 | grep offset | sed 's/[^0-9]*//g')
46-
if [ -z ${QUIET} ]; then
47-
echo "Attaching signature at offset ${OFFSET}"
48-
fi
49-
50-
dd if="$i" of="${i}.tmp" bs=1 seek=${OFFSET} count=${SIZE} 2>/dev/null
51-
mv "${i}.tmp" "${TARGET_FILE}"
52-
rm "${i}"
53-
echo "Success."
54-
done
55-
mv ${TEMPDIR}/${ROOTDIR} ${OUTDIR}
56-
rm -rf ${TEMPDIR}
25+
${SIGNAPPLE} apply ${UNSIGNED} ${SIGNATURE}
26+
mv ${ROOTDIR} ${OUTDIR}
5727
echo "Signed: ${OUTDIR}"

contrib/macdeploy/detached-sig-create.sh

Lines changed: 6 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -8,44 +8,21 @@ set -e
88

99
ROOTDIR=dist
1010
BUNDLE="${ROOTDIR}/XEP-Qt.app"
11-
CODESIGN=codesign
11+
SIGNAPPLE=signapple
1212
TEMPDIR=sign.temp
13-
TEMPLIST=${TEMPDIR}/signatures.txt
1413
OUT=signature-osx.tar.gz
15-
OUTROOT=osx
14+
OUTROOT=osx/dist
1615

1716
if [ -z "$1" ]; then
18-
echo "usage: $0 <codesign args>"
19-
echo "example: $0 -s MyIdentity"
17+
echo "usage: $0 <signapple args>"
18+
echo "example: $0 <path to key>"
2019
exit 1
2120
fi
2221

23-
rm -rf ${TEMPDIR} ${TEMPLIST}
22+
rm -rf ${TEMPDIR}
2423
mkdir -p ${TEMPDIR}
2524

26-
${CODESIGN} -f --file-list ${TEMPLIST} "$@" "${BUNDLE}"
27-
28-
grep -v CodeResources < "${TEMPLIST}" | while read i; do
29-
TARGETFILE="${BUNDLE}/$(echo "${i}" | sed "s|.*${BUNDLE}/||")"
30-
SIZE=$(pagestuff "$i" -p | tail -2 | grep size | sed 's/[^0-9]*//g')
31-
OFFSET=$(pagestuff "$i" -p | tail -2 | grep offset | sed 's/[^0-9]*//g')
32-
SIGNFILE="${TEMPDIR}/${OUTROOT}/${TARGETFILE}.sign"
33-
DIRNAME="$(dirname "${SIGNFILE}")"
34-
mkdir -p "${DIRNAME}"
35-
echo "Adding detached signature for: ${TARGETFILE}. Size: ${SIZE}. Offset: ${OFFSET}"
36-
dd if="$i" of="${SIGNFILE}" bs=1 skip=${OFFSET} count=${SIZE} 2>/dev/null
37-
done
38-
39-
grep CodeResources < "${TEMPLIST}" | while read i; do
40-
TARGETFILE="${BUNDLE}/$(echo "${i}" | sed "s|.*${BUNDLE}/||")"
41-
RESOURCE="${TEMPDIR}/${OUTROOT}/${TARGETFILE}"
42-
DIRNAME="$(dirname "${RESOURCE}")"
43-
mkdir -p "${DIRNAME}"
44-
echo "Adding resource for: \"${TARGETFILE}\""
45-
cp "${i}" "${RESOURCE}"
46-
done
47-
48-
rm ${TEMPLIST}
25+
${SIGNAPPLE} sign -f --detach "${TEMPDIR}/${OUTROOT}" "$@" "${BUNDLE}"
4926

5027
tar -C "${TEMPDIR}" -czf "${OUT}" .
5128
rm -rf "${TEMPDIR}"

contrib/testgen/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@ Utilities to generate test vectors for the data-driven XEP tests.
44

55
Usage:
66

7-
PYTHONPATH=../../test/functional/test_framework ./gen_key_io_test_vectors.py valid 50 > ../../src/test/data/key_io_valid.json
8-
PYTHONPATH=../../test/functional/test_framework ./gen_key_io_test_vectors.py invalid 50 > ../../src/test/data/key_io_invalid.json
7+
PYTHONPATH=../../test/functional/test_framework ./gen_key_io_test_vectors.py valid 70 > ../../src/test/data/key_io_valid.json
8+
PYTHONPATH=../../test/functional/test_framework ./gen_key_io_test_vectors.py invalid 70 > ../../src/test/data/key_io_invalid.json

0 commit comments

Comments
 (0)