Features:
- Connection Healthcheck
- Connection healthcheck implementation for peers was introduced. #2194
- Custom Tokens Activation
- Support for enabling custom EVM (ERC20, PLG20, etc..) tokens without requiring them to be in the coins config was added. #2141
- This allows users to interact with any ERC20 token by providing the contract address.
- Support for enabling custom EVM (ERC20, PLG20, etc..) tokens without requiring them to be in the coins config was added. #2141
Enhancements/Fixes:
- Trading Protocol Upgrade #1895
- NFT integration #900
- Graceful Shutdown
- CTRL-C signal handling with graceful shutdown was implemented. #2213
- Seed Management #1939
- A new
get_wallet_names
RPC was added to retrieve information about all wallet names and the currently active one. #2202
- A new
- Cosmos Integration #1432
- Order Management
- Cancel order race condition was addressed using time-based cache. #2232
- Swap Improvements
- A legacy swap issue was resolved where taker spent maker payment transactions were sometimes incorrectly marked as successful when they were actually reverted or not confirmed, particularly in EVM-based swaps. #2199
- Two new events were added: "MakerPaymentSpendConfirmed" and "MakerPaymentSpendConfirmFailed"
- A fix was introduced where Takers don't need to confirm their own payment as they can wait for the spending of it straight away. #2249
- This invalidates this fix #1442, a better solution will be introduced where taker rebroadcasts their transaction if it's not on the chain.
- A fix was introduced for recover funds for takers when the swap was marked as unsuccessful due to the maker payment spend transaction not being confirmed. #2242
- The required confirmations from coin config for taker/maker payment spend are now used instead of using 1 confirmation max. This is because some chains require more than 1 confirmation for finality, e.g. Polygon.
- A legacy swap issue was resolved where taker spent maker payment transactions were sometimes incorrectly marked as successful when they were actually reverted or not confirmed, particularly in EVM-based swaps. #2199
- Swap watchers #1431
- Taker fee validation retries now work the same way as for makers. #2263
- Electrum Client
- Electrum client was refactored to add min/max connection controls, with server priority based on list order. #1966
- Electrum client can now operate in single-server mode (1,1) to reduce resource usage (especially beneficial for mobile) or multi-server (legacy) mode for reliability.
- Higher priority servers automatically replace lower priority ones when reconnecting during periodic retries or when connection count drops below minimum.
- Coins Activation
- EVM addresses are now displayed in full in iguana v2 activation response. #2254
- HD Wallet #1838
- RPC Service
- A fix was introduced to run rpc request futures till completion in #1966
- This ensures RPC request futures complete fully even if clients disconnect, preventing partial state updates and maintaining data consistency.
- A fix was introduced to run rpc request futures till completion in #1966
- Security Enhancements
- Build Process
wasm-opt
overriding was removed. #2200
- Escaped response body in native RPC was removed. #2219
- Creation of the all-zeroes dir on KDF start was stopped. #2218
- OPTIONS requests to KDF server were added. #2191
Removals:
- Solana Support #1085
- Solana implementation was removed until it can be redone using the latest Solana SDK. #2239
- Adex-CLI #1682
- adex-cli was deprecated pending work on a simpler, more maintainable implementation. #2234
Other Changes:
- Documentation
- Code Structure
- lib.rs was replaced by mm2.rs as the root lib for mm2_main. #2178
- Code Improvements
- Tests
- Tendermint IBC tests were fixed by preparing IBC channels inside the container. #2246
.wait()
usage was replaced withblock_on
in tests to ensure consistent runtime usage, fixing issues with tokio TCP streams in non-tokio runtimes. #2220- Debug assertions for tests were enabled. #2204
- More Sepolia test endpoints were added in #2262
NB - Backwards compatibility breaking changes:
- RPC Renaming
get_peers_info
RPC was renamed toget_directly_connected_peers
. #2195
- Cosmos Integration #1432
- Updates to Tendermint activation payloads:
- 'rpc_urls' field (previously a list of plain string values) is replaced with 'nodes' (a list of JSON objects). #2173
- Updates to Tendermint activation payloads:
- Komodo DeFi Proxy
- All RPC methods fields controlling komodo-defi-proxy are renamed to 'komodo_proxy', affecting various activations, including ETH/EVM. #2173
Features:
- Seed Management #1939
- Seed generation, encryption, and storage features were introduced, including a new
get_mnemonic
API. #2014
- Seed generation, encryption, and storage features were introduced, including a new
- A new
sign_raw_transaction
rpc was added for UTXO and EVM coins, this will facilitate air-gapped wallet implementation in the future. #1930
Enhancements/Fixes:
- Event Streaming #1901
- Balance event streaming for Electrum clients was implemented. #2013
- Balance events for UTXOs were introduced.
- Electrum notification receiving bug was fixed.
- Balance event streaming for EVM was added. #2041
- Error events were introduced. #2041
- Heartbeats were introduced to notify about streaming channel health. #2058
- Balance event streaming for ARRR/Pirate was added. #2076
- Balance event streaming for Electrum clients was implemented. #2013
- Trading Protocol Upgrade #1895
- Important note: Seednodes update is needed to support and rebroadcast new swap protocol messages. #2015
- WASM storage for upgraded swaps introduced. #2015
- Migration of old swaps data was added. #2015
- Swaps now automatically kickstart on MM2 reload. #2015
- File lock for swaps added, preventing the same swap from starting in different processes. #2015
my_swap_status
,my_recent_swaps
V2 RPCs introduced. #2015- Upgraded swaps data now accessible through V1 RPCs. #2015
- Locked amount handling for UTXO swaps implemented. #2046
- Conditional wait for maker payment confirmation was added before signing funding tx spend preimage on taker's side. #2046
active_swaps
V2 RPC introduced. #2046- Handling
accept_only_from
for swap messages (validation of the sender) was implemented. #2046 swap_uuid
for swap v2 messages was added to avoid reuse of the messages generated for other swaps. #2046- Maker payment immediate refund path handling was implemented. #2046
- KMD Burn #2010
- KMD dex fee burn for upgraded swaps was added. #2046
- Hardware Wallet #964
- NFT integration #900
- A new
clear_nft_db
RPC for NFT data management was added. This enables selective (based on a chain) or complete NFT DB data clearance. #2039 - NFT can now be enabled using
enable_eth_with_tokens
orenable_nft
, similar toenable_erc20
. #2049 - NFT swaps V2 POC was shown, which includes a NFT maker payment test using the dockerized Geth dev node. #2084
komodo-defi-proxy
support for NFT feature was added. #2100- Additional checks were added for malicious
token_uri
links. #2100 clear_all
parameter inclear_nft_db
RPC is now optional (default:false
). #2100
- A new
- WASM Worker
- Improved environment detection to ensure the correct method is used for accessing the IndexedDB factory, accommodating both window and worker contexts. #1953, #2131
- SharedWorker support was added, allowing any worker path in
event_stream_configuration
with a default toevent_streaming_worker.js
. #2080
- Simple Maker Bot #1065
- IndexedDB
- Swap Stats DB
stats_swaps
table now includes GUI and MM2 version data used for a swap. #2061
- P2P Layer
- Added
max_concurrent_connections
to MM2 config to control the maximum number of concurrent connections for Gossipsub. #2063
- Added
- ARRR/Pirate #927
- EVM Transport
- ETH websocket transport was introduced.
komodo-defi-proxy
signed messages were also supported for websocket transport. #2058
- ETH websocket transport was introduced.
- Tendermint integration #1432
- Nucleus chain support was introduced as an alternative HTLC backend to Iris. #2079
- Tendermint fee calculation was fixed to use
get_receiver_trade_fee
in platform coin. #2106 - Pubkey-only mode for Tendermint protocol was introduced, allowing use of any external wallet for wallet and swap operations. #2088
ibc_withdraw
RPC was removed, andwithdraw
was refactored to support IBC transfers by automatically finding IBC channels. #2088- Transaction history handling was enhanced to support base64 encoded transaction values for Cosmos-based networks, preventing missing transactions in the history table. #2133
- The precision of max amount handling was improved for Tendermint withdraw operations by simulating the transaction and removing the estimated fee. #2155
- Account sequence numbers are now resolved locally, incorrect sequence numbers from cached responses are also avoided. #2164
- HD Wallet #1838
- Full UTXO and EVM HD wallet functionalities were implemented. #1962
- Swap watchers #1431
- UTXO swaps were fixed to apply events that occurred while the taker was offline, such as maker spending or watcher refunding the taker payment. #2114
- Fees Improvements #1848
- EIP-1559 gas fee estimator and RPCs were added for ETH, including priority fee support for withdrawals and swaps, and improved gas limit for swap transactions. #2051
gas_limit
parameter can be used in coins config to override default gas limit values. #2137- Default
gas_limit
values now ensure that Proxied ERC20 tokens have sufficient gas. #2137
- Rust Toolchain #1972
- CI Builds
- MacOS builds for Apple Silicon are now provided through the CI pipeline. #2163
- Miscellaneous
- BCH block header deserialization was fixed to match BTC's handling of
KAWPOW
version headers. #2099 - Implemented root application directory
.kdf
under$HOME
to consolidate all runtime files, enhancing user experience by following standard UNIX practices. #2102 - Memory usage was improved a bit through preallocation optimizations. #2098
- Swaps and orders file handling was enhanced to use
.tmp
files to avoid concurrent reading/writing issues. #2118 - UTXO P2PK balance is now shown as part of the P2PKH/Legacy address balance and can be spent in withdrawals and swaps. #2053
wallet-only
restriction was removed frommax_maker_vol
RPC, enabling its use for wallet-only mode assets. #2153
- BCH block header deserialization was fixed to match BTC's handling of
NB - Backwards compatibility breaking changes:
- Renamed
mm2
binaries tokdf
, while providing backward-compatible copies withmm2
naming; WASM binaries usekdf
naming only, which is a breaking change. #2126
Features:
- KMD Burn #2010
- Burn 25% of taker fee when paid in KMD #2006.
- Trading Protocol Upgrade #1895
- Implement successful swaps v2 of UTXO to UTXO coins in #1958.
- Add Swaps V2 message exchange using Protobuf in #1958.
- Storing upgraded swaps data to SQLite DB was partially implemented in #1980.
- Protocol enhancement for UTXO coins by adding one more funding tx for taker, which can be reclaimed immediately if maker back-outs was implemented in #1980.
- Event Streaming #1901
Enhancements/Fixes:
- Network Enhancements:
- P2P layer now uses the latest stable libp2p version in #1878.
7777
network was deprecated in #2020.- Seednodes for
netid
8762
were updated in #2024. libp2p-yamux
now uses yamuxv0.13
(new version) by default and fall back to yamuxv0.12
(old version) when setting any configuration options in #2030.- The backpressure buffer cap was increased from
25
to256
in #2030. - New protocol version (Version2) was used for peer exchange and request-response behaviours in #2030.
- Network information is now written to stdout to find mm2 ports easily after #2034.
- NFT integration #900
exclude_spam
andexclude_phishing
params were added forget_nft_list
andget_nft_transfers
RPCs in #1959.nft_cache_db
was added inNftCtx
for non wasm targets in #1989.AsyncConnection
structure that can be used as async wrapper for sqlite connection was added in #1989.async_sqlite_connection
field was added toMmCtx
in #1989.- Spam transfers with empty meta no longer update after #1989.
- ARRR/Pirate:
- Adex-CLI #1682
- Storable State Machine abstraction was added while having few changes to existing state machines in #1958.
- EVM web3 requests timeout was reduced to 20s in #1973.
- Fixed 0.0001 min threshold for TakerFee was removed in #1971.
- The minimum trading volume for evm and tendermint was changed to be the smallest possible amount of the coin in #1971.
- Minimum trading price is reduced to be any value above 0 in #1971.
- Cryptocondition script type was added to utxo transactions in #1991.
- On response error the next web3 node is tried in #1998.
- Watchtower taker-side restart bug was fixed in #1908.
- 'version' method was added to
PUBLIC_METHODS
that require no login in #2001. rpcport
value can now accept a string after #2026.- An additional
PRICE_ENDPOINTS
url which is a cached copy ofhttps://prices.komodian.info/api/v2/tickers
and is updated every minute was added in #2032.
NB - Backwards compatibility breaking changes:
7777
Network deprecation and the upgrade to a new p2p layer breaks compatibility with previous versions of Komodo DeFi Framework. Connections between nodes/clients running an older version of Komodo DeFi Framework and nodes/clients running this latest version will not be possible. To avoid this, all nodes/clients must be upgraded to the latest version of Komodo DeFi Framework.- Because of KMD burn of a part of the taker fee, the taker fee outputs for any
coin/KMD
swap are changed and makers running older versions will not be able to validate the taker fee, this will cause the swap to fail. This case will never happen anyway because older versions will not be able to connect to this latest version due to the network upgrade. - Because of the removal of the fixed 0.0001 min threshold for TakerFee, taker fee validation will also fail for these cases. Again, this case will never happen as the previous case.
Features:
- Trading Protocol Upgrade #1895
- HD Wallet #1838
- Global enabling of an account'/change/address_index path for all coins using hd_account_id config parameter was replaced by enable_hd which is a bool that defaults to false in #1933
- path_to_address parameter was added to coins activation requests to set the default account'/change/address_index path that will be used for swaps. If not provided, the default will be 0'/0/0 in #1933
- HD withdrawal from any account'/change/address_index path was implemented for UTXO, EVM and Tendermint coins in #1933
- Pirate Integration #927
- ARRR synchronization now supports using a specific start date. This allows users to specify a specific date as the starting point for synchronization as a substitute for the checkpoint block from config or syncing from the first block #1922
Enhancements/Fixes:
- Adex-CLI #1682
- The file permissions of the cli config file is now set to 660 in unix to disallow reading by other users #1913
- Activation types have been introduced to prevent malicious substitution of them in the activation scheme file #1912
- HTTPS connection support was added in #1910
- Activation scheme was changed so the related data types were refactored to be fit for it in #1938
- PoSV coins withdrawal issue was fixed. The issue was a missing n_time field in the generated transaction. The fix now correctly considers when n_time is required, and the rawtransaction can be broadcasted #1925
- Latest relayer channel is now used for tendermint test #1929
- Price urls were updated in #1928
- NFT transactions that transfer multiple NFT tokens were fixed in db, log_index is now used as part of the transfers history table primary key #1926
- State machine was refactored as a preparation step for StorableStateMachine pattern extension in #1927
- A fix was introduced to use kmd rewards for fees if change + interest is below dust threshold in #1944
- Debug info was removed from release binary to reduce the file size in #1954
- Failing tests due to BCHD were ignored in #1955
Features:
- Komodo DeFi Framework was introduced in #1903
- The project/repo was renamed from AtomicDEX-API to Komodo-DeFi Framework
- The readme file, logo, links, and some references in the documentation were updated to reflect the new name/brand
- CI was updated to use the new name where it's needed.
- Swap watcher nodes #1431
- Using watcher nodes for swaps were enabled by default for UTXO coins in #1859
use_watchers
configuration was set to true by default. It was later disabled in #1897 due to this issue #1887- All nodes doing a swap will broadcast a watcher message after the taker payment is sent if the swapped coins are supported by watchers (currently only UTXO). This was also disabled in #1897 due to this issue #1887
- This update also fixes an issue that caused nodes to broadcast two consecutive watcher messages after the taker payment was sent.
- Using watcher nodes for swaps were enabled by default for UTXO coins in #1859
- NFT integration #900
- Cache support was added for sqlite (non-wasm targets) in #1833
- IndexedDb support for wasm was added in #1877
- DB unit tests were added in #1877
- Handling of
bafy
in IPFS Moralis links in a correct way was done in #1877 get_uri_meta
function was added to optimize the retrieval ofUriMeta
fromtoken_uri
andmetadata
in #1877protect_from_spam
feature was added to redact URLs in specific fields and flag them as possible spam in #1877- Address is now used instead of string in NFT and transaction objects in #1914
guard: Arc<AsyncMutex<()>>
from structNftCtx
is added to lock nft functions which uses db in #1914- IndexedDB Cursor collect method was used to fix uncaught Error in #1914
- HTTPS support was added for the RPC server in #1861
- Adex-CLI #1682
- New commands
enable
,get-enabled
,orderbook
,sell
,buy
were added to adex-cli in #1768
- New commands
Enhancements/Fixes:
- Some RUSTSEC advisories where resolved in #1853
- ARRR/ZCOIN code was refactored to be compiled in WebAssembly (WASM) in #1805
- The PR for this paves the way for subsequent implementation of the empty/todo functions related to WASM storage and other functionalities.
- Orderbook response now returns the right age for the age field, this was fixed in #1851
- A bug that caused
best_orders
rpc to returnis_mine: false
for the user's orders was fixed in #1846- An optional parameter
exclude_mine
was also added to thebest_orders
request that allows users to exclude their own orders from the response. exclude_mine
defaults to false to maintain the same behaviour before the PR.
- An optional parameter
- Watchtower integration tests were moved to the new ethereum testnet and the ignore attributes were removed in #1846
- The PR also adds a new test case for watcher rewards.
- It also fixes the unstable
send_and_refund_eth_payment
,send_and_refund_erc20_payment
,test_nonce_lock
andtest_withdraw_and_send tests
tests that were failing due to concurrency issues.
- Infrastructure DNS rotation for default seednodes was done in #1868
- Price endpoints were updated in #1869
- A fix removed the passed config string from the error logs during mm2 initialization if there was a deserialization error was done in #1872
- The time needed for CI completion was reduced by caching the downloaded dependencies in #1880
- Label validation on PRs was added. This validation will only succeed if one of the following labels is used but not both:
under review
orin progress
#1881 orderbook
mod of adex-cli was refactored by moving it from the internalresponse_handler
to its appropriate folder, enhancing code organization and clarity in #1879- A bug was fixed for adex-cli to allow starting if configuration does not exist in #1889
- IBC and standard withdrawals for Cosmos now allow users to specify the gas price and gas limit for each transaction #1894
- A fix was introduced to adex-cli to allow starting mm2 from cli under regular user in macOS #1856
- The repo logo was updated to be visible in GitHub light theme in #1904
- A CI job was added to check if mm2 version was bumped before merging any pull request to main in #1899
- All CI tests now run with the
--no-fail-fast
flag, allowing other tests to proceed despite any failures #1907 - Index out of bounds errors in the
tx_details_by_hash
functions was fixed in #1915 - Adex-CLI
test_activation_scheme
was fixed by removing the old file in #1920
Features:
- NFT integration #900
- UriMeta was added to get info from token uri, status and metadata in nft tx history #1823
Enhancements/Fixes:
- Deprecated
wasm-timer
dependency was removed from mm2 tree #1836 log
,getrandom
andwasm-bindgen
dependencies were updated to more recent versions that are inline with the latest libp2p upstream #1837- A CI lint pipeline was added that validates pull request titles to ensure that they comply with the conventional commit specifications #1839
- KMD AUR were reduced from 5% to 0.01% starting at
nS7HardforkHeight
to comply with KIP-0001 #1841
Features:
Enhancements/Fixes:
- Some enhancements were done for
enable_bch_with_tokens
,enable_eth_with_tokens
,enable_tendermint_with_assets
RPCs in #1762- A new parameter
get_balances
was added to the above methods requests, when this parameter is set tofalse
, balances will not be returned in the response. The default value for this parameter istrue
to ensure backward compatibility. - Token balances requests are now performed concurrently for the above methods.
- A new parameter
- Swap watcher nodes #1750
- PoC for ETH/UTXO and ERC20/UTXO swaps with rewards
- Improved protocol to let only the taker pay the reward
- Add passive parent coin state for keeping tokens active when platform is disabled #1763
- Optimize release compilation profile for mm2 #1821
- CI flows for
adex-cli
added #1818 - Detect a chain reorganization, if it occurs, redownload and revalidate the new best chain headers for SPV #1728
- Fix moralis request in wasm target, add moralis tests #1817
- PoSV support for UTXO coins was added in #1815
- Use a new testnet for ETH tests, reduce the amount of ETH and ERC20 tokens exchanged, use fixed addresses instead of one-time use random addresses, fix some existing bugs (#1828)
Features:
Enhancements/Fixes:
- cosmos/iris ethermint account compatibility implemented #1765
- p2p stack is improved #1755
- Validate topics if they are mixed or not.
- Do early return if the message data is not valid (since no point to iterate over and over on the invalid message)
- Break the loop right after processing any of
SWAP_PREFIX
,WATCHER_PREFIX
,TX_HELPER_PREFIX
topic.
- An issue was fixed where we don't have to wait for all EVM nodes to sync the latest account nonce #1757
- optimized dev and release compilation profiles and removed ci #1759
- fix receiver trade fee for cosmos swaps #1767
- All features were enabled to be checked under x86-64 code lint CI step with
--all-features
option #1760 - use OS generated secrets for cryptographically secure randomness in
maker_swap
andtendermint_coin::get_sender_trade_fee_for_denom
#1753
Features:
adex-cli
command line utility was introduced that supplies commands:init
,start
,stop
,status
#1729
Enhancements/Fixes:
- CI/CD workflow logics are improved #1736
- Project root is simplified/refactored #1738
- Created base image to provide more glibc compatible pre-built binaries for linux #1741
- Set default log level as "info" #1747
- Refactor
native_log
module #1751- implement stdout/err streaming to persistent file without dependencies
- Add new parameter
silent_console
to mm conf
Features:
- NFT integration
WIP
#900 - Swap watcher nodes #1431
- Watcher rewards for ETH swaps were added #1658
- Cosmos integration
WIP
#1432ibc_withdraw
,ibc_chains
andibc_transfer_channels
RPC methods were added #1636
- Lightning integration
WIP
#1045- rust-lightning was updated to v0.0.113 in #1655
- Channel
current_confirmations
andrequired_confirmations
were added to channel details RPCs in #1655 Uuid
is now used for internal channel id instead ofu64
#1655- Some unit tests were added for multi path payments in #1655
- Some unit tests for claiming swaps on-chain for closed channels were added in #1655, these unit tests are currently failing.
protocol_info
fields are now used to check if a lightning order can be matched or not in #1655- 2 issues discovered while executing a KMD/LNBTC swap were fixed in #1655, these issues were:
- When electrums were down, if a channel was closed, the channel closing transaction wasn't broadcasted. A check for a network error to rebroadcast the tx after a delay was added.
- If an invoice payment failed, retring paying the same invoice would cause the payment to not be updated to successful in the DB even if it were successful. A method to update the payment in the DB was added to fix this.
mm2_git
crate was added to provide an abstraction layer on Git for doing query/parse operations over the repositories #1636
Enhancements/Fixes:
- Use
env_logger
to achieve flexible log filtering #1725 - IndexedDB Cursor can now iterate over the items step-by-step #1678
- Uuid lib was update from v0.7.4 to v1.2.2 in #1655
- A bug was fixed in #1706 where EVM swap transactions were failing if sent before the approval transaction confirmation.
- Tendermint account sequence problem due to running multiple instances were fixed in #1694
- Maker/taker pubkeys were added to new columns in
stats_swaps
table in #1665 and #1717 - Get rid of unnecessary / old dependencies:
crossterm
,crossterm_winapi
,mio 0.7.13
,miow
,ntapi
,signal-hook
,signal-hook-mio
in #1710 - A bug that caused EVM swap payments validation to fail because the tx was not available yet in the RPC node when calling
eth_getTransactionByHash
was fixed in #1716.eth_getTransactionByHash
in now retried inwait_for_confirmations
until tx is found in the RPC node, this makes sure that the transaction is returned frometh_getTransactionByHash
later when validating. - CI/CD migrated from Azure to Github runners #1699
- CI tests are much stabilized #1699
- Integration and unit tests are seperated on CI stack #1699
- Codebase is updated in linting rules at wasm and test stack #1699
crossbeam
bumped to0.8
from0.7
#1699- Un-used/Unstable parts of mm2 excluded from build outputs which avoids mm2 runtime from potential UB #1699
- Build time optimizations applied such as sharing generics instead of duplicating them in binary (which reduces output sizes) #1699
RUSTSEC-2020-0036
,RUSTSEC-2021-0139
andRUSTSEC-2023-0018
resolved #1699- Enabled linting checks for wasm and test stack on CI #1699
- Release container base image updated to debian stable from ubuntu bionic #1699
- Fix dylib linking error of rusb #1699
OperationFailure::Other
error was expanded. New error variants were matched withHwRpcError
, so error type will beHwError
, notInternalError
#1719- RPC calls for evm chains was reduced in
wait_for_confirmations
function in #1724 - A possible endless loop in evm
wait_for_htlc_tx_spend
was fixed in #1724 - Wait time for taker fee validation was increased from 30 to 60 seconds in #1730 to give the fee tx more time to appear in most nodes mempools.
Features:
- ARRR integration #927:
- Tendermint integration #1432
- HD Wallet #740
- Hardware Wallet #964
- Implement TX history V2 for UTXO coins activated with a Hardware wallet #1467
- Fix KMD withdraw with Trezor #1628
task::get_new_address::*
RPCs were added to replace the legacyget_new_address
RPC #1672trezor_connection_status
RPC was added to allow the GUI to poll the Trezor connection status #1672
- Simple Payment Verification #1612
- New RPCs
- Lightning integration
WIP
#1045- rust-lightning was updated to v0.0.110 in #1452
- Inbound channels details was added to SQL channels history in #1339
- Blocking was fixed for sync rust-lightning functions that calls other I/O functions or that has mutexes that can be held for some time in #1452
- Default fees are retrieved from rpc instead of config when starting lightning #1452
- 0 confirmations channels feature was added in #1452
- An
update_channel
RPC was added that updates a channel that is open without closing it in #1452 - Lightning RPCs now use the
lightning::
namespace in #1497 TakerFee
andMakerPayment
swap messages were modified to include payment instructions for the other side, in the case of lightning this payment instructions is a lightning invoice #1497MakerPaymentInstructionsReceived
/TakerPaymentInstructionsReceived
events are added toMakerSwapEvent
/TakerSwapEvent
in #1497, for more info check this comment- Lightning swaps were implemented in #1497, #1557
- Lightning swap refunds were implemented in #1592
MakerPaymentRefundStarted
,TakerPaymentRefundStarted
,MakerPaymentRefundFinished
,TakerPaymentRefundFinished
events were added to swap error events in #1592, for more info check this comment- Enabling lightning now uses the task manager #1513
- Disabling lightning coin or calling
stop
RPC now drops theBackgroundProcessor
which persists the latest network graph and scorer to disk #1513, #1490 avg_blocktime
from platform/utxo coin is used for l2/lightning estimating of the number of blocks swap payments are locked for #1606
- MetaMask
WIP
#1167- Login with a MetaMask wallet #1551
- Check if corresponding ETH chain is known by MetaMask wallet on coin activation using
wallet_switchEthereumChain
#1674 - Refactor ETH/ERC20 withdraw taking into account that the only way to sign a transaction is to send it using
eth_sendTransaction
#1674 - Extract address's public key using
eth_singTypedDataV4
#1674 - Perform swaps with coins activated with MetaMask #1674
Enhancements/Fixes:
- Update
rust-web3
crate #1674 - Custom enum from stringify derive macro to derive From implementations for enums #1502
- Validate that
input_tx
is calling'receiverSpend'
ineth::extract_secret
#1596 - Validate all Swap parameters at the Negotiation stage #1475
- created safe number type castings #1517
- Improve
stop
functionality #1490 - A possible seednode p2p thread panicking attack due to
GetKnownPeers
msg was fixed in #1445 - NAV
cold_staking
script type was added to fix a problem in NAV tx history in #1466 - SPV was temporarily disabled in WASM in #1479
BTC-segwit
swap locktimes was fixed in #1548 by using orderbook ticker instead of ticker in swap locktimes calculations.- BTC block headers deserialization was fixed for version 4 and
KAWPOW_VERSION
in #1452 - Error messages for failing swaps due to a time difference between maker and taker are now more informative after #1677
- Fix
LBC
block header deserialization bug #1343 - Fix
NMC
block header deserialization bug #1409 - Refactor mm2 error handling for some structures #1444
- Tx wait for confirmation timeout fix #1446
- Retry tx wait confirmation if not on chain #1474
- Fix electrum "response is too large (over 2M bytes)" error for block header download #1506
- Deactivate tokens with platform coin #1525
- Enhanced logging in
spv
andrpc_client
mods #1594 - Update metrics related dep && refactoring #1312
- Fix rick and morty genesis block deserialization #1647
- In
librustzcash
bumpedbech32
to0.9.1
(which we already have in mm2, so we will not have 2 versions ofbech32
) - Use dev branch as a target branch for Dependabot #1424
- Fixed Zhtlc orders is_mine bug (orders had "is_mine":false) #1489
- Grouped SwapOps method arguments into new groups(structures) #1529
- Handling multiple rpcs optimization #1480
- Solana tests are disabled #1660
- Some of vulnerable dependencies(tokio, libp2p) are fixed #1666
- Add
mm2_stop
WASM FFI #1628 - Use
futures_timer
crate and fix some unstable tests #1511 - Fix
Timer::sleep_ms
in WASM #1514 - Fix a race condition in
AbortableQueue
#1528 - Spawn
process_json_request
so the RPC requests can be processed asynchronously #1620 - Fix
task::-::cancel
if the RPC task is an awaiting status #1582 disable_coin
should fail if there are tokens dependent on the platform #1651- Implement a repeatable future #1564
- Version handling was enhanced #1686
- Version of
mm2_bin_lib
from cargo manifest is now used for the API version --version
,-v
,version
arguments now print the mm2 version
- Version of
- Workflow for VirusTotal results was added to CI #1676
parity-ethereum
andtestcontainers-rs
crates from KomodoPlatform repo are now used #1690- Testnet node of atom was updated, RUSTSEC-2023-0018 was ignored #1692
- Timestamp value sent from the peer in
PubkeyKeepAlive
msg was ignored and the received timestamp was used instead #1668 - Change release branch from mm2.1 to main in CI #1697
- CHANGELOG.md was introduced to have a complete log of code changes #1680
- Small fixes #1518, #1515, #1550, #1657
NB - Backwards compatibility breaking changes:
- Because of #1548, old nodes will not be able to swap BTC segwit with new nodes since locktimes are exchanged and validated in the negotiation messages.