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

PrivateKey.generate() doesn't respect ocap discipline #50

Open
dckc opened this issue Mar 14, 2020 · 2 comments
Open

PrivateKey.generate() doesn't respect ocap discipline #50

dckc opened this issue Mar 14, 2020 · 2 comments

Comments

@dckc
Copy link

dckc commented Mar 14, 2020

It uses ambient authority to a source of randomness; I like to stick to ocap discipine, so I'd like to see the source of randomness passed in explicitly as an argument.

PrivateKey.generate()

@zsluedem
Copy link
Collaborator

Tbh, I am actually not familiar with ocap discipline. Do you have any docs or references about that?

What about the from_seed method?

PrivateKey.from_seed(1)

@dckc
Copy link
Author

dckc commented Mar 14, 2020

yes, from_seed has no non-determinism; it respects ocap discipline.

capabilities are like unforgeable names in the RChain architecture (cf. Policies as Types cited from rchain dev docs). Python doesn't enforce ocap discipline like rholang does, but the discipline is useful even as a convention.

a pretty good reference is http://erights.org/elib/capability/ode/ode-capabilities.html
for application to python: https://www.madmode.com/2019/python-eng.html

p.s. feel free to stand by until I find time to make a PR for this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants