Method and system for brokered cross-ledger stablecoin atomic swaps using hashlocks

An intermediary processing server facilitates atomic swaps between different blockchain networks by generating hash locks and addresses, addressing the limitations of existing methods and enhancing security and convenience.

JP7620733B2Active Publication Date: 2025-01-23MASTERCARD ASIAPACIFIC PTE LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
JP2023577760
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Priority Date
2021-06-17
Filing Date
2022-06-17
Publication Date
2025-01-23
Estimated Expiration
2042-06-17

AI Technical Summary

Technical Problem

Existing atomic swap methods require both blockchains to use the same hashing methodology, limiting their applicability and exposing users to risks when involving third-party exchanges.

Method used

An intermediary processing server generates hash locks and addresses for atomic swaps, enabling transactions across different blockchain networks without requiring participants to generate their own locks, ensuring secure and independent execution.

Benefits of technology

This approach allows for secure, versatile, and convenient atomic swaps across diverse blockchain networks, eliminating the need for participants to share private keys and simplifying the exchange process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 0007620733000001
    Figure 0007620733000001
  • Figure 0007620733000002
    Figure 0007620733000002
  • Figure 0007620733000003
    Figure 0007620733000003
Patent Text Reader

Abstract

A method for brokering an atomic swap includes receiving a swap request from a first computing device, identifying the second computing device using a network identifier and a second address associated with a second blockchain, generating a proof value and a hash lock using the proof value, sending (i) the hash lock and the second address to the first computing device and (ii) the hash lock and the first address to the second computing device, verifying the first blockchain transaction on the first blockchain for transfer to the first address and the second blockchain transaction on the second blockchain for transfer to the second address, and sending the proof value to blockchain nodes associated with the first and second blockchains.
Need to check novelty before this filing date? Find Prior Art

Description

[Technical field]

[0001] The present disclosure relates to atomic swap intermediation, and more particularly to enabling the use of intermediary processes to swap currencies across separate blockchain ledgers using atomic swaps and hash locks. [Background technology]

[0002] Blockchain was initially created as a storage mechanism for use in making payment transactions with cryptocurrencies. Using blockchain offers many benefits, such as decentralization, distributed computing, transparency regarding transactions, and also providing anonymity regarding individuals or entities involved in transactions. One of the more common aspects of blockchain is that it is an immutable record. All transactions that are part of the chain are stored within it and cannot be altered due to computational requirements and bandwidth limitations, especially as chains get longer and blockchain networks add more nodes.

[0003] The popularity and versatility of blockchain has led to a multitude of blockchains, each utilizing its own unique digital currency. Many users and entities interested in blockchain may find themselves interested in participating in multiple blockchains for a variety of reasons. As a result, such users may be interested in exchanging one blockchain currency for another blockchain currency, or participating in a transaction with another user where both utilize different currencies. Traditionally, there are two ways for such transactions to occur. The first is to use an exchange service, which either requires the user to surrender a private key to the exchange, or to have both parties transfer currency to the exchange. However, many parties may be wary of either option associated with using an exchange, due to the risks involved in surrendering a private key or entrusting all funds to a third party. The second traditional method is the use of atomic swaps. Atomic swaps utilize hash locks to ensure that either both parties will receive the currency, or that the party will not. However, atomic swaps typically require that both blockchains utilize the same hashing methodology, and both parties must be able to generate and use the hashes needed to accomplish the atomic swap.

[0004] There is therefore a need for technical improvements to perform atomic swaps that can be freely participated in by parties using traditional blockchain wallet capabilities and that are not dependent on the hashing methodology used by the blockchains involved. Summary of the Invention

[0005] This disclosure provides a description of a system and method for brokering an atomic swap. A processing server generates the data required for the hash lock. This data includes the proof value used. The processing server acts as an intermediary between the two parties involved in the atomic swap by providing both parties with an address and a hash lock. The parties make the necessary transactions using the hash lock and address provided by the processing server. The processing server verifies that both transactions have been posted to the appropriate blockchain and then provides a proof value to cause the blockchain to release the hash lock, thereby releasing funds to the parties. The use of a processing server allows both parties to utilize atomic swaps without having to generate the hash lock themselves, or even communicate with the other party. This provides easier execution and greater security. The result is an improved atomic swap that is safer and easier to execute for the parties involved.

[0006] A method for brokering an atomic swap includes receiving, by a receiver of a processing server, a swap request from a first computing device, the swap request including at least a first address associated with a first blockchain and a network identifier associated with a second blockchain; identifying, by a processor of the processing server, a second computing device based at least on the network identifier and a second address associated with the second blockchain; generating, by the processor of the processing server, a proof value and a hash lock, the hash lock being generated using at least the proof value; and transmitting, by a transmitter of the processing server, (i) a cryptographic key pair (PCB) that is a cryptographic key pair that is a cryptographic key pair of a first computing device and a first address associated with a first blockchain, the first address and the second address associated with the second blockchain. and (ii) at least the hash lock and the first address to the second computing device; verifying, by the processor of the processing server, a first blockchain transaction posted to the first blockchain for a transfer of a first currency amount to the first address and a second blockchain transaction posted to the second blockchain for a transfer of a second currency amount to the second address; and transmitting, by the transmitter of the processing server, at least the proof value to a first blockchain node associated with the first blockchain and a second blockchain node associated with the second blockchain.

[0007] A system for brokering an atomic swap includes a first computing device, a second computing device, and a processing server, the processing server comprising a receiver that receives a swap request from the first computing device, the swap request including at least a first address associated with a first blockchain and a network identifier associated with a second blockchain; a processor that performs the following: identifying the second computing device based on at least the network identifier and the second address associated with the second blockchain; generating a proof value and a hash lock, the hash lock being generated using at least the proof value; and (i) a processor that performs the following: and (ii) a transmitter that transmits at least the hash lock and the first address to the first computing device, and (ii) a transmitter that transmits at least the hash lock and the first address to the second computing device, wherein the processor of the processing server further verifies a first blockchain transaction posted to the first blockchain for the transfer of a first currency amount to the first address and a second blockchain transaction posted to the second blockchain for the transfer of a second currency amount to the second address, and the transmitter of the processing server further transmits at least the proof value to a first blockchain node associated with the first blockchain and to a second blockchain node associated with the second blockchain.

[0008] The scope of the present disclosure is best understood from the following detailed description of exemplary embodiments when read in conjunction with the accompanying drawing figures, which include: [Brief description of the drawings]

[0009] [Figure 1] FIG. 1 is a block diagram illustrating a high-level system architecture for brokering atomic swaps, in accordance with an example embodiment. [Diagram 2] 2 is a block diagram illustrating a processing server of the system of FIG. 1 for brokering an atomic swap in accordance with an exemplary embodiment. [Figure 3A] FIG. 2 is a flow diagram illustrating a process for performing a brokered atomic swap in the system of FIG. 1 according to an example embodiment. [Figure 3B] FIG. 2 is a flow diagram illustrating a process for performing a brokered atomic swap in the system of FIG. 1 according to an example embodiment. [Figure 4] 1 is a flowchart illustrating an example method for brokering an atomic swap, according to an example embodiment. [Diagram 5] FIG. 1 is a block diagram illustrating a computer system architecture in accordance with an exemplary embodiment. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0010] Further areas of applicability of the present disclosure will become apparent from the detailed description provided hereinafter. It should be understood that the detailed description of the exemplary embodiments is intended for purposes of illustration only, and is therefore not intended to necessarily limit the scope of the present disclosure.

