Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Backport newer serialization facilities from Bitcoin #1535

Merged

Commits on Sep 25, 2019

  1. Port Bitcoin allocators implementation

    This refactors the parts of the application that depend on the secure
    allocator and zero-after-free allocator. It replaces the structure to
    copy Bitcoin's file hierarchy. This updates the secure allocator with
    the newer memory swap prevention mechanism.
    cyrossignol committed Sep 25, 2019
    Configuration menu
    Copy the full SHA
    24ddd39 View commit details
    Browse the repository at this point in the history
  2. Use agnostic memory zeroing from Bitcoin

    This replaces the remaining OPENSSL_cleanse() calls with Bitcoin's
    memory_cleanse() function.
    cyrossignol committed Sep 25, 2019
    Configuration menu
    Copy the full SHA
    c78743d View commit details
    Browse the repository at this point in the history
  3. Port streams.h from Bitcoin

    Bitcoin moved the stream-like classes out of serialize.h into streams.h
    and added several new classes. This refactors the application to use the
    new file for code that uses the existing stream objects.
    cyrossignol committed Sep 25, 2019
    Configuration menu
    Copy the full SHA
    ec20ed7 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    530c302 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    8b0aa20 View commit details
    Browse the repository at this point in the history
  6. Port serialize.h from Bitcoin

    Bitcoin moved its stream classes out from serialize.h into streams.h.
    These changes update the application serialization and stream code to
    match Bitcoin's newer implementation with the following exceptions:
    
    - CSizeComputer retains nType for legacy code with type-dependent
      serialization (SER_NETWORK, SER_DISK, SER_GETHASH, ...)
    - The retention of serialization implementations for std::tuple
      for the deprecated accounting API
    
    The backport includes some new stream classes from Bitcoin not used in
    Gridcoin. We may refactor code to use these new classes in the future.
    cyrossignol committed Sep 25, 2019
    Configuration menu
    Copy the full SHA
    39bb55d View commit details
    Browse the repository at this point in the history
  7. Fix serialization for NN::Superblock::ProjectIndex hashing

    The ProjectStats convergence hint is not part of the superblock hash, so
    don't serialize the hint while hashing the superblock.
    cyrossignol committed Sep 25, 2019
    Configuration menu
    Copy the full SHA
    61b776b View commit details
    Browse the repository at this point in the history