Code Monkey home page Code Monkey logo

basic-attention-token-crowdsale's Introduction

Introducing a decentralized, transparent digital ad exchange based on Ethereum Blockchain.

Problem:

Digital advertising is broken. The marketplace for online advertising, once dominated by advertisers, publishers and users, has become overrun by "middleman" ad exchanges, audience segmentation, complicated behavioral and cross-device user tracking, and opaque cross-party sharing through data management platforms. Users face unprecedented levels of malvertisements and privacy violations. Mobile advertising results in as much as $23 per month in data charges on the average user’s data plan, slow page loads, and as much as 21% less battery life. In response, over 600 million mobile devices and desktops (globally) employ ad blocking software and this number is growing. Traditional publishers have lost approximately 66% of their revenue over the past decade, adjusted for inflation. Publishers face falling revenue, users feel increasingly violated, and advertisers’ ability to assess effectiveness is diminished.

Solution:

The solution is a decentralized, transparent digital ad exchange based on Blockchain.

The first component is Brave, a fast, open source, privacy-focused browser that blocks third party ads and trackers, and builds in a ledger system that measures user attention to reward publishers accordingly.

Second component is BAT (Basic Attention Token), a token for a decentralized ad exchange. It compensates the browser user for attention while protecting privacy. BAT connects advertisers, publishers, and users and is denominated by relevant user attention, while removing social and economic costs associated with existing ad networks, e.g., fraud, privacy violations, and malvertising. BAT is a payment system that rewards and protects the user while giving better conversion to ad vertisers and higher yield to publishers. We see BAT and associated technologies as a future part of web standards, solving the important problem of monetizing publisher content while protecting user privacy.

To learn more please visit https://basicattentiontoken.org/

Contact

If you have questions please send us an email at [email protected] or join our slack channel at http://slack.basicattentiontoken.org/

basic-attention-token-crowdsale's People

Contributors

bradleyrichter avatar evq avatar locklin avatar nfnty avatar thypon avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

basic-attention-token-crowdsale's Issues

BAT testnet token sale should use Rinkeby

The BAT testnet token sale uses the Ropsten testnet, which is extremely slow right now due to DoS attacks and mining spam. Transactions routinely take days to clear, and it is therefore difficult to both receive Ropsten faucet ether, and also to spend it.

A better testnet to use and advertise on the website would be Rinkeby, for both funders and the contract devs to test out the contract in advance of the real sale on Wednesday.

I've deployed BAToken.sol here on Rinkeby, to end at block 280741 (about one day from the create date of this issue). Anyone is free to use for testing:

https://rinkeby.etherscan.io/address/0x6f036e95c0503f3456059b8a6ec5c81a6d7bfdfa

msg.value is in wei, tokenExchangeRate expects ether

This line of the token creation function creates tokens at the specified exchange rate when users pay into the contract.
https://github.com/brave-intl/basic-attention-token-crowdsale/blob/master/contracts/BAToken.sol#L55

The comment where the exchange rate is declared implies that 1 ether should get 8000 BATs.

I've deployed this contract to Rinkeby here:
https://rinkeby.etherscan.io/address/0x6f036e95c0503f3456059b8a6ec5c81a6d7bfdfa

and tested it with these geth commands.

> batokenInstance.ethFundDeposit()
"0x83fa180e1557b6598b15d2de154bbef657f8fafe"
> batokenInstance.batFundDeposit()
"0x83fa180e1557b6598b15d2de154bbef657f8fafe"
> batokenInstance.createTokens({from: eth.coinbase, value: 1})
"0xcd053194880ff6f6ab1ab8af85eaffbe858fe948a7cca88f1f86c1fdaa0180c7"
> batokenInstance.balanceOf(eth.coinbase)
8000

After paying in 1 wei, I get 8000 BATs, which is not the intended amount.
For 1 wei, I should get 8000 / 10e18 BATs, which would be rounded down to 0 since the variable balances is a map of address to type unit256.

Capitalize constants

    uint256 public constant batFund = 500 * (10**6) * 10**decimals;   // 500m BAT reserved for Brave Intl use
    uint256 public constant tokenExchangeRate = 5500; // 5500 BAT tokens per 1 ETH: THIS MAY CHANGE AT DEPLOY TIME
    uint256 public constant tokenCreationCap =  1500 * (10**6) * 10**decimals; 
    uint256 public constant tokenCreationMin =  750 * (10**6) * 10**decimals; 

Consider capitalizing constants to improve readability when they are used.

http://solidity.readthedocs.io/en/develop/style-guide.html#constants

Constants should be named with all capital letters with underscores separating words. (for example:MAX_BLOCKS)

(This would also be more in line with conventions in other languages.)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.