[0011] Glossary Blockchain - a public ledger of all transactions of a currency based on a blockchain. One or more computing devices may include a blockchain network, which may be configured to process and record transactions as part of a block in the blockchain. When a block is completed, it is added to the blockchain and transaction records are updated accordingly. In many cases, the blockchain may be a chronological ledger of transactions, or may be presented in any other order that may be suitable for use by the blockchain network. In some configurations, transactions recorded in the blockchain may include a destination address and a currency amount, and the blockchain records how much currency is attributable to a particular address. In some cases, some transactions are financial, others are not, or transactions may include additional or different information, such as a source address, a timestamp, etc. In some embodiments, the blockchain may also or alternatively include almost any kind of data in the form of transactions that are or need to be placed in a distributed database that maintains a continuously growing list of data records that are hardened against tampering and modification, even by its operators. In some embodiments, the blockchain can be verified and validated by the blockchain network via proof of work and / or any other suitable verification techniques associated therewith. In some cases, the data about a given transaction can further include additional data that is not directly part of the transaction that is appended to the transaction data. In some cases, the inclusion of such data in the blockchain can constitute a transaction. In such cases, the blockchain may not be directly associated with a particular digital, virtual, fiat, or other type of currency.

[0012] A system for brokering atomic swaps FIG. 1 illustrates a system 100 for performing an atomic swap between two blockchains using an intermediary.

[0013] The system 100 can be configured to enable atomic swaps to occur between two different blockchain networks 106, shown in FIG. 1 as blockchain networks 106a and 106b. Each blockchain network 106 can be comprised of multiple different blockchain nodes. In an embodiment, one or more blockchain nodes can be nodes in two or more blockchain networks 106, including both blockchain networks 106a and 106b. Each blockchain node can be a computing system, as discussed in more detail below and shown in FIG. 5. The computing systems are configured to perform functions related to blockchain processing and management, including generating blockchain data values, validating proposed blockchain transactions, verifying digital signatures, generating new blocks, validating new blocks, and maintaining a replica of the blockchain.

[0014] A blockchain may be a distributed ledger that is composed of at least a number of blocks. Each block may include at least a block header and one or more data values. Each block header may include at least a timestamp, a block reference value, and a data reference value. The timestamp may be the time when the block header is generated and may be represented using any suitable method (e.g., UNIX timestamp, DateTime, etc.). The block reference value may be a value that references (e.g., based on the timestamp) an earlier block in the blockchain. In an embodiment, the block reference value in the block header may be a reference to the block header of the block that was most recently added before the respective block. In an exemplary embodiment, the block reference value may be a hash value generated via hashing the block header of the most recently added block. The data reference value may similarly be a reference to one or more data values ​​stored in the block that includes the block header. In an exemplary embodiment, the data reference value may be a hash value generated via hashing the one or more data values. For example, the block reference value may be the root of a Merkle tree that is generated using one or more data values.

[0015] The use of block reference values ​​and data reference values ​​in each block header can result in the blockchain being immutable. Any attempted modification to any data value requires the generation of a new data reference value for the block, which in turn requires the generation of a new block reference value for the subsequent block, which in turn requires the generation of a new block reference value in all subsequent blocks. This must be performed and updated at every single blockchain node in the blockchain network 106 before generating and adding a new block to the blockchain in order to make the change permanent. Computational and communication limitations make such modifications very difficult, if not impossible, thus making the blockchain immutable.

[0016] In one embodiment, a blockchain can be used to store information about blockchain transactions that occur between two different blockchain wallets. A blockchain wallet can include a private key of a cryptographic key pair. This is used to generate a digital signature that serves as a payer's authorization of the blockchain transaction. The digital signature can be verified by the blockchain network 106 using the public key of the cryptographic key pair. In some cases, the term "blockchain wallet" can refer specifically to a private key. In other cases, the term "blockchain wallet" can refer to a computing device (e.g., the processing server 102, the first participant device 108, or the second participant device 110) that stores a private key for use in blockchain transactions. For example, each computing device can each have its own private key for a respective cryptographic key pair and each can be a blockchain wallet for use in transactions with a blockchain associated with the blockchain network. The computing device can be any type of device suitable for storing and utilizing a blockchain wallet, such as a desktop computer, a laptop computer, a notebook computer, a tablet computer, a mobile phone, a smartphone, a smart watch, a smart TV, a wearable computing device, an embedded computing device, etc.

[0017] Each blockchain data value stored in the blockchain may correspond to a blockchain transaction or storage of other data, if applicable. A blockchain transaction may consist of at least a digital signature of the sender of the currency (e.g., the first participant device 108), generated using the sender's private key, a blockchain address of the recipient of the currency (e.g., the second participant device 110), generated using the recipient's public key, and the blockchain currency amount to be transferred or other data to be stored. In the case of a blockchain used for data storage separate from currency, the currency amount may be replaced by such other data. Also, in a blockchain transaction, the transaction may include one or more blockchain addresses of the sender where the blockchain currency is currently stored (e.g., the digital signature certifies access to such currency), and an address generated using the sender's public key for any changes held by the sender. Addresses to which cryptocurrency has been sent that may be used in future transactions are called "output" addresses, as each address was previously used to capture the output of a previous blockchain transaction, and are also called "unspent transactions" because there was currency sent to the address in a previous transaction where that currency is still unspent. Also, in some cases, a blockchain transaction may include the sender's public key for use by the entity in verifying the transaction. For conventional processing of blockchain transactions, such data may be provided by either the sender or recipient to a blockchain node in the blockchain network 106. The node may verify the digital signature using the public key in the sender's wallet's cryptographic key pair.The node may also verify access to the sender's funds (e.g., an unspent transaction has not yet been spent and was sent to an address associated with the sender's wallet), a process known as "confirming" the transaction, and then include the blockchain transaction in a new block. The new block may be verified by other nodes in the blockchain network 106 before being added to the blockchain and distributed to all of the blockchain nodes in the blockchain network 106 in a traditional blockchain implementation. In cases where the blockchain data value is not associated with a blockchain transaction, but may instead be associated with the storage of other types of data, the blockchain data value may still include or involve the verification of a digital signature.

[0018] The system 100 may include a processing server 102. The processing server 102 may be configured to act as an intermediary between a first participant device 108 and a second participant device 110 to exchange blockchain currency in a blockchain associated with a first blockchain network 106a, referred to herein as the first blockchain, for blockchain currency in a blockchain associated with a second blockchain network 106b, referred to herein as the second blockchain, to execute an atomic swap, as discussed in more detail below. To initiate a transaction, the first participant device 108 may submit a swap request to the processing server 102 using any suitable communication network and method. For example, the first participant device 108 may include an application program configured to submit a swap request to the processing server 102, may access a website where a swap request may be submitted, or may access an application programming interface associated with the processing server 102.

