airalab / robonomics_contracts Goto Github PK
View Code? Open in Web Editor NEWRobonomics contracts for Ethereum; Launched on the mainnet in 2019
License: BSD 3-Clause "New" or "Revised" License
Robonomics contracts for Ethereum; Launched on the mainnet in 2019
License: BSD 3-Clause "New" or "Revised" License
Good day,
I made a mistake to withdraw funds from Bilaxy Exchange to your adres.
Txid :
0xc5b05c9fea9569f5e9ca7cfe69e08e149dce0cd6c2bfcb3e4201b0f03875d599
from :
0x253ff8d3b639243e2c9c4a36a4c461aa7fc5fe0d
Number of XRT coins : 21.892052
Can you guys help me out?
Thanks in advance,
Roy
Finalize method fails for zero cost liabilities due to ERC20 transfer call with zero value.
Try to migrate for the doxity tool.
Currenly Core compiled with solc 0.2, at the first Core it's not compatible with solc 0.4 by code syntax features.
Add name and short desc for creating contract function.
The problem
In current state of network is possible scenario below:
Current message format have no tool to prevent this scenario.
Proposal
Extend messages with special field lighthouse
that fix message settle to only one lighthouse. The message can be encoded as lighthouse name
(on ENS) or as lighthouse address
(raw Ethereum address). For early implementation raw address is enough because in other case all message fields like a validator
or token
should be corce to namehash
format.
Affected
Сделать объекты Lot и Market смертным. А также пересобрать Market Builder в тестовой и основной сетях.
The problem
Currently used constant approach to gas price. But realistic value of gas price is very important for gas based token emission.
Proposal
Make gas price estimator based on tx.gasprice filtered by moving average(SMA, EMA, etc.).
Affected
closed
Access control list
system is alternative for onlyOwner
security check. We should discuss that and create model for ACL system.
Unable to append lot for buy asset by regulator:
https://github.com/airalab/core/blob/master/sol/market/DAOMarketRegulator.sol
So this is a feature of lot constructor: no way for creating lots with fractional price.
Place lot to buy asset:
Asset | Value | Price |
---|---|---|
potato | 10 | 50 |
This creates Lot with
Seller | Buyer | Sell | Buy | Value | Price |
---|---|---|---|---|---|
me | none | credits | potato | 10*50=500 | 1 / 50 = 0.02 |
It's price not looks good because real
types isn't supported by Solidity.
В функцию вывода добавить возможность сделать так, что бы при выводе генерировались и отправлялись на кошелек фонда дополнительные токены. Например мы хотим 26% от общих выпущенных токенов отправить фонду. Значит выпускаем дополнительно totalsold/76*26
A user accidently sent their XRT tokens to the actual XRT Contract address: https://etherscan.io/tx/0xa4a3226a4ac727f2787da0436a9bb372e03c6f4eed1cf1b2c0863294b0ebd5bb
They were hoping to use the exodus bridge so that they could begin staking.
It is possible to reinburse / compensate this user?
Motivation
A lot of new features in
Progress
tests
migrations
Affected
robonomics_contracts
@akru$ testrpc -v
EthereumJS TestRPC v3.0.0
$ node -v
v6.9.1
$ npm -v
4.0.2
Mikes-MacBook-Air-2:core mikefluff$ ./aira_deploy.js -O -C AddressList --library
Compile...
(compiled)
/Volumes/USB/prog/Ethereum/core/node_modules/solc/soljson.js:1
(function (exports, require, module, __filename, __dirname) { var Module;if(!Module)Module=(typeof Module!=="undefined"?Module:null)||{};var moduleOverrides={};for(var key in Module){if(Module.hasOwnProperty(key)){moduleOverrides[key]=Module[key]}}var ENVIRONMENT_IS_WEB=typeof window==="object";var ENVIRONMENT_IS_WORKER=typeof importScripts==="function";var ENVIRONMENT_IS_NODE=typeof process==="object"&&typeof require==="function"&&!ENVIRONMENT_IS_WEB&&!ENVIRONMENT_IS_WORKER;var ENVIRONMENT_IS_SHELL=!ENVIRONMENT_IS_WEB&&!ENVIRONMENT_IS_NODE&&!ENVIRONMENT_IS_WORKER;if(ENVIRONMENT_IS_NODE){if(!Module["print"])Module["print"]=function print(x){process["stdout"].write(x+"\n")};if(!Module["printErr"])Module["printErr"]=function printErr(x){process["stderr"].write(x+"\n")};var nodeFS=require("fs");var nodePath=require("path");Module["read"]=function read(filename,binary){filename=nodePath"normalize";var ret=nodeFS"readFileSync"
TypeError: cb is not a function
at /Volumes/USB/prog/Ethereum/core/lib/compiler.js:70:17
at /Volumes/USB/prog/Ethereum/core/node_modules/hash-files/lib/hash.js:69:4
at /Volumes/USB/prog/Ethereum/core/node_modules/async/lib/async.js:726:13
at /Volumes/USB/prog/Ethereum/core/node_modules/async/lib/async.js:52:16
at replenish (/Volumes/USB/prog/Ethereum/core/node_modules/async/lib/async.js:306:28)
at /Volumes/USB/prog/Ethereum/core/node_modules/async/lib/async.js:326:29
at /Volumes/USB/prog/Ethereum/core/node_modules/async/lib/async.js:44:16
at /Volumes/USB/prog/Ethereum/core/node_modules/async/lib/async.js:723:17
at /Volumes/USB/prog/Ethereum/core/node_modules/async/lib/async.js:167:37
at FSReqWrap.readFileAfterClose [as oncomplete] (fs.js:445:3)
Mikes-MacBook-Air-2:core mikefluff$ ./aira_deploy.sh -C Core -A '["MyDAO", "My first DAO"]'
Compile...
(cache)
Contract: Core
WARN: No libs loaded!
Binary size: 6.0859375K
Error: VM Exception while processing transaction: out of gas
at Object.InvalidResponse (/Volumes/USB/prog/Ethereum/core/node_modules/web3/lib/web3/errors.js:35:16)
at /Volumes/USB/prog/Ethereum/core/node_modules/web3/lib/web3/requestmanager.js:86:36
at request.onreadystatechange (/Volumes/USB/prog/Ethereum/core/node_modules/web3/lib/web3/httpprovider.js:110:13)
at dispatchEvent (/Volumes/USB/prog/Ethereum/core/node_modules/xmlhttprequest/lib/XMLHttpRequest.js:591:25)
at setState (/Volumes/USB/prog/Ethereum/core/node_modules/xmlhttprequest/lib/XMLHttpRequest.js:610:14)
at IncomingMessage. (/Volumes/USB/prog/Ethereum/core/node_modules/xmlhttprequest/lib/XMLHttpRequest.js:447:13)
at emitNone (events.js:91:20)
at IncomingMessage.emit (events.js:185:7)
at endReadableNT (_stream_readable.js:974:12)
at _combinedTickCallback (internal/process/next_tick.js:74:11)
The problem
It’s possible to create and use in liability opening the message from different senders and the same ‘messageHash’. This collision is can be used for rewriting messages by attacker.
Solution
Use sender address in message hashing scheme.
Affected
This is part of #49.
The problem
Observing network is a concept from Robonomics Whitepaper p5.5. Observing network can have very very different implementation. But interface for them should be strictly specified.
Basically for liability contract only one thing is important: the decision of observing network around liability result. For this reason I propose validator contract interface below.
/**
* @dev Observing network contract interface
*/
contract IValidator {
/**
* @dev Get decision of liability, is used by liability contract only
* @notice Transaction will fail when have no decision
*/
function decision() external returns (bool);
}
Method decision
should be called from liability smart contract in finalization procedure and result of this is decision around liability result report: observer agree or not agree with this result.
#ERC777 standard includes new #Ethereum functions, but, it goes a lot further and implements some very innovative features and implements an extensive range of transaction-handling mechanisms that #ERC20 users cannot enjoy...
При работе с контрактом через web3js есть проблема с массивами.
Хорошо-бы добавить геттер, который будет возвращать размер массива.
Сейчас возникла проблема с массивом group из контракта ACLStorage.sol
The Problem
Currently gas estimation isn't so effective. Moving gas estimation to Lighthouse
contract can be more effective because it closer to transaction entry point in most cases.
Changes
startGasEstimation
modifierendGasEstimation
modifierliabilityCreated
and liabilityFinalized
hooks for gas accountinggasUtilizing
-> gasConsumed
Affected
@akru how I can view lot data without adding lot contract in watch contract? - probably no way :) Can you create function for viewing lot data with market or agent or regulator contract?
@akru я подготовил материал, на основе которого можно начать исследование вопроса: http://ensrationis.com/smart-contract-security/
"Aira BuilderDAO" in "DAO factory" at address "0xa76422591378d14fb6d94c9da48a42498d8b51da" create DAO in that romoveModule method not work.
Moving @EvgenRad81 proposal from learning center issues.
I want to add counter fo
Core
modules and events for any modification of module structure(adding, removing).
When #52 will implemented is possible to add order cancellation method to factory contract. Typically cancel
can be called by order sender when sender wants to force disallow liability creation with him message. Currently we have no method to force close order excluding deadline
, but it's motive to spam network with too short lifetime messages.
необходимо имплементировать вот этот протокол https://github.com/Matchpool/contracts/blob/master/contracts/Contribution.sol
Вкратце, что я понял:
1)игрок отправляет seed
2) держатель банкрола (не контракт) забирает seed из контракта
3) подписывает ее закрытым ключем (я проверил метод в JS ethUtil.ecsign из EthereumJS) и отправляет эту подпись обратно в контракт (и дополнительные данные r,s,v для валидации подписи)
4) контракт проверяет, что хеш прислал именно держателем банкрола, и что подписан именно seed клиента через функцию ecrecover
5) собно полученный хеш пропускаем через uint(hash)%maxnum; и получается число от 0 до maxnum.
пример https://gist.github.com/noxonsu/82eff25bf0c537dce1a331b0b8863137
Smart contract with set of validator is more flexible way to implement validators network.
Proposal
IValidator
should implement special method that returns true
when argument address is in validator set.
Any address from validator set can finalize liability when validator contract is set for liability contract.
The problem
Currently Robonomics blockchain infrastructure isn't have strict specification. It's mean that it have a big changes between releases. The main aim of this proposal is making Robonomics smart contracts more stable.
The approach providen here is making Robonomics smart contract interfaces and architecture reference. Robonomics blockchain interfaces
is a set of solidity contracts that contains methods and states of smart contract as minimal as it possible. It placed at robonomics_contracts/contracts/robonomics/interface
. All things of this should be documented so well and should not be changed without necessity.
Affected
According to https://github.com/airalab/core/blob/master/sol/lib/Voting.sol:
no way to multiple voter for one target, they vote not accounting by shifting
mechanysm.
Possible to refactoring
Possible DoS by setting too long duration in proposal.
The Problem
KYC is required for using auction and ambix contracts.
Using https://github.com/OpenZeppelin/openzeppelin-solidity/blob/master/contracts/drafts/SignatureBouncer.sol looks a good solution for this issue.
Affected
Current flat implementation of Market
contract isn't scalable and have strong performance issues.
In my opinion is needed to prepare scalable market requirements and model.
Desc: I was tried to use Congress builder twice with null in field _client and fill this field with my address, but owner and first congress member was "The Blockchain Congress builder "
Builded contract example: 0xb9accd738d7b9ef0a04d2a4f24833f7a9b1b4e9e
Type: The Blockchain Congress
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.