Louis Singer
10ef0dbffa
Add reversible policy to pending vtxos ( #311 )
...
* [server] descriptor-based vtxo script
* [server] fix unit tests
* [sdk] descriptor based vtxo
* empty config check & version flag support
* fix: empty config check & version flag support (#309 )
* fix
* [sdk] several fixes
* [sdk][server] several fixes
* [common][sdk] add reversible VtxoScript type, use it in async payment
* [common] improve parser
* [common] fix reversible vtxo parser
* [sdk] remove logs
* fix forfeit map
* remove debug log
* [sdk] do not allow reversible vtxo script in case of self-transfer
* remove signing pubkey
* remove signer public key, craft forfeit txs client side
* go work sync
* fix linter errors
* rename MakeForfeitTxs to BuildForfeitTxs
* fix conflicts
* fix tests
* comment VtxoScript type
* revert ROUND_INTERVAL value
---------
Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com >
Co-authored-by: sekulicd <sekula87@gmail.com >
2024-09-19 10:01:33 +02:00
Dusan Sekulic
7a83f9957e
[CLI] Fix init checks ( #314 )
...
* empty config check & version flag support
* fix: empty config check & version flag support (#309 )
* fix
* cli init check
Prevent execution without initialization by checking cfgData and returning error if not initialized
* merge with master
* Replace errors.New with fmt.Errorf
Signed-off-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com >
---------
Signed-off-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com >
Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com >
2024-09-17 15:42:09 +02:00
João Bordalo
0fe52386e8
[SDK] Add RoundInterval to StoreData ( #283 )
...
Co-authored-by: altafan <18440657+altafan@users.noreply.github.com >
2024-09-16 17:26:32 +02:00
Louis Singer
3782793431
Add tests for adversarial scenarios ( #300 )
...
* fix and test cheating scenario (malicious double spend)
* test and fix async vtxo cheating cases
* add replace statement in go.mod
* Update server/internal/core/application/covenantless.go
Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com >
Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com >
* Update server/internal/infrastructure/wallet/btc-embedded/psbt.go
Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com >
Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com >
* Update server/test/e2e/covenant/e2e_test.go
Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com >
Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com >
* Update server/test/e2e/covenantless/e2e_test.go
Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com >
Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com >
* Update server/test/e2e/covenantless/e2e_test.go
Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com >
Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com >
* remove unused
* [btc-embedded] fix GetNotificationChannel
* [tx-builder] fix redeem transaction fee estimator
* close grpc client in tests
* [application] rework listentoscannerNotification
* [application][covenant] fix getConnectorAmount
* [tx-builder][covenant] get connector amount from wallet
* e2e test sleep time
* [liquid-standalone] ListConnectorUtxos: filter by script client side
* fix Makefile integrationtest
* do not use cache in integration tests
* use VtxoKey as argument of findForfeitTxBitcoin
* wrap adversarial test in t.Run
* increaste test timeout
* CI: setup go 1.23.1
* CI: revert go version
* add replace in server/go.mod
* Update server/internal/core/application/covenant.go
Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com >
Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com >
* remove replace
* readd replace statement
* fixes
* go work sync
* fix CI
---------
Signed-off-by: Louis Singer <41042567+louisinger@users.noreply.github.com >
Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com >
2024-09-16 17:03:43 +02:00
Pietralberto Mazza
4c8c5c06ed
Tidy up workspace ( #317 )
...
* go work sync
* Clean go.sum files
2024-09-16 15:40:10 +02:00
altafan
4883e692cd
[Client] Fixes ( #310 )
...
* merge
* fix
* fix: empty config check & version flag support (#309 )
* empty config check & version flag support
2024-09-16 11:26:07 +02:00
João Bordalo
2174e4b04d
[SDK] Add boarding txs to history ( #306 )
...
* test
* Add onboard tx to tx history
Co-authored-by: Pietralberto Mazza <altafan@users.noreply.github.com >
* add createdAt to onboard UTXO
* show unconfirmed on top
* add new method GetTx to explorer
* fix list of onboarding tx
* ignore not pending
* small refactor
* replicate changes on covenant client
* fix tests
---------
Co-authored-by: Pietralberto Mazza <altafan@users.noreply.github.com >
2024-09-13 19:19:21 +02:00
Dusan Sekulic
4304626d08
CLI with ARK Sdk ( #307 )
...
* Export new methods
* Use sdk in CLI
* pr review refactor
* go sync
* Fixes
* run integration test on every change
* fixes
* go sync
* fix
* Persist explorer url
* Fix decoding bitcoin address
* Add missing timeout to e2e test
* Fix
* Fixes
---------
Co-authored-by: altafan <18440657+altafan@users.noreply.github.com >
2024-09-13 19:13:48 +02:00
João Bordalo
f9cf449104
fix: support http as asp url ( #303 )
...
* fix asp url
* replicate fix on covenant client
* upgrade to go 1.23.1
2024-09-12 17:11:37 +01:00
Pietralberto Mazza
9d2e84cc9c
chore: go work sync ( #305 )
2024-09-11 23:03:43 +02:00
Marco Argentieri
ab2c9785d0
chore: disable CodeQL workflow ( #304 )
...
* Create codeql.yml
Signed-off-by: Marco Argentieri <3596602+tiero@users.noreply.github.com >
* Update codeql.yml
Signed-off-by: Marco Argentieri <3596602+tiero@users.noreply.github.com >
---------
Signed-off-by: Marco Argentieri <3596602+tiero@users.noreply.github.com >
2024-09-10 21:51:27 +02:00
Louis Singer
1387c8da7a
CompleteAsyncPayment: validate signatures and transactions ( #298 )
2024-09-10 19:21:54 +02:00
Louis Singer
0fb34cb13d
Dynamic min-relay-fee and dust amount ( #280 )
...
* [btc-embedded] add chainfee.Estimator and extraAPI interfaces
* dynamic fee amount
* dynamic dust amount
* [client] fix linter errors
* [domain] fix unit tests
* [server] return dust amount in GetInfo RPC
* [sdk] fix lnd dependencie
* go work sync
* fix witness stack size forfeit tx size estimator
* remove hardcoded fee values in covenant txbuilder
* lower liquid feerate
* fix after reviews
* go work sync
2024-09-10 17:22:09 +02:00
Dusan Sekulic
a8cf0ed204
[SDK] Add Transaction History ( #288 )
...
* tx history
* fix
* fix
* pr review refactor
* pr review refactor
* fix
* pr review refactor
* exclude gosec G115 Integer Overflow Conversion
* ignore some gosec errs
* ignore some gosec errs
* ignore createdat in test assertion
* Fixes (#7 )
* Fixes
* Fixes
* Update golang (#8 )
* update gha golangci-lint version
* update gha golangci-lint version
* fix linting issues
* fix linting issues
* fix linting issues
* add linter timeout
---------
Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com >
2024-09-10 14:27:29 +02:00
Louis Singer
4da76ec88b
New boarding protocol ( #279 )
...
* [domain] add reverse boarding inputs in Payment struct
* [tx-builder] support reverse boarding script
* [wallet] add GetTransaction
* [api-spec][application] add reverse boarding support in covenantless
* [config] add reverse boarding config
* [api-spec] add ReverseBoardingAddress RPC
* [domain][application] support empty forfeits txs in EndFinalization events
* [tx-builder] optional connector output in round tx
* [btc-embedded] fix getTx and taproot finalizer
* whitelist ReverseBoardingAddress RPC
* [test] add reverse boarding integration test
* [client] support reverse boarding
* [sdk] support reverse boarding
* [e2e] add sleep time after faucet
* [test] run using bitcoin-core RPC
* [tx-builder] fix GetSweepInput
* [application][tx-builder] support reverse onboarding in covenant
* [cli] support reverse onboarding in covenant CLI
* [test] rework integration tests
* [sdk] remove onchain wallet, replace by onboarding address
* remove old onboarding protocols
* [sdk] Fix RegisterPayment
* [e2e] add more funds to covenant ASP
* [e2e] add sleeping time
* several fixes
* descriptor boarding
* remove boarding delay from info
* [sdk] implement descriptor boarding
* go mod tidy
* fixes and revert error msgs
* move descriptor pkg to common
* add replace in go.mod
* [sdk] fix unit tests
* rename DescriptorInput --> BoardingInput
* genrest in SDK
* remove boarding input from domain
* remove all "reverse boarding"
* rename "onboarding" ==> "boarding"
* remove outdate payment unit test
* use tmpfs docker volument for compose testing files
* several fixes
2024-09-04 19:21:26 +02:00
João Bordalo
8cba9c9d42
Merge pull request #293 from ark-network/fix_typo
...
fix typo and spacing
2024-09-04 17:27:01 +01:00
João Bordalo
8d339cd3e7
fix typo and spacing
2024-09-04 17:24:26 +01:00
Pietralberto Mazza
b5e1ea4d57
Add SpentBy field to client.Vtxo ( #285 )
2024-09-02 23:24:12 +02:00
Pietralberto Mazza
e46f2ce392
[SDK] Export ListVtxos ( #282 )
2024-08-30 17:30:47 +02:00
Louis Singer
c183f99244
Make the round participants sign the vtxo tree ( #271 )
...
* [proto] add APIs to send and receive musig2 signing data
* [common] add serialization functions for nonces and signatures
* [application] implements tree signing
* fix: remove old debug logs
* [proto] cleaning
* [common] fix musig2.go
* [application] fixes and logs
* [interface] fix: stop forwarding 2 times the events
* [client] add musig2 support + sign the tree when joining a round
* [interface] add new APIs into permissions.go
* [application][proto] rework PingResponse (return all events type)
* [common] split SetKeys into 2 distinct methods
* [client] fixes according to musig2.go changes
* [sdk] support tree signing + new PingResponse
* [sdk] fixes
* [application] revert event channel type
* [application] use domain.RoundEvent as lastEvent type
* [application] remove IsCovenantLess
* comments
* [application] revert roundAborted changes
* [interface] remove bitcointree dependencie
2024-08-30 14:32:35 +02:00
Marco Argentieri
1b9660ec89
gha: add trivy security scan ( #277 )
2024-08-23 16:08:40 +02:00
Marco Argentieri
1f8cdcc770
fix: upgrade alpine:3.18 for zlib CVE-2022-37434 ( #276 )
2024-08-23 15:56:31 +02:00
João Bordalo
2ffc478f38
Merge pull request #275 from louisinger/fix-covenantless-round-tx-witnessutxo
...
fix: AddInWitnessUtxo in covenantless `txBuilder`
2024-08-23 11:54:05 +01:00
louisinger
4ddbcd1fd1
hotfix AddInWitnessUtxo in txBuilder
2024-08-23 12:30:27 +02:00
Marco Argentieri
a84195ffb5
fix: README.md broken link quick start guide ( #270 )
...
Signed-off-by: Marco Argentieri <3596602+tiero@users.noreply.github.com >
2024-08-21 16:53:14 +02:00
Marco Argentieri
0fb8076c6e
check go work sync in unit test ( #268 )
...
* check go work sync is ran
* bump setup-go@v4
* remove go mod tidy
2024-08-20 11:22:59 +02:00
Dusan Sekulic
07139786e6
IsInitialized > walletLoaded & panic recovery ( #266 )
...
* isInitialized update
update walletInitialized to return true is walled.db exist,
add walletLoaded that check if wallet property is nil
* panic handler
2024-08-19 18:57:52 +02:00
Louis Singer
250dd7eea2
[server] fix unexpected panics when the wallet is not initialized ( #264 )
2024-08-19 13:44:05 +02:00
Louis Singer
7c31942386
move make proto & make proto-lint commands to root folder ( #265 )
...
* fix make proto
* cleaning
2024-08-17 00:08:21 +02:00
Marco Argentieri
6e7fff9096
client-sdk: bump api-spec and common to latest ( #261 )
2024-08-16 01:41:01 +02:00
Marco Argentieri
edc4534dfc
chore: remove extra } in Dockerfile ( #258 )
...
Signed-off-by: Marco Argentieri <3596602+tiero@users.noreply.github.com >
2024-08-15 22:30:29 +02:00
Marco Argentieri
94cd222004
wallet: bitcoind support with RPC polling ( #254 )
...
* support bitcoind connection
* fix: wallet should be the varibale, not s.wallet
* block cache: up to 2M blocks
* WithBitcoind wait for sync
* WithBitcoind rename
* switch based on the ENV VARs
* Add make targets
2024-08-15 20:02:11 +02:00
Marco Argentieri
c840aac431
build parallel ( #257 )
2024-08-15 18:58:37 +02:00
Marco Argentieri
faecf1a392
gha release: split docker and binaries. tag name as VERSION in build-arg ( #256 )
...
* client: print version
* arkd: add --version
* release action refactor
2024-08-15 04:52:04 +02:00
Marco Argentieri
6ce090bf53
add flag --version ( #255 )
...
* client: print version
* arkd: add --version
2024-08-15 03:51:16 +02:00
Marco Argentieri
62ea14ddb5
arkd: support signet ( #251 )
...
* pass MutinyNet parameters
* set signetblocktime=30
* supports signet in client and sdk
* ark: --network help message to support signet
* revert intialPeers set
2024-08-15 02:25:13 +02:00
Marco Argentieri
0672ad6d53
fix: wallet should be the varibale, not s.wallet ( #252 )
2024-08-15 00:58:42 +02:00
Marco Argentieri
2e6fa7fe6d
pkg/client-sdk: expose IsLocked ( #247 )
...
* expose IsLocked
* add test for IsLocked
2024-08-14 14:07:15 +02:00
Marco Argentieri
e79819cca8
arkd: migrate to 7070 as default port ( #246 )
2024-08-13 18:17:57 +02:00
Marco Argentieri
cfb6f9ec41
wasm: export browser package already initialized and cleanup to example ( #245 )
...
* refactor sdk wasm
* remove example go.mod
* go work sync
* revert default port change
2024-08-13 16:13:09 +02:00
Marco Argentieri
1b0252f3e4
Migrate to Go Workspaces ( #243 )
...
* api-spec: move the api-spec to root and init go.mod
* go mod tidy
* move buf files in the root as well
* gh action for api-spec changes only
* gh action for api-spec on push and pr
* introduce go.work and remove all replaces
* solve dependencies and force btcd/btcec@v2.3.3
* go work sync
* force btcd/btcec@v2.3.3
* go mod tidy
2024-08-13 03:27:41 +02:00
Marco Argentieri
f0a90c06ee
Move api-spec to root folder ( #242 )
...
* api-spec: move the api-spec to root and init go.mod
* go mod tidy
* move buf files in the root as well
* gh action for api-spec changes only
* gh action for api-spec on push and pr
2024-08-13 00:54:06 +02:00
Marco Argentieri
67baf9e7fc
client-sdk/wasm: binary rename to ark-sdk.wasm ( #241 )
2024-08-13 00:30:44 +02:00
Marco Argentieri
a8077f143d
change order sections of the README ( #240 )
2024-08-13 00:30:33 +02:00
Marco Argentieri
c559b91fec
pkg/client-sdk/wasm: build wasm ( #238 )
...
Signed-off-by: tiero <3596602+tiero@users.noreply.github.com >
2024-08-12 16:40:27 +02:00
Pietralberto Mazza
72a7f29bab
Add CreatePayment and CompletePayment ( #229 )
...
Co-authored-by: Marco Argentieri <tiero@users.noreply.github.com >
* Add claim command
* Persist pending data in sqlite repo
* Remove debug log
* Return pending data at interface level
* Fix unlocking btc wallet after restart
* Lint & Fix whitelist permissions
* Fix send command for covenant
* Update client/covenantless/claim.go
Signed-off-by: Marco Argentieri <3596602+tiero@users.noreply.github.com >
* Fix
* Pay for min relay fee instead of estimating fees for redeem and unconf forfeit txs
* Add support for pending payments (coventanless)
* Fixes
* Fixes
* Improve verbosity
* Fix coin selection
* Fix
---------
Signed-off-by: Marco Argentieri <3596602+tiero@users.noreply.github.com >
Co-authored-by: louisinger <louis@vulpem.com >
Co-authored-by: Marco Argentieri <tiero@users.noreply.github.com >
Co-authored-by: Marco Argentieri <3596602+tiero@users.noreply.github.com >
2024-08-10 19:18:02 +02:00
Pietralberto Mazza
57ce08f239
Support macaroons and TLS && Add arkd wallet cmds ( #232 )
...
* Update protos
* Update handlers
* Support macaroons and TLS
* Add arkd cli
* Minor fixes
* Update deps
* Fixes
* Update makefile
* Fixes
* Fix
* Fix
* Fix
* Remove trusted onboarding from client
* Completely remove trusted onboarding
* Fix compose files and add --no-macaroon flag to arkd cli
* Lint
* Remove e2e for trusted onboarding
* Add sleep time
2024-08-09 17:59:31 +02:00
Marco Argentieri
059e837794
Rename ark-sdk > ark/pkg/client-sdk ( #236 )
2024-08-09 17:46:42 +02:00
Marco Argentieri
ff28f00730
client: Rename flag ark-url into asp-url ( #234 )
2024-08-09 17:08:17 +02:00
Marco Argentieri
a8ed0bf6a4
Update README.md ( #231 )
...
Signed-off-by: Marco Argentieri <3596602+tiero@users.noreply.github.com >
2024-08-09 11:38:38 +02:00