Louis Singer ff96524f22 Ark Notes (#379)
* ark credits

* rename "ecash" --> "ark credit"

* rework note_test.go

* NewFromString

* create several notes

* note repo: rename "push" to "add"

* RegisterInputsForNextRoundRequest: move "notes" to field #3

* use uint64 as note ID

* rename to voucher

* add nostr notification

* nostr notification test and fixes

* bump badger to 4.3

* allow npub to be registered

* rename poolTxID

* add default relays

* Update server/internal/config/config.go

Co-authored-by: Marco Argentieri <3596602+tiero@users.noreply.github.com>

* fix RedeemVouchers test

* notification = voucher

* WASM wrappers

* fix arkd voucher cmd

* test_utils.go ignore gosec rule G101

* fix permissions

* rename ALL to notes

* add URI prefix

* note.go : fix signature encoding

* fix decode note.Data

* Update server/internal/infrastructure/notifier/nostr/nostr.go

Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com>

* Update pkg/client-sdk/wasm/browser/wrappers.go

Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com>

* Update server/internal/infrastructure/notifier/nostr/nostr.go

Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com>

* rework note and entity db + sqlite implementations

* NOTIFICATION_PREFIX -> NOTE_URI_PREFIX

* validate NOTE_URI_PREFIX

* Update defaults to convenant-less mainnet (#2)

* config: defaults to convenant-less tx builder

* Drop env var for blockchain scanner

---------

Co-authored-by: altafan <18440657+altafan@users.noreply.github.com>

* add // before URI prefix

* add URI prefix in admin CreateNote

* Fixes

* rework nonces encoding (#4)

* rework nonces encoding

* add a check in Musig2Nonce decode function

* musig2_test: increase number of signers to 20

* musig2.json: add a test case with a 35 leaves tree

* GetEventStream REST rework

* fix round phases time intervals

* [SDK] Use server-side streams in rest client

* Fix history

* make the URI optional

* Updates

* Fix settled txs in history

* fix e2e test

* go work sync in sdk unit test

* fix signMessage in btc and liquid sdk wallets

---------

Co-authored-by: Marco Argentieri <3596602+tiero@users.noreply.github.com>
Co-authored-by: Pietralberto Mazza <18440657+altafan@users.noreply.github.com>
2024-11-15 19:07:33 +01:00
2024-11-15 19:07:33 +01:00
2024-11-15 19:07:33 +01:00
2024-11-15 19:07:33 +01:00
2024-11-15 19:07:33 +01:00
2024-11-15 19:07:33 +01:00
2024-11-15 19:07:33 +01:00
2024-03-05 14:25:53 +01:00
2024-09-16 15:40:10 +02:00
2024-11-15 19:07:33 +01:00
2024-06-03 19:29:56 +02:00
2024-11-15 19:07:33 +01:00
2024-10-26 01:51:40 +02:00
2024-08-09 01:15:16 +02:00

Ark

GitHub release (latest by date) Docker Image Integration ci_unit GitHub Go Reference

Welcome to the Ark monorepo, a comprehensive solution for off-chain Bitcoin transactions.

Ark logo

⚠️ IMPORTANT DISCLAIMER: ALPHA SOFTWARE Ark is currently in alpha stage. This software is experimental and under active development. DO NOT ATTEMPT TO USE IN PRODUCTION. Use at your own risk.

Supported Networks and Wallets

Covenant-less Covenant
Network Bitcoin signet, Bitcoin regtest Liquid, Liquid testnet, Liquid regtest
Wallet Embedded lnwallet Ocean wallet

Usage Documentation

For a comprehensive guide on how to set up and use Ark, please visit our Developer Portal. For a quick-start with Docker, head over to our Quick Start guide where you can setup an Ark Server and Clients in a local Bitcoin regtest network.

Repository Structure

  • api-spec: Ark Protocol Buffer API specification
  • client: ark Single-key wallet CLI for interacting with the ASP
  • common: Shared code between the server and client
  • pkg/client-sdk: Go SDK for interacting with ASPs running the Ark protocol. It offers WASM bindings to interact with the SDK from the browser and other environments.
  • server: arkd Ark Service Provider (ASP) - the always-on daemon

Development

For detailed development instructions, including running tests, and contributing to the implementations, please refer to the README files in the server and client directories.

Compile binary from source

To compile Ark binaries from source, you can use the following Make commands from the root of the monorepo:

  • make build-server: Builds the arkd binary (Ark Service Provider)
  • make build-client: Builds the ark binary (Single-key wallet CLI)
  • make build-wasm: Builds the WebAssembly bindings
  • make build: Builds all components for the current architecture (server, client, and WebAssembly SDK)
  • make build-all: Cross-compile all components for all supported architectures

For example, to build both the server and client binaries, run:

make build

This will compile the arkd and ark binaries for your current architecture. For more detailed build instructions and options, please refer to the README files in the server and client directories.

Contributing Guidelines

  1. No force pushing in PRs: Always use git push --force-with-lease to avoid overwriting others' work.
  2. Sign your commits: Use GPG to sign your commits for verification.
  3. Squash and merge: When merging PRs, use the "Squash and merge" option to maintain a clean commit history.
  4. Testing: Add tests for each new major feature or bug fix.
  5. Keep master green: The master branch should always be in a passing state. All tests must pass before merging.

Local Development Setup

  1. Install Go (version 1.18 or later)

  2. Install Nigiri for local Bitcoin and Liquid networks

  3. Clone this repository:

    git clone https://github.com/ark-network/ark.git
    cd ark
    
  4. Install dependencies:

    go work sync
    
  5. Build the project:

    cd server
    make build
    cd ../client
    make build
    

Note: You need to run make build in both the server and client directories separately.

Support

If you encounter any issues or have questions, please file an issue on our GitHub Issues page.

Security

We take the security of Ark seriously. If you discover a security vulnerability, we appreciate your responsible disclosure.

Currently, we do not have an official bug bounty program. However, we value the efforts of security researchers and will consider offering appropriate compensation for significant, responsibly disclosed vulnerabilities.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Description
No description provided
Readme MIT 13 MiB
Languages
Go 97.9%
HTML 1.1%
Makefile 0.5%
Shell 0.3%
Dockerfile 0.2%