[0019] The swap request may include at least a destination address on the blockchain where the first participant device 108 wishes to receive the currency (e.g., in the first blockchain). This destination address may be referred to herein as the first address. The destination address may be generated by the first participant device 108 using a blockchain wallet, for example, by generating the address with the public key of a cryptographic key pair associated with the first blockchain. The swap request may also include a currency amount. This currency amount may be an amount of blockchain currency that a user associated with the first participant device 108 wishes to transfer on the second blockchain or receive on the first blockchain. In some cases, the swap request may include both currency amounts, i.e., how much the user wishes to transfer on the second blockchain and how much the user wishes to receive on the first blockchain. In other cases, only one currency amount may be provided, as discussed below. The other amount may be determined based on an exchange rate, etc., which may depend on both the blockchain network 106 and the second participant device 110. In some embodiments, the swap request may also include an identifier for the first blockchain and / or the second blockchain. This identifier may be a unique identification value associated with the respective blockchain, the associated blockchain network 106, or the blockchain currency used by the respective blockchain. If the swap request does not include such an identifier, the processing server 102 may be configured to identify the blockchain and / or the blockchain network 106 based on the currency amount included (e.g., if the currency itself is specified, it may be used by the processing server 102 to identify the appropriate blockchain).

[0020] The processing server 102 can receive the swap request and can identify both blockchain networks 106 involved in the atomic swap based on the data included in the swap request. In an embodiment, the swap request can identify the second participant device 110. This can be done, for example, by including a device identifier or contact information for the second participant device 110, such as a phone number, a media access control address, an Internet protocol address, a serial number, or other unique value. In other embodiments, the first participant device 108 can submit a swap request to the processing server 102 without identifying the second participant device 110. In such an embodiment, the processing server 102 can assist the first participant device 108 in finding a second participant device 110 with which to perform the atomic swap.

[0021] In such an embodiment, any device (which may include, for example, the first participant device 108) that is interested in participating in an atomic swap as a second participant device 110 may register with the processing server 102. Registration may include providing the processing server 102 with a device identifier associated with the device and a list of blockchain networks 106 in which the device has a blockchain wallet and may be willing to receive and / or transfer blockchain currency (e.g., via an identification value). In some cases, the registering device may also provide a public key for one or more networks in which the device is registered. As a result, the processing server 102 may generate a receiving address to allow the processing server 102 to reduce operations that the device may need to perform during a brokered atomic swap. In some cases, a registered device may provide an update of its current balance on the blockchain. The device is willing to transfer currency. The currency may be maintained in the device's registration data in the processing server 102.

[0022] When the processing server 102 assists in finding a second participant device 110 for a first participant device 108, the processing server 102 can identify all registered devices that receive blockchain currency on the second blockchain and transfer blockchain currency on the first blockchain. If the currency balances of the registered devices are stored, the processing server 102 can identify only those devices that have sufficient balances based on the currency amounts provided in the swap request. In some cases, each registered device can have a desired exchange rate or fee associated with participating in an atomic swap as a second participant device 110. In such a case, the processing server 102 can calculate the currency amounts that may be required to accomplish the atomic swap desired by the first participant device.

[0023] Once the processing server 102 identifies the eligible devices, it may transmit a list of the identified devices to the first participant device 108 using an appropriate communications network and method, for example in response to a received swap request. If fees or exchange rates may vary across the eligible devices, the list may include the associated fees, exchange rates, the amount of currency in the first blockchain that the first participant device 108 will receive, and / or the amount of currency in the second blockchain that the first participant device 108 must transfer for each of the eligible devices. A user associated with the first participant device 108 may then select one of the eligible devices to function as the second participant device 110 and submit the selection to the processing server 102 using an appropriate communications network and method.

[0024] The processing server 102 may receive the selection for the second participant device 110 and may perform any additional calculations that may be required to determine the currency amount for both the first and second blockchains. If the processing server 102 is able to store a public key for the selected second participant device 110 on the second blockchain, the processing server 102 may generate a destination address for the second participant device 110 to be used to receive the currency in the second blockchain. If the processing server 102 does not have the public key, the processing server 102 may submit a request for a destination address to the selected second participant device 110. The request may include at least an identifier for the second blockchain and may include any additional information desired by the second participant device 110, such as the currency amount for the first or second blockchain, the exchange rate and / or fees used. The second participant device 110 may then use the received identifier to identify the appropriate blockchain wallet and generate a destination address for the second blockchain using the public key of the respective cryptographic key pair. The second participant device 110 can electronically transmit the destination address back to the processing server 102 using an appropriate communications network and method.

[0025] The processing server 102 may prepare to start processing for the atomic swap. To start processing, the processing server 102 may generate a value to be used as a proof value for the hash lock. The value may be a unique value specific to the transaction. The value may be generated randomly or pseudo-randomly, may be constructed based on information about the first participant device 108 and the second participant device 110 (e.g., from the first address and the second address), or may be identified using any other suitable method. The proof value may be generated and / or identified by the processing server 102, but may be unknown to any other devices, in particular the first participant device 108 and the second participant device 110. Next, the processing server 102 may generate a hash lock. A hash lock is a scrambled version of a cryptographic key or other value that, when placed on a transaction, locks the output of the transaction until the hash value is unlocked using the original cryptographic key or other value. In the system 100, the processing server 102 may generate a hash lock using the proof value. This hash lock will be placed on the transfer made by the first participant device 108 and the second participant device 110. It can only be unlocked by the processing server 102 using the proof value. The hash lock can be generated, for example, by applying a hash algorithm to the proof value. In some cases, the hash lock can also be generated using additional data associated with the atomic swap to be performed, such as the first address, the second address, the currency amount of the first blockchain or the second blockchain. In some embodiments, the processing server 102 can generate separate hash locks (a hash lock for the first participant device 108 used on the second blockchain, and a hash lock for the second participant device 110 used on the first blockchain), for example, by using different data when generating the hash locks, but can also utilize the same proof value for both hash locks.

[0026] Once the hash lock is generated, the processing server 102 can electronically transmit to the appropriate participating devices the data necessary for each participating device to execute the appropriate transaction. For example, the processing server 102 can transmit at least the destination address on the second blockchain (e.g., provided by the second participant device 110), the currency amount of the second blockchain, and the hash lock to the first participant device 108. The processing server 102 can transmit at least the destination address on the first blockchain (e.g., from the swap request), the currency amount of the first blockchain, and the hash lock to the second participant device 110. In some instances, the processing server 102 can avoid transmitting any redundant information that the appropriate participant device may have already received (e.g., in the swap request or when requesting the destination address).

[0027] The participant devices can receive the data and can submit a new blockchain transaction to the appropriate blockchain for the transfer of the currency as indicated in the received data. For example, the first participant device 108 can generate a blockchain transaction for the second blockchain for the transfer of the appropriate currency amount to a destination address associated with the blockchain wallet of the second participant device 110 and then submit the blockchain transaction to a blockchain node in the blockchain network 106b. The second participant device 110 can generate a new blockchain transaction for the first blockchain for the transfer of the appropriate currency amount to the destination address submitted in the swap request, which can then be submitted to a blockchain node in the blockchain network 106a.

[0028] Using conventional methods and systems, once both blockchain transactions have been posted to their respective blockchains, the processing server 102 can verify that the transactions have been posted and are correct (e.g., involving the proper currency amount being transferred to the proper destination address). In some embodiments, the first participant device 108 and the second participant device 110 can receive a confirmation message from the blockchain node after submitting the transaction. This can include, for example, an identifier of a blockchain data value on the blockchain that stores the submitted blockchain transaction. In such an embodiment, the first participant device 108 and the second participant device 110 can provide the received identifier and / or the confirmation message to the processing server 102 for use in identifying the blockchain transaction on the first and second blockchains. In other embodiments, the processing server 102 can monitor both the first and second blockchains to add blockchain transactions that match the desired atomic swap. This can be done, for example, by monitoring the destination addresses provided to each participant device.

