GithubHelp home page GithubHelp logo

Comments (6)

donmendelson avatar donmendelson commented on June 18, 2024

The spec currently says:

For optional fields, a special mantissa value is used to indicate that a field value is null.

For efficiency, the value of the exponent need not be checked by a decoder if the mantissa is null.

However, I don't like the fact that the value of the exponent is non-deterministic. In my opinion, all values should be deterministic. That is, given the same semantic values, two encoders should produce exactly the same buffer. Also, failing to overwrite previous values in a buffer could leak information and pose a security risk. So it should always write something. I would be in favor of changing the spec to say that the exponent should also be set null. Do others agree?

from fix-simple-binary-encoding.

kleihan avatar kleihan commented on June 18, 2024

Agree. Did you mean to write "However, I don't like the fact that the value of the exponent is non-deterministic."?

from fix-simple-binary-encoding.

donmendelson avatar donmendelson commented on June 18, 2024

Thanks, Hanno. Corrected.

from fix-simple-binary-encoding.

RFrenkel avatar RFrenkel commented on June 18, 2024

Thank you, Don and Hanno!

So i take it the best practice is to set exponent also to null =127.

from fix-simple-binary-encoding.

donmendelson avatar donmendelson commented on June 18, 2024

I suggest that we edit the spec to say that this is recommended practice.

(BTW the spec says that character arrays should be padded with nulls for the same reason--a deterministic output.)

from fix-simple-binary-encoding.

RFrenkel avatar RFrenkel commented on June 18, 2024

Great, thank you!

from fix-simple-binary-encoding.

Related Issues (20)

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.