Giter VIP home page Giter VIP logo

nucypher-core's Introduction

Cryptographic primitives, hosted on the decentralized nodes of the Threshold network, offering accessible, intuitive, and extensible runtimes and interfaces for secrets management and dynamic access control.

pypi pyversions codecov discord license


TACo Access Control

TACo (Threshold Access Control) is end-to-end encrypted data sharing and communication, without the requirement of trusting a centralized authority, who might unilaterally deny service or even decrypt private user data. It is the only access control layer available to Web3 developers that can offer a decentralized service, through a live, well-collateralized and battle-tested network. See more here: https://docs.threshold.network/applications/threshold-access-control

Getting Involved

NuCypher is a community-driven project and we're very open to outside contributions.

All our development discussions happen in our Discord server, where we're happy to answer technical questions, discuss feature requests, and accept bug reports.

If you're interested in contributing code, please check out our Contribution Guide and browse our Open Issues for potential areas to contribute.

Security

If you identify vulnerabilities with any nucypher code, please email [email protected] with relevant information to your findings. We will work with researchers to coordinate vulnerability disclosure between our stakers, partners, and users to ensure successful mitigation of vulnerabilities.

Throughout the reporting process, we expect researchers to honor an embargo period that may vary depending on the severity of the disclosure. This ensures that we have the opportunity to fix any issues, identify further issues (if any), and inform our users.

Sometimes vulnerabilities are of a more sensitive nature and require extra precautions. We are happy to work together to use a more secure medium, such as Signal. Email [email protected] and we will coordinate a communication channel that we're both comfortable with.

A great place to begin your research is by working on our testnet. Please see our documentation to get started. We ask that you please respect testnet machines and their owners. If you find a vulnerability that you suspect has given you access to a machine against the owner's permission, stop what you're doing and immediately email [email protected].

nucypher-core's People

Contributors

derekpierre avatar fjarri avatar jmyles avatar kprasch avatar piotr-roslaniec avatar theref avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

nucypher-core's Issues

Renaming things

Some of the terminology changed with the Threshold merge. Currently need renaming:

  • staker -> staking_provider
  • decentralized_identity_evidence - undecided, operator_signature? See what ends up being merged with nucypher/nucypher#2850
  • something else?

Support `serde` serialization to human-readable formats

Initially the objects in nucypher-core were only intended to be serialized in binary because we were only concerned with protocol objects. Recently an issue was raised on Discord about deserializing the JSON response from Porter with fields like

      {
        "checksum_address": "314CaB1F5e6731f14F1deb4413d76b09D68710CA",
        "encrypting_key": "033c8e562e959b70714c96ec65cfd74f35d29526f8e8b38d148e8551b702dfb581"
      },

It would be convenient if these field could be deserialized by serde into Address and PublicKey. There are two problems here:

  • Address's serde serialization for human-readable formats is the serde default, that is a list of integers. So it cannot be deserialized from the hex form above at all.
  • While PublicKey would deserialize fine, it may be better to have a 0x prefix in front of the hex representation, to match the Ethereum RPC format (and the same applies to Address).

Naturally, fixing that should be done in a consistent manner. There are several interconnecting issues (which also affect umbral), so the scope of the changes needs to be determined.

Several bytearray-like objects in nucypher-core (Address, FleetStateChecksum, HRAC and the third-party recoverable::Signature) use the custom arrays_as_bytes serialization. certificate_der field of NodeMetadataPayload uses serde_bytes. These will have to be modified to support human-readable formats. One way to do it is to expose the machinery from serde.rs in umbral and use it in nucypher-core. The problem is that it deals with objects that are represented as arrays with size known at compile time, so that may have to be changed.

operator_signature and certificate_der fields of NodeMetadataPayload may need to be wrapped in types so that we could impl Serialize/Deserialize for them. This way the Option<recoverable::Signature> that we need will be handled automatically, too. Now we need a special function in arrays_as_bytes.rs to handle it.

Should we care about human-readable serialization of protocol objects? How will versioning work in this case?

Implement a "slim" WASM packaging for `nucypher-core`

  • Implement an alternative "slim" export in the nucypher-core package for WASM-aware bundlers
  • Provides nucypher-core users with a lightweight (~33% smaller) alternative for "fat" export which contains base64-encoded inlined WASM
  • Consider merging the nucypher-core-wasm and nucypher-core-wasm-bundler directories on the back of this change
  • Refers to #83

Integrate and re-export ferveo for public API

Presently all ferveo-generated objects are handled as bytes. Instead, ferveo types can be implemented directly in dks.rs as well as the python/wasm bindings. This implies that ferveo provides a crate exporting it's python and wasm bindings for consumption in nucypher-core (nucypher/ferveo#87).

targets
  • ThresholdDecryptionRequest.ciphertext -> ferveo.api.Ciphertext
  • ThresholdDecryptionResponse.decryption_share-> ferveo.tpke.api.DecryptionShareSimple||DecryptionSharePrecomputed
  • NodeMetadataPayload.ferveo_public_key -> ferveo.common.keypair.PublicKey

Implement `ThresholdDecryptionRequest` and `ThresholdDecryptionResponse`

Requirements

Implement two new serde-versioned bytes-serializable entities for use in nucypher/nucypher and nucypher/nucypher-ts threshold decryption product (working title "tCBD"). Bob will use these entities to gather threshold decryption shares. Both python and WASM binding are needed.

Entities
  • ThresholdDecryptionRequest (ThRq)
    • ritual ID: int
    • ciphertext: ferveo.Ciphertext
    • conditions: Conditions
    • context: Context
  • ThresholdDecryptionResponse (ThRs)
    • share: ferveo.DecryptionShare

Notes

Use modules in WASM and Python bindings

  • Introduce wasm_bindgen(module = "ferveo/nucypher") in order to avoid naming conflicts between umbral.Ciphertext & ferveo.Ciphertext etc., in WASM bindings
  • Instead of relaying on prefixes (FerveoPublicKey, UmbralPublicKey, etc.) make sure that the naming conflicts are avoided by exposing types from their respective modules (ferveo.PublicKey, umbral.PublicKey).

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.