[0029] After the blockchain transactions are identified, the processing server 102 can verify each transaction. Validating the transaction can include verifying that the destination address is correct and that the currency amount being transferred is correct. In some cases, the processing server 102 can also verify that the hash lock is the same hash lock that was previously provided by the processing server 102. In some embodiments, the processing server 102 can digitally sign the hash lock before providing it to the first participant device 108 and the second participant device 110, for example, by using a private key of a cryptographic key pair. In such an embodiment, the processing server 102 can verify the digital signature using the corresponding public key in the cryptographic key pair as part of validating the blockchain transaction. If one or both of the blockchain transactions cannot be successfully validated, the processing server 102 can notify the appropriate participant device and can provide the participant device with an opportunity to submit a modified blockchain transaction. If both blockchain transactions are not successfully validated, the hash lock may not be removed by the processing server 102. This can prevent the transaction from being unlocked, thereby preventing the transfer. In some cases, a hash lock can have an expiration time associated with it (e.g., via a smart contract, the blockchain network 106, etc.). If the hash lock is not unlocked within the expiration time, the corresponding blockchain transaction will not occur (e.g., will remain locked, either with an input that can be used again by the sender, or with a reversal transaction that is automatically posted to the blockchain).

[0030] If both blockchain transactions are successfully verified, the processing server 102 may release the hash lock. The processing server 102 may electronically send a proof value to a blockchain node in the first blockchain network 106a and a blockchain node in the second blockchain network 106b to release the hash lock. This proof value may be used by the blockchain nodes to generate the hash lock and may verify a match to ensure that the processing server 102 is authorized to remove the hash lock. If other data was used in addition to the proof value to generate the hash lock, the additional data may also be sent to the blockchain nodes. If a separate hash lock is generated for each blockchain transaction, the processing server 102 may send the appropriate data to the appropriate blockchain node accordingly. Once the hash lock is removed, both the first participant device 108 and the second participant device 110 will receive the currency on the first blockchain and the second blockchain, respectively, to complete the atomic swap.

[0031] In an example implementation, the processing server 102 can utilize the following code to define and create a hash lock that is created using a currency amount, a destination address, and a proof value:

[0032] class AtomicSwapContract: struct HashLock { Coin amount Address recipient byte[] hashKey } public CreateHashLock(double amount, Address recipient, byte[] hashKey){ Coin coin = WithdrawAmountFromSenderAccount(amount) HashLock hashLock = new HashLock(coin, recipient, hashKey) PublishHashLockTransactionToSenderAccount(hashLock) } }

[0033] In the above example, hashKey may be the attestation value generated by the processing server 102 as described above. When the hash lock is unlocked, the processing server 102 may utilize the following function in an example implementation:

[0034] public Unlock(Address addressOfSmartContract, Address recipient, byte[] secretKey){ HashLock hashLock = ReadTransactionFromSender(addressOfSmartContract) / / Ensure the recipient of the hashLock is same as provided assert(hashLock.recipient == recipient) / / Ensure the hashes match, otherwise this transaction will fail byte[] hashOfSecretKey = Hash(secretKey) assert(hashLock.hashKey == hashOfSecretKey) / / Second receives the amount from the first participant. SendTransaction(hashLock.recipient, hashLock.amount) }

[0035] In one embodiment, hash locks and atomic swaps can be implemented by the blockchain through the use of smart contracts, which can be self-executing agreements stored within the blockchain. Smart contracts can utilize different programming languages, codes, and protocols that can vary for each blockchain network 106. In one example, a blockchain network 106 can utilize Solidity® as the programming language for smart contracts used by the associated blockchain. In Solidity, the above functions can be implemented using, for example, the following code:

[0036] contract AtomicSwap { struct Swap { address sender; address recipient; uint startTime; uint duration; uint amount; bool active; } mapping(bytes32=>Swap) swaps; event SwapStart(address indexed sender, address indexed recipient, bytes32 indexed hashedSecret, uint startTime, uint duration, uint amount); function startSwap(address recipient, uint duration, bytes32 hashedSecret) public payable { require(! swaps[hashedSecret].active); require(msg.value > 0); Swap memory swap; swap.sender = msg.sender; swap.recipient = recipient; swap.startTime = now; swap.duration = duration; swap.amount = msg.value; swap.active = true; swaps[hashedSecret] = swap; emit SwapStart(swap.sender, swap.recipient, hashedSecret, swap.startTime, swap.duration, swap.amount); } event SwapCancel(bytes32 indexed hashedSecret, uint time); function cancelSwap(bytes32 hashedSecret) public { Swap memory swap = swaps[hashedSecret]; require(swap.sender == msg.sender); require(swap.active); require(now >= swap.startTime + swap.duration); swaps[hashedSecret].active = false; msg.sender.transfer(swap.amount); emit SwapCancel(hashedSecret, now); } event SwapComplete(bytes32 indexed hashedSecret, uint time); function completeSwap(bytes memory secret) public { bytes32 hashedSecret = keccak256(secret); Swap memory swap = swaps[hashedSecret]; require(swap.recipient == msg.sender); require(swap.active); require(now < swap.startTime + swap.duration); swaps[hashedSecret].active = false; msg.sender.transfer(swap.amount); emit SwapComplete(hashedSecret, now); } / / auxilary function to get swap info function getSwapInfo(bytes32 hashedSecret) public view returns(address sender, address recipient, uint startTime, uint duration, uint amount, bool active) { Swap memory swap = swaps[hashedSecret]; sender = swap.sender; recipient = swap.recipient; startTime = swap.startTime; duration = swap.duration; amount = swap.amount; active = swap.active; } / / auxilary function to help calculate the hashed secret on chain function hashSecret(bytes memory secret) public pure returns(bytes32){ return keccak256(secret); } }

[0037] In the above example, Swap can be the configuration for the data of the atomic swap to be performed. SwapStart can be called to generate a hash lock for both transactions. SwapCancel can be used to stop the atomic swap and if the transaction is not successfully published (e.g., due to a failed validation or retraction by one of the participant devices). SwapComplete can be used to remove the hash lock and allow both transactions to be completed. getSwapInfo can be used to identify the current state of the atomic swap. This can be, for example, to check the expiration time while the processing server 102 waits for validation of the two blockchain transactions. It will be apparent to one skilled in the art that the above code is an example and may not encompass all implementations of the methods and systems discussed herein using Solidity or any other programming language.

[0038] The methods and systems discussed herein provide for the brokering of atomic swaps by the processing server 102. By brokering atomic swaps in the manner discussed herein, a first participant device 108 can have the desired swap without giving up its private or public key or even identifying the second participant device 110 (as it can instead be identified by the processing server 102). In addition, because the transaction is performed independently on both blockchains, with the processing server 102 as the intermediary in charge of the hash lock, the atomic swap can be performed regardless of hashing methodologies and other technical differences between the blockchain networks 106. As a result, the methods and systems discussed herein provide more versatile atomic swaps while also improving convenience and security for participants through the use of the intermediary and the processes discussed herein.

