Code Monkey home page Code Monkey logo

Comments (4)

murgatroid99 avatar murgatroid99 commented on June 13, 2024

gRFC L35 proposes an API to expose this information to the application. PR #508 would have implemented it in the old Node gRPC library, but clearly it was never resolved. The implementation work for grpc-js just never happened.

That gRFC has a relatively restricted API because of constraints that no longer apply, namely needing to handle the intersection of the two libraries. At this point, that proposal could probably be modified to be more expressive in grpc-js in ways that are incompatible with the old library.

from grpc-node.

davidfiala avatar davidfiala commented on June 13, 2024

Thanks for the note. Seems like there is agreement that something should exist. :)

At the risk of sidetracking, but since it wasn't implemented yet: I'd ask whether we there's openness also to reconsider the implementation regarding passing raw cert buffers around. My thought is that for a server under load it wouldn't be ideal to decode the same cert multiple times per call or risk double copies of Buffers if that were to end up happening. Exposing the Http2Session or it's net.Socket | net.TLSSocket directly could allow for further flexibility for the developer to have useful information even on non-TLS connections. My big ask though is simply to have a performant way to get at the data, without being too prescriptive.

WDYT?

from grpc-node.

murgatroid99 avatar murgatroid99 commented on June 13, 2024

That's why I meant by modifying the proposal to make the API more expressive. For example, it could contain the full output of tlsSocket.getPeerCertificate, instead of just the raw cert. As I said, that limitation was the result of previous constraints that no longer apply.

from grpc-node.

davidfiala avatar davidfiala commented on June 13, 2024

Hi- I put together some thoughts here: grpc/proposal#440

from grpc-node.

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.