1. 30 8月, 2017 1 次提交
  2. 17 8月, 2017 1 次提交
    • N
      Resolve #153: Make irrelevant sigs a soft check · 9781e5ef
      Nathan Hourt 提交于
      Previously, all nodes rejected transactions with irrelevant signatures
      always. Now, this is still true, except if a transaction with irrelevant
      signatures is included in an otherwise valid block: then the transaction
      is accepted even though it fails the soft check.
      9781e5ef
  3. 16 8月, 2017 2 次提交
  4. 11 8月, 2017 1 次提交
  5. 10 8月, 2017 1 次提交
  6. 08 8月, 2017 2 次提交
    • N
      Ref #7: Progress towards auth · 9ad3260d
      Nathan Hourt 提交于
      We now check authorization of transactions when they come in as pending,
      and again when we apply them in some block (either when generating the
      block or when applying it). When applying the transactions in a block,
      we check auth for all transactions in the block prior to processing any.
      
      To check auth, we first scan all of the declared authorizations, and
      check that the authorization is sufficient to grant permission for the
      given account to execute the given message type (TODO: look up the
      actual required permission level rather than just assuming it's
      'active'); then, check that the transaction bears signatures to confer
      the declared authorization.
      9ad3260d
    • B
  7. 25 7月, 2017 1 次提交
  8. 29 6月, 2017 1 次提交
    • N
      Update naming in test framework · 6c4e89f3
      Nathan Hourt 提交于
      The testing framework still used "database" to refer to the blockchain, which doesn't make sense since we split the blockchain class from the database class. This commit updates the names/docs in the
      test framework to use chain instead of database as appropriate.
      6c4e89f3
  9. 24 6月, 2017 1 次提交
    • N
      Ref #19: Preparation for proxied voting · 0bd3bc84
      Nathan Hourt 提交于
      Define types, objects, and indexes necessary for proxied voting on
      producers. Also, perform some necessary refactoring, as the old code
      assumed the only way votes could be cast would be direct, not by proxy.
      0bd3bc84
  10. 22 6月, 2017 2 次提交
    • N
      Ref #19: Update round in generate_block · 0688238c
      Nathan Hourt 提交于
      Now we calculate the round changes and store them in generate_block.
      0688238c
    • N
      Ref #19: Progress, tests · 37e32542
      Nathan Hourt 提交于
      Progress:
      - When an account adds/removes stake, we now update votes for its
      approved producers
      - Name map<AccountName, AccountName> as RoundChanges, and define
      operator- such that RoundChanges = ProducerRound - ProducerRound
      
      Test the vote updates, making sure that producer votes are updated when
      an account adds stake
      
      TODO: Calculate the producer round changes in generate_block and add to
      block header
      37e32542
  11. 15 6月, 2017 1 次提交
    • N
      Small Refactors · cb13ff0d
      Nathan Hourt 提交于
      - Rename config::ProducerCount -> config::BlocksPerRound
      - Add new config::VotedProducersPerRound = 20
      - Split up staked_balance_objects.hpp moving ProducerVotesObject to
      producer_objects.hpp
      cb13ff0d
  12. 14 6月, 2017 2 次提交
  13. 13 6月, 2017 1 次提交
  14. 09 6月, 2017 1 次提交
    • N
      Exodus of Genesis · 55a84709
      Nathan Hourt 提交于
      OK, so this turned out to be a **massive** refactor that I thought I'd
      never finish, and no, I don't remember everything that changed here, but
      I think it all worked out to be better than before, and almost all of it
      was fairly necessary/the best of available options. Whew. I am SO glad
      this is finally done.
      
      High level goal: Continue refining the native contracts (ref #15),
      specifically
      walling off their state into their own contract DBs rather than globally
      shared (read: stuff that race conditions are made of) general blockchain
      state.
      
      The first real change I made in this commit, which precipitated the
      avalanche of changes that followed before the project became consistent
      again, was to move the account balance out of account_object (globally
      shared) to an object known only to the Eos Contract, thus eliminating
      the possibility of race conditions/nondeterministic behavior.
      
      The trouble is, balances are set at genesis. Genesis is processed by
      chain_controller. chain_controller cannot know about balances, since
      those are an abstraction defined on top of the Eos contract, which is an
      abstraction defined on top of chain_controller. So all of genesis had to
      be reimagined, and quite a lot of architectural changes had to be made
      in order to create a logically consistent solution.
      
      Changes (probably incomplete):
       - Fix up notifications within the native contract to support
      precondition validation as well as application
      
       - Add notify handlers for CreateAccount to Eos and Staked Balance
      contracts
      
       - Move account's liquid balance of EOS from account_object to
      BalanceObject
      
       - Replace {producer,account}_object::id_type with AccountName most
      everywhere except block_header, which still contains a
      producer_object::id_type (potentially in violation of protocol
      standards, but I want to confirm that before fixing it)
         - Reason: The name is not significantly slower, as it's fixed length so
      no heap allocs, and it simplifies the code in quite a few places by
      allowing us to look up objects directly rather than indirectly by
      looking up an ID to get an intermediate object to get a handle for the
      object we really wanted
      
       - Replace native_system_contract_plugin with native_contract library
         - Reason: The plugin was getting in the way. The native system
      contract C++ implementation is simply too fundamental unless/until we
      have a scripted implementation that works until the native
      implementation gets installed
      
       - Completely reimagine genesis initialization, taking it largely out of
      the hands of chain_controller and putting it in the hands of
      native_contract
         - Reason: chain_controller understands relatively little about
      genesis. It understands global_property_object and producer_object, but
      not BalanceObject or StakedBalanceObject, etc... It also doesn't
      understand the native_contract, and things like installing the native
      contract, setting up accounts/balances, etc. all need to be handled by
      something... native_contract is the most logical place to put it.
      
      Sorry for the enormous commit... alas, this was the first time I got it
      all building again and passing tests in days.
      55a84709
  15. 29 5月, 2017 1 次提交
    • N
      Refactor Complete · 842ef395
      Nathan Hourt 提交于
      This completes the refactor (to a buildable/tests passing state) from my
      last commit.
      842ef395
  16. 26 5月, 2017 1 次提交
    • N
      Rename: database->chain_controller · 1c6d3f7b
      Nathan Hourt 提交于
      Rename database class to chain_controller, as this class manages
      blockchain state and operations. Database was a misnomer.
      
      Next step: make chain_controller a free-standing class, rather than
      having it inherit from chainbase::database. This should give us a better
      architecture, especially for testing, going forward.
      1c6d3f7b
  17. 27 4月, 2017 1 次提交
    • N
      Move system contract impl to plugin · 20d9c9b8
      Nathan Hourt 提交于
      The system contract C++ implementation is now in a plugin rather than
      directly on database.
      
      Note that testing_database installs this implementation on the testing
      database, even though the test framework does not use appbase or appbase
      plugins.
      20d9c9b8
  18. 26 4月, 2017 1 次提交
    • N
      Resolve #13: Fix simulated network propagation · 288f489e
      Nathan Hourt 提交于
      The simulated network was recursively calling push_block when
      propagating blocks, which caused a lock timeout. Fix this issue by not
      pushing a new block to the database that created it.
      
      Also, replace the currently_propagating_block flag with boost's slot
      blocker.
      288f489e
  19. 22 4月, 2017 1 次提交
  20. 20 4月, 2017 2 次提交
  21. 14 4月, 2017 2 次提交
  22. 07 4月, 2017 2 次提交
  23. 06 4月, 2017 2 次提交
    • N
      More test framework, test cases · 4faabfe6
      Nathan Hourt 提交于
      Add a testing_network class to emulate a P2P network ferrying blocks
      between databases.
      
      Add some test cases exercising databases syncing with the
      testing_network and resolving forks.
      4faabfe6
    • N
      Initial commit · e03269e8
      Nathan Hourt 提交于
      e03269e8