[0039] Processing Server 2 illustrates one embodiment of a processing server 102, such as the processing server 102 in system 100. Those skilled in the art will appreciate that the embodiment of processing server 102 illustrated in FIG. 2 is provided by way of example only and may not be exhaustive of all possible configurations of a processing server 102 suitable for performing the functions as discussed herein. For example, computer system 500 illustrated in FIG. 5 and discussed in more detail below may be a suitable configuration of processing server 102.

[0040] The processing server 102 may include a receiving device 202. The receiving device 202 may be configured to receive data over one or more networks via one or more network protocols. In some cases, the receiving device 202 may be configured to receive data from blockchain nodes, the first participant device 108, the second participant device 110, and other systems and entities via one or more communication methods, such as radio frequency, local area network, wireless area network, cellular communication network, Bluetooth, Internet, etc. In some embodiments, the receiving device 202 may be comprised of multiple devices, such as different receiving devices for receiving data via different networks, such as a first receiving device for receiving data via a local area network and a second receiving device for receiving data via the Internet. The receiving device 202 may receive an electronically transmitted data signal. Data may be superimposed or encoded on the data signal and may be decoded, parsed, read, or obtained via reception of the data signal by the receiving device 202. In some instances, the receiving device 202 may include a parsing module to parse the received data signal to obtain the overlaid data. For example, the receiving device 202 may include a parser program configured to receive and convert the received data signal into usable input for functions performed by the processing device to implement the methods and systems described herein.

[0041] The receiving device 202 can be configured to receive data signals transmitted electronically by a blockchain node. This can be overlaid or encoded with blockchain data values, blocks, blockchain transaction data, etc. The receiving device 202 can also be configured to receive data signals transmitted electronically by a first participant device 108. This can be overlaid or encoded with swap requests, destination addresses, transaction identifiers, registration data, etc. The receiving device 202 can also be configured to receive data signals transmitted electronically by a second participant device 110. This can be overlaid or encoded with registration data, destination addresses, fees, exchange rates, network identifiers, transaction identifiers, etc.

[0042] The processing server 102 may also include a communication module 204. The communication module 204 may be configured to transmit data between the modules, engines, databases, storage, and other components of the processing server 102 for use in performing the functions discussed herein. The communication module 204 may be comprised of one or more communication types and may utilize various communication methods for communication within a computing device. For example, the communication module 204 may be comprised of a bus, a contact pin connector, wires, and the like. In an embodiment, the communication module 204 may also be configured to communicate between the internal components of the processing server 102 and external components of the processing server 102, such as an externally connected database, a display device, an input device, and the like. The processing server 102 may also include a processing device. The processing device may be configured to perform the functions of the processing server 102 discussed herein, as would be apparent to one of ordinary skill in the art. In an embodiment, the processing device may include and / or be comprised of multiple engines and / or modules specifically configured to perform one or more functions of the processing device, such as the query module 214, the generation module 216, the validation module 218, and the like. As used herein, the term "module" can refer to software running on hardware or hardware specifically programmed to receive input, perform one or more operations using the input, and provide output. The inputs, outputs, and operations performed by various modules will be apparent to one of ordinary skill in the art based on this disclosure.

[0043] The processing server 102 may include an account database 206. The account database 206 may be configured to store a number of account profiles 208 using a suitable data storage format and schema. The account database 206 may be a relational database utilizing a structured query language for storing, identifying, modifying, updating, accessing, etc., the stored structured data collections. Each account profile 208 may be a structured data collection configured to store data related to one or more registered accounts, for any device registered to act as a second participant device 110 in an atomic swap, as described above. For example, an account profile 208 may be associated with a second participant device 110 and may store data necessary for the device's identification as a second participant device 110 and participation in an atomic swap. For example, the account profile 208 may include a device identifier, an identifier for each blockchain network 106. The associated device may receive currency. Alternatively, the associated device may transfer currency, currency balances in any blockchain to which the associated device can transfer currency, the public key of a cryptographic key pair for a blockchain to which the associated device can receive currency, contact information, fees, exchange rates, etc.

[0044] The processing server 102 may also include blockchain data 210, which may be stored in the storage 212 of the processing server 102 or may be stored in a separate area within the processing server 102 or may be accessible thereby. The blockchain data 210 may include a blockchain, which may be comprised of multiple blocks and may be associated with the blockchain network 106. The blockchain data 210 may also or alternatively include any data associated with one or more blockchain wallets that may be used by the processing server 102. This data may be, for example, cryptographic key pairs, unspent transaction outputs, digital asset amounts, network identifiers for the blockchain network 106, smart contracts, signature generation algorithms, encryption algorithms, communication information for third-party services, etc.

[0045] The processing server 102 may also include a memory 212. The memory 212 may be configured to store data for use by the processing server 102 in performing the functions discussed herein, such as public and private keys, symmetric keys, etc. The memory 212 may be configured to store data using appropriate data formatting methods and schemas, and may be any suitable type of memory, such as read-only memory, random access memory, etc. For example, the memory 212 may include cryptographic keys and algorithms, communication protocols and standards, data formatting standards and protocols, program code for processing device modules and application programs, and other data that may be suitable for use by the processing server 102 in performing the functions disclosed herein, as would be apparent to one of ordinary skill in the art. In an embodiment, the memory 212 may consist of or include a relational database. The relational database utilizes a structured query language for storing, identifying, modifying, updating, accessing, etc., stored structured data sets. The memory unit 212 can be configured to store, for example, cryptographic keys, salts, nonces, communication information for other computing systems, generation algorithms, cryptographic key pairs, algorithms for calculating currency amounts, exchange rates, identifiers for the blockchain network 106, and the like.

[0046] The processing server 102 may include a query module 214. The query module 214 may be configured to run a query on a database to identify information. The query module 214 may receive one or more data values ​​or query strings and may run the query string based thereon on an indicated database, such as the account database 206 of the processing server 102, to identify stored information. The query module 214 may then output the identified information to an appropriate engine or module of the processing server 102, as appropriate. The query module 214 may, for example, run a query on the account database 206 to find all registered devices that may be eligible to serve as the second participant device 110 of the atomic swap requested by the first participant device 108. This may be done, for example, based on a network identifier included in the swap request.

[0047] The processing server 102 may also include a generation module 216. The generation module 216 may be configured to generate data for use by the processing server 102 in performing the functions discussed herein. The generation module 216 may receive instructions as input, generate data based on the instructions, and output the generated data to one or more modules of the processing server 102. For example, the generation module 216 may be configured to generate a cryptographic key pair, generate a digital signature, generate a blockchain data value, etc. The generation module 216 may also be configured to generate a proof value and a hash lock, and generate any data necessary for removal of the hash lock generated by the processing server 102.

[0048] The processing server 102 may also include a validation module 218. The validation module 218 may be configured to perform validation for the processing server 102 as part of the functionality discussed herein. The validation module 218 may receive instructions as input (which may also include data used in performing the validation), perform the validation upon request, and output the results of the validation to another module or engine of the processing server 102. The validation module 218 may be configured to, for example, validate digital signatures using appropriate signature generation algorithms and keys, validate blockchain transactions, validate smart contracts, validate hash locks, etc.

