swaponline / sips Goto Github PK
View Code? Open in Web Editor NEWSwap.online Improvement Proposals
Swap.online Improvement Proposals
Заменить подпись через адрес data.eth на data.identity
data: {
identity: { address: '0x1DEN717Y' },
eth: { address: '0xAbCDeF' },
btc: { publicKey: '000ffff', address: 'MgMg..' },
}
Чтоб можно было в .eth класть любой адрес, метамаск или внешний кошелек. Это нужно, чтоб избавиться от destinationSellAddress
, destinationBuyAddress
в ордере.
Currently, Flows are not very stable. For example, you can get into the state where you should know secret, but somehow it's null
. We should make Flows more obvious in the sense of data flow before releasing and having real money and users' headaches at stake.
Main UX obstacles are:
Main security obstacles:
user lost a Swap ID – this goes to SwapHistory issue.
second party left right after signing and I dont know that
I froze my money, I should have all the values so I can get them back
bad connection to server, I am not sure if money were sent
I froze money, but second party left away – can I refund?
we both froze our money – how can I be sure it is? double-check
I am ready to withdraw, but I don't know
ETH owner had lost a secret key, but his ETH were withdraw already
Given the above, we have next steps:
For brevity and polimorphism we call BTC = base, ETH = secondary
Both know only the participant address and amounts to send.
We cannot leave this step until both agree on continuing swap.
This step should check the balances for everyone. Double-check you have money you claim to have.
Submit secret method goes here.
BTC owner should froze his money.
The shared state adds script address and exact values.
We cannot leave until both know these.
ETH owner also checks the frozen balance is just equals to what was expected.
ETH owner locks funds on the smart contract.
This step has no additional data. That's only he should send message, that funds are ready.
BTC owner doesnt leave until he knows exactly that contract has the right balance, and the hash matches.
ETH owner does not leave until BTC owner leaves.
BTC owner does not leave this step until ETH were transferred to his account.
ETH owner does not leave until he receives the message that ETH were withdrawn
Although he has everything he needs, BTC owner waits for message to mark swap as finished.
ETH owner cannot leave the step until he makes a successful withdraw tx.
Поустпил запрос от неопределенных личностей на возможность работы через тор. Сейчас IPFS не грузится в торе, какие есть варианты и решения
Прошу обсудить идею (назовем данный тикет не issue а неким Implementation Flow Improvement Proposal)
Создать список чекбоксов, где каждый чекбокс описывает конкретный принцип, требование или тест имплементации протокола, которые должны быть выполнены или соблюдены перед тем как имплементация свопа конкретной пары пошла в мейннет.
Каждый чекбокс при этом отмечается по мере имплементации свопа между конкретной парой.
Каждый чекбокс должен содержать назавание принципа/требования/теста и ссылку на более подробное описание, мотивацию и обоснование, возможно с примерами имплементации.
Для каждой версии протокола обмена у нас будет своя версия такого списка. При этом каждый чекбокс может тоже иметь свою версию.
This is a checkbox list for implementation of atomic swap of dogs for cats version 1.0
Из более реальных примеров чекбокосов:
При этом при создании тикета на имплементацию свопа конкретной пары, всегда будет висеть шаблон, в котором уже будет иметься checkbox list самой актуальной на данный момент версии
Чекбоксы могут быть разделены на milestones. То есть у каждой имплементации может быть разная глубина. Например - только Basic Swap имплементация - бесплатный медленный своп (то как это происходит сейчас), Faster Swap имплементация - ускоренный своп, когда маркет тейкер подписывает сразу 2 транзакции (send + claim), Destination Address - фича с кастомным адресом назначения, Prepaid Claim фича - платный когда мы сами оплачиваем "claim" своим эфиром итд итп...
Если мы делаем вышеописанное, неплохо было бы сделать страничку публичную, которая имеет список всех криптовалют, а так-же всех пар и на каждую из пар было бы круто видеть в реальном времени статусы имплементации, сгенерированные прямо из гитхабовских issues с боксами.
Что то типа swapready.net только наш собственный
We need support for steem and SBD. account creation on steem requires Resource credits or 3 steem.
Right now you make a poor user remember two keys. One ethereum, and one bitcoin. This needs to be fixed. Both blockchains are using the same private key algos: secp256k1. According to bitcoin ():
Range of valid ECDSA private keys
Nearly every 256-bit number is a valid ECDSA private key. Specifically, any 256-bit number from 0x1 to 0xFFFF FFFF FFFF FFFF FFFF FFFF FFFF FFFE BAAE DCE6 AF48 A03B BFD2 5E8C D036 4140 is a valid private key.
The range of valid private keys is governed by the secp256k1 ECDSA standard used by Bitcoin.
According to Ethereum (https://etherworld.co/2017/11/17/understanding-the-concept-of-private-key-public-key-and-address-in-ethereum-blockchain/):
Ethereum key generation is based on elliptical curve ecp256k1. Elliptical curve (EC) is intense mathematics, and there are a lot of great articles on the internet covering deep details of the elliptical curve. There are standard libraries to generate Ethereum key pair in a much safer way. In this article, just for demonstration, I will use elliptical curve Javascript library to perform elliptical curve operations.
The only difference right now is that your ethereum private key is represented in Hex format, and your bitcoin private key is in Wif format (that can be easily derived from hex format) like this:
https://en.bitcoin.it/wiki/Wallet_import_format
Now I suggest using Wif format ONLY for the private key because it contains a checksum. Then derive Ethereum private key from it. It should be straightforward. It is just a number in a range. I think either script to generate a private key will do. Bitcoin or Ethereum.
In order to make things more secure and avoid collisions, we may want to use Derived Keys (HD) for the blockchains.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.