Skip to content
This repository has been archived by the owner on Apr 19, 2024. It is now read-only.

Sync project. #3

Merged
merged 81 commits into from
Sep 9, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
81 commits
Select commit Hold shift + click to select a range
72c8b9e
Update FIO block explorer url (#903)
hewigovens Mar 30, 2020
72846ba
Update zcash/xlm block explorer (#915)
hewigovens Apr 4, 2020
d3e86ea
Change password type from string to data (#917)
hewigovens Apr 6, 2020
8f8a396
enable Filecoin json protobuf signing (#919)
hewigovens Apr 9, 2020
0d91994
[IoTeX ] support IoTeX native staking (#912)
coderbradlee Apr 10, 2020
4fd327a
Fix possible memory leak in walletconsole/Util.cpp (#921)
draane Apr 14, 2020
e8ff9c7
Build sample apps in CI (#909)
optout21 Apr 15, 2020
87c4f1f
Create auto_assign.yml (#928)
vikmeup Apr 23, 2020
15fb8f3
Add CODEOWNERS (#930)
vikmeup Apr 23, 2020
e0e21bc
Migrate CI to GitHub Actions (#937)
hewigovens Apr 27, 2020
7dde1a5
Bitcoin Script minor fixes and new tests. (#933)
optout21 Apr 27, 2020
4dfeeeb
Some low-impact cppcheck finding fixes. (#938)
optout21 Apr 29, 2020
02eab8a
Add Elrond blockchain (#929)
andreibancioiu Apr 29, 2020
be69646
Add TWFIOAccount (#940)
hewigovens Apr 30, 2020
cb6e57f
Bitcoin Signing coverage (#939)
optout21 May 2, 2020
b76214d
Replace parse_hex with boost::unhex (#944)
hewigovens May 5, 2020
39070cf
Add Bitcoin Gold implementation (#926)
h4x3rotab May 5, 2020
b61a114
Speed up bootstrap.sh, pretty iOS test (#948)
hewigovens May 7, 2020
870a192
Extra Decred signer tests and fixes (#949)
optout21 May 8, 2020
6bf65b4
Bitcoin&Decred signing: Fix for assert bug for invalid address. (#952)
optout21 May 13, 2020
25467e1
Update Android Gradle to 6.4.0 (#956)
hewigovens May 14, 2020
8c9ddbe
[Swift] Return nil if hex string length is odd (#959)
hewigovens May 15, 2020
f1411a9
(BTC) Extra tests for UnspentSelector UTXO selection (#960)
optout21 May 18, 2020
21ce5a5
Add encode/decode to AnySigner (#962)
hewigovens May 22, 2020
be86114
[BTC] Minor refactoring in fee handling. (#963)
optout21 May 25, 2020
cbbf151
bump ndk version (#968)
hewigovens May 28, 2020
6a4a1bf
TransferTRC20 contract amount is 256 bits (#970)
optout21 May 29, 2020
abe125b
[iOS CI] Add clean to xcodebuild (#971)
hewigovens May 29, 2020
fc01315
Update clang / boost version in Dockerfile (#972)
hewigovens May 31, 2020
03ac911
Enable pay-to-self transactions (#974)
Jun 2, 2020
a6418f2
Added FrontierWallet to Readme (#981)
ravidsrk Jun 8, 2020
06bbce2
[BTC] Fee estimation segwit-compliant, lower and more accurate fees (…
optout21 Jun 9, 2020
1721b74
[Testonly] Extra Cbor tests for coverage. (#983)
optout21 Jun 11, 2020
893977b
add android-release action (#985)
hewigovens Jun 11, 2020
4cc4dac
Migrate iOS build from s3 to release/assets (#986)
hewigovens Jun 12, 2020
0f1de97
NSCAssert will be removed from release (#990)
hewigovens Jun 13, 2020
792e0e8
[Tests] New TWBitcoinAddressTests. (#992)
optout21 Jun 15, 2020
ca75f79
Fixes protobuf related warnings (#995)
hewigovens Jun 17, 2020
0125c0b
[BTC Signing] Do not swallow error in case of missing keys with segwi…
optout21 Jun 17, 2020
51351be
Add BandChain Support (#980)
ravidsrk Jun 17, 2020
6fe0d64
[BTC fee] Fix for no-private-key fee estimation, wrong fee for many U…
optout21 Jun 17, 2020
28299f6
[Decred fee] Use simple estimation for non-segwit coins (#1000)
optout21 Jun 19, 2020
b265f12
Better lock script naming (#1003)
hewigovens Jun 19, 2020
6b59bb7
zip LICENSE for podspec (#991)
hewigovens Jun 19, 2020
4a13a72
Add EthereumAbiDecoder and tests (#1005)
hewigovens Jun 21, 2020
728f2da
Fix compiler warnings. (#1004)
optout21 Jun 21, 2020
2e86f86
Remove unneeded warning flags (#1006)
optout21 Jun 22, 2020
a1689f8
[TestOnly] TWData and TWBase58 tests (#1007)
optout21 Jun 22, 2020
95a089c
TWData cleanup: remove hex parsing code, resume parse_hex. (#1010)
optout21 Jun 24, 2020
65e096c
HDWallet tests and code cleanup (#1008)
optout21 Jun 25, 2020
474b39d
[BTC] New hashtype logic (#1016)
optout21 Jun 29, 2020
8d88104
Update PULL_REQUEST_TEMPLATE.md (#1020)
hewigovens Jun 30, 2020
2330f73
Include building of sample apps in CI. (#1017)
optout21 Jul 2, 2020
3b04dfa
Add TWAESPaddingMode and tests (#1022)
hewigovens Jul 2, 2020
4ff8fad
Add swift playground (#1029)
hewigovens Jul 6, 2020
b39e7d7
codegen typescript coin type and protobuf messages (#1024)
hewigovens Jul 7, 2020
88b6e3c
Refresh README (#1033)
optout21 Jul 10, 2020
a89990d
HashTypeForCoin: fix return type to uint32 (#1042)
optout21 Jul 18, 2020
6c4ef5c
Add Filecoin message changes (#1043)
riptl Jul 18, 2020
ea57870
Fix Xcode 12 warnings (#1040)
hewigovens Jul 18, 2020
eddc642
Bump lodash from 4.17.15 to 4.17.19 in /typescript (#1045)
dependabot[bot] Jul 21, 2020
461a011
Eth ABI enocde/decode fix (ParamArray) (#1048)
optout21 Jul 24, 2020
c4401de
[Ethereum] Support decoding contract data / abi (#1044)
hewigovens Jul 25, 2020
c77825b
Add kotlinx.coroutines to test and remove duplicated tests (#1050)
hewigovens Jul 27, 2020
0450f75
Elrond: update signing procedure (#1053)
andreibancioiu Jul 27, 2020
cf8f918
change find_package for ubuntu (#1057)
hewigovens Jul 31, 2020
d87969d
[Polkadot] Update DOT decimals/path/tests (#1052)
hewigovens Aug 3, 2020
cd3f7bc
Add locking to setting up dispatchers. (#1062)
optout21 Aug 5, 2020
fe98234
Changed the token symbol from ERD to eGLD (#1067)
andreibancioiu Aug 10, 2020
8d3100f
Add Binance SmartChain (#1064)
hewigovens Aug 12, 2020
9ec7bcd
[Sample] Add golang signing sample code (#1070)
hewigovens Aug 14, 2020
53e43e4
expose AnyAddress near public key (#1075)
hewigovens Aug 20, 2020
27f52cd
near coin define updates (#1076)
hewigovens Aug 22, 2020
158bbca
[Aion] remove hardcoded timestamp (#1078)
hewigovens Aug 24, 2020
bcdea5a
[WIP] Android CI build speedup (#1072)
optout21 Aug 25, 2020
3e30661
Update Binance Smart Chain name and explorer (#1083)
hewigovens Aug 28, 2020
ae3d541
Update mainnet chain id (#1084)
hewigovens Aug 31, 2020
6fb0317
Frontier Wallet is now Frontier (#1085)
philiparthurmoore Aug 31, 2020
61c55bf
Update bsc display name again (#1086)
hewigovens Sep 1, 2020
a00c16b
Set typescript package release tag (#1090)
hewigovens Sep 4, 2020
7a8d1c1
Change smart chain derivation path (#1101)
hewigovens Sep 9, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
6 changes: 6 additions & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# These owners will be the default owners for everything in
# the repo. Unless a later match takes precedence,
# @global-owner1 and @global-owner2 will be requested for
# review when someone opens a pull request.

* @hewigovens @catenocrypt
3 changes: 2 additions & 1 deletion .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,5 @@
- [ ] Prefix PR title with `[WIP]` if necessary.
- [ ] Add tests to cover changes as needed.
- [ ] Update documentation as needed.
- [ ] If there is a related Issue, mention it in the description (e.g. 'Fixes #444 ).
- [ ] I have read the [guidelines](https://developer.trustwallet.com/wallet-core/newblockchain#integration-criteria) for adding a new blockchain
- [ ] If there is a related Issue, mention it in the description (e.g. Fixes #<issue_number> ).
40 changes: 40 additions & 0 deletions .github/workflows/android-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Android CI

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
build:

runs-on: macos-10.15

steps:
- uses: actions/checkout@v2
- name: Install system dependencies
run: brew install boost ninja
- name: Install Android Dependencies
run: |
$ANDROID_HOME/tools/bin/sdkmanager --verbose "cmake;3.10.2.4988404" "ndk;21.2.6472646"
$ANDROID_HOME/tools/bin/sdkmanager "system-images;android-26;google_apis;x86"
- name: Accept Licenses
run: echo -e "y\ny\ny\ny\ny\n" | $ANDROID_HOME/tools/bin/sdkmanager --licenses
- name: Cache internal dependencies
id: internal_cache
uses: actions/[email protected]
with:
path: build/local
key: ${{ runner.os }}-internal-${{ hashFiles('tools/install-dependencies') }}
- name: Install internal dependencies
run: |
tools/install-dependencies
if: steps.internal_cache.outputs.cache-hit != 'true'
- name: Run test
run: |
tools/generate-files
tools/android-test
- name: Build sample app
run: |
tools/samples-build android
41 changes: 41 additions & 0 deletions .github/workflows/android-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Android Release

on:
push:
tags:
- '*'
pull_request:
tags:
- '*'

jobs:
release:
runs-on: macos-10.15
steps:
- uses: actions/checkout@v2
- name: Install system dependencies
run: brew install boost ninja
- name: Install Android Dependencies
run: |
$ANDROID_HOME/tools/bin/sdkmanager --verbose "cmake;3.10.2.4988404" "ndk;21.2.6472646"
$ANDROID_HOME/tools/bin/sdkmanager "system-images;android-26;google_apis;x86"
- name: Accept Licenses
run: echo -e "y\ny\ny\ny\ny\n" | $ANDROID_HOME/tools/bin/sdkmanager --licenses
- name: Cache internal dependencies
id: internal_cache
uses: actions/[email protected]
with:
path: build/local
key: ${{ runner.os }}-internal-${{ hashFiles('tools/install-dependencies') }}
- name: Install internal dependencies
run: |
tools/install-dependencies
if: steps.internal_cache.outputs.cache-hit != 'true'
- name: Generate files
run: tools/generate-files
- name: Upload to maven
run: |
tools/maven-android-upload
env:
BINTRAY_KEY: ${{ secrets.BINTRAY_API_KEY }}
BINTRAY_USER: ${{ secrets.BINTRAY_USER }}
30 changes: 30 additions & 0 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Docker CI

on:
push:
branches: [ master ]
paths:
- Dockerfile
- tools/install-dependencies
pull_request:
branches: [ master ]
paths:
- Dockerfile
- tools/install-dependencies

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Lint Dockerfile
run: |
curl -L https://github.com/hadolint/hadolint/releases/download/v1.17.6/hadolint-Linux-x86_64 -o hadolint && chmod +x hadolint
./hadolint Dockerfile

- name: Build Dockerfile
uses: docker/[email protected]
with:
repository: trustwallet/wallet-core
tags: latest
push: false
35 changes: 35 additions & 0 deletions .github/workflows/ios-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: iOS CI

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
build:
runs-on: macos-10.15
steps:
- uses: actions/checkout@v2
- name: Install system dependencies
run: |
brew install boost ninja xcodegen
- name: Cache internal dependencies
id: internal_cache
uses: actions/[email protected]
with:
path: build/local
key: ${{ runner.os }}-internal-${{ hashFiles('tools/install-dependencies') }}
- name: Install internal dependencies
run: |
tools/install-dependencies
if: steps.internal_cache.outputs.cache-hit != 'true'
- name: Run codegen tests
run: tools/codegen-test
- name: Run iOS tests
run: |
tools/generate-files
tools/ios-test
- name: Build sample app
run: |
tools/samples-build ios
37 changes: 37 additions & 0 deletions .github/workflows/ios-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: iOS Release

on:
push:
tags:
- '*'
pull_request:
tags:
- '*'

jobs:
release:
runs-on: macos-10.15
steps:
- uses: actions/checkout@v2
- name: Install system dependencies
run: |
brew install boost ninja xcodegen
- name: Cache internal dependencies
id: internal_cache
uses: actions/[email protected]
with:
path: build/local
key: ${{ runner.os }}-internal-${{ hashFiles('tools/install-dependencies') }}
- name: Install internal dependencies
run: |
tools/install-dependencies
if: steps.internal_cache.outputs.cache-hit != 'true'
- name: Generate files
run: tools/generate-files
- name: Build and release
run: |
tools/ios-release
env:
COCOAPODS_TRUNK_TOKEN: ${{ secrets.COCOAPODS_TRUNK_TOKEN }}
GITHUB_TOKEN: ${{ secrets.WC_GITHUB_TOKEN }}
GITHUB_USER: ${{ secrets.WC_GITHUB_USER }}
46 changes: 46 additions & 0 deletions .github/workflows/linux-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Linux CI

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
build:
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v2
- name: Install system dependencies
run: |
# build-essential libboost-all-dev clang-9 ruby-full cmake
sudo apt-get install libc++-dev libc++abi-dev ninja-build lcov llvm
- name: Cache internal dependencies
id: internal_cache
uses: actions/[email protected]
with:
path: build/local
key: ${{ runner.os }}-internal-${{ hashFiles('tools/install-dependencies') }}
- name: Install internal dependencies
run: |
tools/install-dependencies
env:
CC: /usr/bin/clang
CXX: /usr/bin/clang++
if: steps.internal_cache.outputs.cache-hit != 'true'
- name: Build and test
run: |
tools/generate-files
cmake -H. -Bbuild -DCMAKE_BUILD_TYPE=Debug -DCODE_COVERAGE=ON -DBOOST_ROOT=${BOOST_ROOT_1_72_0}
make -Cbuild -j12 tests TrezorCryptoTests

build/trezor-crypto/tests/TrezorCryptoTests
build/tests/tests tests --gtest_output=xml
env:
CC: /usr/bin/clang
CXX: /usr/bin/clang++
CK_TIMEOUT_MULTIPLIER: 4
- name: Gather code coverage
run: |
sudo rm -rf coverage.info
tools/coverage
25 changes: 25 additions & 0 deletions .github/workflows/ts-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Typescript CI

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [14.x]
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- run: yarn install
working-directory: typescript
- name: Build and test
run: yarn build && yarn test
working-directory: typescript
73 changes: 73 additions & 0 deletions .github/workflows/ts-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
name: Typescript Release

on:
push:
tags:
- '*'
pull_request:
tags:
- '*'

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [14.x]
outputs:
publish_npm: ${{ steps.version.outputs.publish_npm }}
publish_gpr: ${{ steps.version.outputs.publish_gpr }}
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- run: yarn install
working-directory: typescript
- name: Build and test
run: yarn build && yarn test
working-directory: typescript
- name: Check if needed to publish
id: version
run: |
tools/set-tag-version
echo "::set-output name=publish_npm::$(tools/check-npm-version)"
echo "::set-output name=publish_gpr::$(tools/check-gpr-version)"
working-directory: typescript
env:
TOKEN: ${{secrets.GITHUB_TOKEN}}
publish-npm:
needs: build
if: needs.build.outputs.publish_npm == 'true'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 14
registry-url: https://registry.npmjs.org/
- name: Publish
run: |
tools/set-tag-version
yarn install && yarn build && npm publish --access public
working-directory: typescript
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
publish-gpr:
needs: build
if: needs.build.outputs.publish_gpr == 'true'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 14
registry-url: https://npm.pkg.github.com/
- name: Publish
run: |
tools/set-tag-version
yarn install && yarn build && npm publish --access public
working-directory: typescript
env:
NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ lib/protobuf
.idea/
.vscode/
.project
.history/

# Generated files
jni/cpp/generated
Expand All @@ -33,6 +34,7 @@ include/TrustWalletCore/TW*Proto.h
# Code coverage files
coverage.info
coverage/
swift/test_output/

# Sourcetrail
*.srctrldb
Expand Down
3 changes: 3 additions & 0 deletions .hadolint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
ignored:
- DL3008
- DL3015
11 changes: 10 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,11 @@ cmake_minimum_required(VERSION 3.8 FATAL_ERROR)

project(TrustWalletCore)

# Configure warnings
set(TW_CXX_WARNINGS "-Wshorten-64-to-32")
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++ ${TW_CXX_WARNINGS}")
set(CMAKE_EXPORT_COMPILE_COMMANDS 1)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)

Expand All @@ -18,6 +20,13 @@ else()
set(PREFIX "$ENV{PREFIX}")
endif()

# Configure CCache if available
find_program(CCACHE_FOUND ccache)
if(CCACHE_FOUND)
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache)
set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK ccache)
endif(CCACHE_FOUND)

include_directories(${PREFIX}/include)
link_directories(${PREFIX}/lib)

Expand Down
Loading