[0049] The processing server 102 may also include a transmitting device 220. The transmitting device 220 may be configured to transmit data over one or more networks via one or more network protocols. In some cases, the transmitting device 220 may be configured to transmit data to the blockchain nodes, the first participant device 108, the second participant device 110, and other entities via one or more communication methods, such as a local area network, a wireless area network, cellular communication, Bluetooth, radio frequency, the Internet, and the like. In some embodiments, the transmitting device 220 may be comprised of multiple devices, such as different transmitting devices for transmitting data over different networks, such as a first transmitting device for transmitting data over a local area network and a second transmitting device for transmitting data over the Internet. The transmitting device 220 may electronically transmit a data signal overlaid with data, which may be parsed by a receiving computing device. In some cases, the transmitting device 220 may include one or more modules for overlaying, encoding, or formatting the data into a data signal suitable for transmission.

[0050] The sending device 220 can be configured to electronically send a data signal to a blockchain node. This can be overlaid or encoded with a hash lock, data for removal of the hash lock, a request for a block or blockchain data value, etc. The sending device 220 can also be configured to electronically send a data signal to a first participant device 108. This can be overlaid or encoded with a request for an address, a list of eligible second participant devices 110, a currency amount, a fee, an exchange rate, data about a new blockchain transaction, a notification, etc. The sending device 220 can be configured to electronically send a data signal to a second participant device 110. This can be overlaid or encoded with a request for a destination address or currency amount data, data about a new blockchain transaction, a notification, a request for an updated currency balance, etc.

[0051] The process for executing a brokered atomic swap 3A and 3B illustrate a process for performing an atomic swap in the system 100 of FIG. 1, mediated by the processing server 102 and involving a first participant device 108 and a second participant device 110. As shown in FIG.

[0052] At step 302, the second participant device 110 may register with the processing server 102 for participation in the atomic swap by electronically transmitting registration data to the processing server 102. The registration data may include, for example, a device identifier and / or contact information for the second participant device 110, a list of identifiers for blockchains for which the second participant device 110 is willing to accept currency, and a list of identifiers for blockchains for which the second participant device is willing to transfer currency. At step 304, the receiving device 202 of the processing server 102 may receive the registration data from the second participant device 110. At step 306, the query module 214 of the processing server 102 may perform a query on the account database 206 of the processing server 102 to insert therein a new account profile 208 for the second participant device 110 including the received device registration data.

[0053] At step 308, the first participant device 108 may submit a request for an atomic swap to the processing server 102 using an appropriate communications network and method. The swap request may include at least a destination address on the first blockchain where the first participant device 108 wishes to receive the currency, an amount of the currency the first participant device 108 wishes to receive on the first blockchain, and one or more identifiers of a second blockchain to which the first participant device 108 is willing to transfer the currency. At step 310, the receiving device 202 of the processing server 102 may receive the swap request.

[0054] In step 312, the query module 214 of the processing server 102 may perform a query on the account database 206 of the processing server 102 to identify the account profile 208 of any registered device that may be suitable to act as the second participant device 110 in the atomic swap. This is done, for example, by checking to see if the account profile 208 includes an indication of the first blockchain as the associated device being willing to transfer currency, and an indication of one of the second blockchain as the associated device being willing to receive currency. In an embodiment, the processing server 102 may identify multiple eligible devices and may request from the first participant device 108 a selection of one of the devices. In the example shown in FIG. 3A and FIG. 3B, the processing server 102 may identify the second participant device 110 device as eligible and proceed accordingly. As part of step 312, the processing server 102 may identify a destination address for the second participant device 110 on the second blockchain (e.g., selected from all eligible second blockchains by the processing server 102, the first participant device 108, or the second participant device 110). This may be done, for example, by generating the destination address (e.g., via the generation module 216 using a public key for the second blockchain stored in the account database 208) or by requesting a destination address from the second participant device 110 for the second blockchain.

[0055] In step 314, the generation module 216 of the processing server 102 may generate a proof value to be used in the hash lock. The proof value may be generated or identified using any suitable method and may be unique to the atomic swap requested by the first participant device 108. In step 316, the generation module 216 of the processing server 102 may generate a hash lock using at least the proof value, for example by applying a hashing algorithm to the proof value. The hash lock is the resulting hash value. In step 318, the sending device 220 of the processing server 102 may electronically send the hash lock and appropriate transaction data to both the first participant device 108 and the second participant device 110. The first participant device 108 may be sent the hash lock, a destination address for the second blockchain of the second participant device 110, and a currency amount of the second blockchain. The second participant device 110 can be sent the hash lock, the destination address for the first blockchain of the first participant device 108, and the currency amount of the first blockchain.

[0056] In step 320, the first participant device 108 can receive the hash lock, the destination address, and the currency amount from the processing server 102. In step 322, using conventional methods and systems, the first participant device 108 can submit a new blockchain transaction to a blockchain node in the second blockchain network 106b for forwarding the received currency amount to the received destination address using one or more appropriate transaction outputs owned by the first participant device 108 (e.g., dealing in the currency amount). The blockchain transaction can be hash locked by a hash lock sent by the first participant device 108 or by being submitted separately to the blockchain network 106b by the processing server 102 before the new blockchain transaction is submitted. The first participant device 108 can receive a transaction identifier from the blockchain node as notification that the new blockchain transaction has been successfully verified, added to a new block, and posted to the second blockchain. In step 324, the first participant device 108 may electronically transmit the transaction identifier when notifying the processing server 102 that the blockchain transaction was successfully posted.

[0057] At step 326, the second participant device 110 may receive the hash lock, the destination address, and the currency amount from the processing server 102. At step 328, using conventional methods and systems, the second participant device 110 may submit a new blockchain transaction to a blockchain node in the first blockchain network 106a for forwarding the received currency amount to the received destination address using one or more appropriate transaction outputs owned by the second participant device 110 (e.g., dealing in the currency amount). The blockchain transaction may be hash locked by a hash lock sent by the second participant device 110 or by being submitted separately to the blockchain network 106a by the processing server 102 before the new blockchain transaction is submitted. The second participant device 110 may receive a transaction identifier from the blockchain node as notification that the new blockchain transaction has been successfully verified, added to a new block, and posted to the second blockchain. In step 330, the second participant device 110 may electronically transmit the transaction identifier when notifying the processing server 102 that the blockchain transaction was successfully posted.

[0058] In step 332, the receiving device 202 of the processing server 102 may receive transaction identifiers for both blockchain transactions from both the first participant device 108 and the second participant device 110. In step 334, the processing server 102 may identify both blockchain transactions. This may be done, for example, in the blockchain data 210 stored in the processing server 102, or by requesting blockchain data values ​​from the appropriate blockchain network 106 using the received transaction identifiers. In step 336, the validation module 218 of the processing server 102 may validate both blockchain transactions. Each blockchain transaction may be validated by the validation module 218 by ensuring that the destination address and currency amount are correct, and by verifying that the hash lock is correct, in place, and has not yet expired. If the transaction is successfully verified, then in step 338, the sending device 220 of the processing server 102 can electronically send the proof value to blockchain nodes in both the first blockchain network 106a and the second blockchain network 106b to request the removal of the hash locks on both blockchain transactions. Once the hash locks are removed, the first participant device 108 and the second participant device 110 can receive currency on the appropriate blockchain and the atomic swap can be completed.

[0059] Exemplary Method for Brokering Atomic Swaps FIG. 4 illustrates a method 400 for brokering an atomic swap by a third party processing server.

[0060] In step 402, a swap request may be received from a first computing device (e.g., first participant device 108) by a receiver (e.g., receiver device 202) of a processing server (e.g., processing server 102). The swap request includes at least a first address associated with the first blockchain and a network identifier associated with the second blockchain. In step 404, a processor (e.g., query module 214) of the processing server may identify a second computing device (e.g., second participant device 110) based at least on the network identifier and the second address associated with the second blockchain. In step 406, a proof value and a hash lock may be generated by a processor (e.g., generation module 216) of the processing server. The hash lock is generated using at least the proof value.

[0061] In step 408, a transmitter of the processing server (e.g., the sending device 220) may (i) send at least the hash lock and the second address to the first computing device and (ii) send at least the hash lock and the first address to the second computing device. In step 410, a processor of the processing server (e.g., the validation module 218) may validate the first blockchain transaction posted to the first blockchain for the transfer of the first currency amount to the first address and the second blockchain transaction posted to the second blockchain for the transfer of the second currency amount to the second address. In step 412, the transmitter of the processing server may send at least the proof value to a first blockchain node associated with the first blockchain and a second blockchain node associated with the second blockchain.

[0062] In one embodiment, the second computing device can be identified in the swap request. In an embodiment, identifying the second computing device can include identifying, by a processor of the processing server, an identifier for each of the multiple additional computing devices based on the network identifier, transmitting, by a transmitter of the processing server, the identifier for each of the multiple additional computing devices to the first computing device, and receiving, by a receiver of the processing server, an identifier associated with the second computing device from the first computing device. In one embodiment, the swap request can include a first currency amount and a second currency amount. In an embodiment, the first currency amount and the second currency amount can be the same amount.

[0063] In one embodiment, the method 400 may further include receiving, by a receiver of the processing server, first notification data associated with the first blockchain transaction from the second computing device, and receiving, by a receiver of the processing server, second notification data associated with the second blockchain transaction from the first computing device. In a further embodiment, the first notification data and the second notification data may be received prior to validating the first blockchain transaction and the second blockchain transaction, the first blockchain transaction may be validated using the first notification data, and the second blockchain transaction may be validated using the second notification data. In an embodiment, the method 400 may also include calculating, by a processor of the processing server, a second currency amount based at least on the first currency amount and an exchange rate associated with the second computing device.

[0064] Computer System Architecture 5 illustrates a computer system 500 in which embodiments of the present disclosure or portions thereof can be implemented as computer readable code. For example, the processing server 102 of FIGS. 1 and 2 can be implemented in the computer system 500 using hardware, non-transitory computer readable media having stored instructions, or a combination thereof, and can be implemented in one or more computer systems or other processing systems. The hardware can embody modules and components used to implement the methods of FIGS. 3A, 3B, and 4.

[0065] Where programmable logic is used, such logic may be executed on commercially available processing platforms configured with executable software code to become a specific purpose computer or special purpose device (e.g., programmable logic arrays, application specific integrated circuits, etc.). Those skilled in the art will appreciate that embodiments of the disclosed subject matter may be practiced using a variety of computer system configurations, including multi-core multiprocessor systems, minicomputers, mainframe computers, computers linked or clustered with distributed functionality, as well as pervasive or small computers that may be embedded in virtually any device. For example, at least one processor device and memory unit may be used to implement the above-described embodiments.

[0066] A processor unit or device discussed herein may be a single processor, multiple processors, or a combination thereof. A processor device may have one or more processor "cores." As discussed herein, the terms "computer program medium," "non-transitory computer-readable medium," and "computer usable medium" are generally used to refer to tangible media, such as removable storage unit 518, removable storage unit 522, and a hard disk installed in hard disk drive 512.

[0067] Various embodiments of the present disclosure are described with respect to this exemplary computer system 500. After reading this description, it will become apparent to one of ordinary skill in the art how to implement the present disclosure using other computer systems and / or computer architectures. Although the operations may be described as sequential processes, some of the operations may in fact be performed in parallel, concurrently, and / or in a distributed environment, using program code stored locally or remotely for access by single or multi-processor machines. Additionally, in some embodiments, the order of the operations may be rearranged without departing from the spirit of the disclosed subject matter.

[0068] The processor unit 504 may be a dedicated or general-purpose processor unit that is specifically configured to perform the functions discussed herein. The processor unit 504 may be connected to a communication infrastructure 506, such as a bus, a message queue, a network, a multi-core message passing scheme, and the like. The network may be any network suitable for performing the functions as disclosed herein, and may include a local area network (LAN), a wide area network (WAN), a wireless network (e.g., WiFi), a cellular network, a satellite network, the Internet, optical fiber, coaxial cable, infrared, radio frequency (RF), or any combination thereof. Other suitable network types and configurations will be apparent to those skilled in the art. The computer system 500 may also include a primary memory 508 (e.g., random access memory, read-only memory, etc.), and may also include a secondary memory 510. The secondary memory 510 may include a hard disk drive 512 and a removable storage drive 514, such as a floppy disk drive, a magnetic tape drive, an optical disk drive, a flash memory, and the like.

[0069] The removable storage drive 514 can read from and / or write to the removable storage unit 518 in a well-known manner. The removable storage unit 518 can include a removable storage medium that can be read from and written to by the removable storage drive 514. For example, if the removable storage drive 514 is a floppy disk drive or a universal serial bus port, the removable storage unit 518 can be a floppy disk or a portable flash drive, respectively. In one embodiment, the removable storage unit 518 can be a non-transitory computer-readable recording medium.

[0070] In some embodiments, secondary storage 510 may include alternative means for allowing computer programs or other instructions to be loaded into computer system 500, such as removable storage unit 522 and interface 520. Examples of such means may include program cartridges and cartridge interfaces (e.g., as found in video game systems), removable memory chips (e.g., EEPROM, PROM, etc.) and associated sockets, and other removable storage units 522 and interfaces 520 as would be apparent to one skilled in the art.

[0071] Data stored in computer system 500 (e.g., primary memory 508 and / or secondary memory 510) may be stored on any type of suitable computer-readable medium, such as optical storage devices (e.g., compact discs, digital versatile discs, Blu-ray discs, etc.) or magnetic tape storage devices (e.g., hard disk drives). Data may be organized in any type of suitable database configuration, such as, for example, a relational database, a Structured Query Language (SQL) database, a distributed database, an object database, etc. Suitable configurations and types of storage devices will be apparent to those skilled in the art.

[0072] Computer system 500 may also include a communications interface 524. Communications interface 524 may be configured to allow software and data to be transferred between computer system 500 and external devices. Exemplary communications interface 524 may include a modem, a network interface (e.g., an Ethernet card), a communications port, a PCMCIA slot and card, and the like. The software and data transferred through communications interface 524 may be in the form of signals, which may be electronic, electromagnetic, optical, or other signals as would be apparent to one skilled in the art. The signals may travel over communications path 526, which may be configured to carry signals and may be implemented using wire, cable, fiber optics, a telephone line, a cellular phone link, a radio frequency link, and the like.

