Comments (5)
Can you explain what fails in https://github.com/w3f/schnorrkel/blob/master/src/serdey.rs please? A priori I'd expect visit_seq
should fail when invoked upon a simple byte array because that's what visit_bytes
does, no?
Appears ed25519-dalek used serde_bytes without using Bytes
anyplace.
from schnorrkel.
I don't understand why the issue was closed...?
There's nothing failing in serdey per se, it's just that not all format specialise sequence of bytes as just bytes, json being one of those...
This poses an issue with the current implementation during deserialization, with the reported error, where a sequence is encountered but serdey doesn't handle it
from schnorrkel.
I just pressed the wrong button due to it being late..
Do we need a serde_bytes feature like ed25519-dalek added? If so, we're basically replaying dalek-cryptography/ed25519-dalek@69eccda yes? I'll accept a PR for that of course.
from schnorrkel.
There's a problem in implementing the deserialization part, namely a BytesBuf
becomes somewhat necessary if you want sequence support since Bytes
doesn't implement visit_sequence
, probably since the size is now known so you'd need to allocate.
I'm probably gonna impl with Bytes
and if alloc
is provided as feature then use ByteBuf
instead
from schnorrkel.
I think a serde_bytes feature flag sounds good, mostly because ed25519-dalek did so.
from schnorrkel.
Related Issues (20)
- Version 0.9.2 breaks semver HOT 6
- `getrandom` feature should enable `rand_core/getrandom` HOT 9
- Implement Schnorr half aggregation HOT 1
- Keypair::vrf_sign ignores (partially) passed RNG HOT 6
- ThinVRF HOT 3
- Remove serde? HOT 4
- Is soft public key derive ready for production usage? HOT 3
- failed to verify signatures generated by `polkadot-js` HOT 10
- What Is The Signing Context For? HOT 4
- How to use musig? HOT 2
- Adopt the new secret key interface HOT 1
- Verify schnorrkel vrf on EVM HOT 1
- Build fails: `rand_core` doesn't have feature `nightly` HOT 2
- Add rand back HOT 2
- The code compile Error from_bits not found HOT 3
- Update from curve25519-dalek 4.0.0-rc2 to 4.0.0 and release 0.11 HOT 3
- Fix aead
- v0.11 doesn't compile in no-std mode HOT 2
- Broken `no_std` because of `rand/std_rng` HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from schnorrkel.