[0073] The computer system 500 may further include a display interface 502. The display interface 502 may be configured to allow data to be transferred between the computer system 500 and an external display device 530. Exemplary display interfaces 502 may include a High-Definition Multimedia Interface (HDMI), a Digital Visual Interface (DVI), a Video Graphics Array (VGA), and the like. The display device 530 may be any suitable type of display device for displaying data transmitted via the display interface 502 of the computer system 500. The display device may include a cathode ray tube (CRT) display, a liquid crystal display (LCD), a light-emitting diode (LED) display, an electrostatic touch display, a thin film transistor (TFT) display, and the like.

[0074] The computer program medium and computer usable medium can refer to storage units such as the main storage unit 508 and the secondary storage unit 510, which can be memory semiconductors (e.g., DRAM, etc.). These computer program products can be means for providing software to the computer system 500. Computer programs (e.g., computer control logic) can be stored in the main storage unit 508 and / or the secondary storage unit 510. Also, the computer programs can be received via the communication interface 524. Such computer programs, when executed, can enable the computer system 500 to perform the methods as discussed herein. In particular, the computer programs, when executed, can enable the processor unit 504 to perform the methods illustrated by Figures 3A, 3B, and 4 as discussed herein. Thus, such computer programs can represent the control units of the computer system 500. If the present disclosure is implemented using software, the software can be stored in the computer program product and loaded into the computer system 500 using the removable storage drive 514, the interface 520, and the hard disk drive 512, or the communication interface 524.

[0075] The processor unit 504 may include one or more modules or engines configured to perform the functions of the computer system 500. Each of the modules or engines may be implemented using hardware, or in some cases may also utilize software, such as corresponding program code and / or programs stored in the main memory 508 or secondary memory 510. In such cases, the program code may be compiled by the processor unit 504 (e.g., by a compiling module or engine) prior to execution by the hardware of the computer system 500. For example, the program code may be source code written in a programming language that is translated into a lower level language, such as assembly language or machine code, for execution by the processor unit 504 and / or any additional hardware components of the computer system 500. The compiling process may include the use of lexical analysis, preprocessing, syntax analysis, semantic analysis, syntax-directed translation, code generation, code optimization, and any other techniques that may be suitable for translating program code into a lower level language suitable for controlling the computer system 500 to perform the functions disclosed herein. As a result of such processing, it will be apparent to one skilled in the art that computer system 500 is a specially configured computer system 500 that is uniquely programmed to perform the functions described above.

[0076] Techniques consistent with the present disclosure provide, among other things, features, systems, and methods for brokering atomic swaps. While various exemplary embodiments of the disclosed systems and methods have been described above, it should be understood that they have been presented for purposes of illustration only, and not limitation. It is not exhaustive and does not limit the disclosure to the precise form disclosed. Modifications and variations are possible in light of the above teachings, or can be acquired from the practice of the present disclosure without departing from the breadth or scope.

Claims

1. 1. A method for brokering an atomic swap, comprising: receiving, by a receiver of the processing server, a swap request from a first computing device, the swap request including at least a first address associated with the first blockchain and a network identifier associated with the second blockchain; identifying, by a processor of the processing server, a second computing device based at least on the network identifier and a second address associated with the second blockchain; generating, by the processor of the processing server, a proof value and a hash lock, the hash lock being generated using at least the proof value; transmitting, by a transmitter of the processing server, (i) at least the hash lock and the second address to the first computing device, and (ii) at least the hash lock and the first address to the second computing device; verifying, by the processor of the processing server, a first blockchain transaction posted to the first blockchain for the transfer of a first currency amount to the first address and a second blockchain transaction posted to the second blockchain for the transfer of a second currency amount to the second address; transmitting, by the transmitter of the processing server, at least the proof value to a first blockchain node associated with the first blockchain and to a second blockchain node associated with the second blockchain; A method comprising:

2. The method of claim 1 , wherein the second computing device is identified in the swap request.

3. 2. The method of claim 1, wherein identifying the second computing device comprises: identifying, by the processor of the processing server, an identifier for each of a plurality of additional computing devices based on the network identifier; transmitting, by the transmitter of the processing server, the identifier for each of the plurality of additional computing devices to the first computing device; receiving, by the receiver of the processing server, from the first computing device, an identifier associated with the second computing device; A method comprising:

4. 2. The method of claim 1, wherein the swap request includes the first currency amount and the second currency amount.

5. 2. The method of claim 1, wherein the first currency amount and the second currency amount are the same amount.

6. 10. The method of claim 1 , receiving, by the receiver of the processing server, from the second computing device, first notification data associated with the first blockchain transaction; receiving, by the receiver of the processing server, from the first computing device, second notification data associated with the second blockchain transaction; The method further comprising:

7. 7. The method of claim 6, The first notification data and the second notification data are received prior to verifying the first blockchain transaction and the second blockchain transaction; The first blockchain transaction is verified using the first notification data; The second blockchain transaction is verified using the second notification data.

8. 10. The method of claim 1 , calculating, by the processor of the processing server, the second currency amount based at least on the first currency amount and an exchange rate associated with the second computing device; The method further comprising:

9. A system for intermediating atomic swaps, comprising: a first computing device; a second computing device; and a processing server, the processing server comprising: a receiver that receives a swap request from the first computing device, the swap request including at least a first address associated with a first blockchain and a network identifier associated with a second blockchain; 1. A processor comprising: identifying the second computing device based on at least the network identifier and a second address associated with the second blockchain; generating a proof value and a hash lock, the hash lock being generated using at least the proof value; (i) a transmitter that transmits at least the hash lock and the second address to the first computing device, and (ii) at least the hash lock and the first address to the second computing device; The processor of the processing server further verifies a first blockchain transaction posted to the first blockchain for the transfer of a first currency amount to the first address and a second blockchain transaction posted to the second blockchain for the transfer of a second currency amount to the second address; The transmitter of the processing server further transmits at least the proof value to a first blockchain node associated with the first blockchain and to a second blockchain node associated with the second blockchain.

10. 10. The system of claim 9, wherein the second computing device is identified in the swap request.

11. 10. The system of claim 9, wherein identifying the second computing device comprises: identifying, by the processor of the processing server, an identifier for each of a plurality of additional computing devices based on the network identifier; transmitting, by the transmitter of the processing server, the identifier for each of the plurality of additional computing devices to the first computing device; receiving, by the receiver of the processing server, from the first computing device, an identifier associated with the second computing device; Including, the system.

12. 10. The system of claim 9, wherein the swap request includes the first currency amount and the second currency amount.

13. 10. The system of claim 9, wherein the first currency amount and the second currency amount are the same amount.

14. 10. The system of claim 9, wherein the receiver of the processing server comprises: from the second computing device, first notification data associated with the first blockchain transaction; and second notification data associated with the second blockchain transaction from the first computing device; and Further receiving, the system.

15. 15. The system of claim 14, The first notification data and the second notification data are received prior to verifying the first blockchain transaction and the second blockchain transaction; The first blockchain transaction is verified using the first notification data; The second blockchain transaction is verified using the second notification data.

16. 10. The system of claim 9, wherein the processor of the processing server further calculates the second currency amount based on at least the first currency amount and an exchange rate associated with the second computing device.

Citation Information

Patent Citations

  • Transaction device, transaction method and transaction program

    JP2020048161A

  • Real-time cryptocurrency exchange using trusted hardware

    US20190156301A1

  • Trading Apparatus, And Trading Method

    US20200098042A1