GithubHelp home page GithubHelp logo

Comments (6)

nikkolasg avatar nikkolasg commented on May 1, 2024

So when I put the serverNameOverride to "", the tests fail with

authentication handshake failed: x509: cannot validate certificate for 127.0.0.1 because it doesn't contain any IP SANs

Since it's explicitely stated as a testing method, I figure we need to remove that call to NewClientTLSFromFile and separate that "testing logic" from the main logic, while still being reachable from the main command line, because I need to be able to indicate custom certificates on the cli flags to run the docker test.

Basically, that would require separating the method creating new connections into two, and have two ways of a creating a GRPC client: regular one that will not even need TransportCredentials since it will use the OS root trust store, and one that uses this NewClientTLSFromFile.

from drand.

nikkolasg avatar nikkolasg commented on May 1, 2024

I'll try to see what I can come up with this week, but that's gonna take a little bit of time though, so I can't promise anything.

from drand.

mahrud avatar mahrud commented on May 1, 2024

I think only serverNameOverride is for testing, not the method itself.

I can think of a couple of simpler ways that don't require two separate calls. One is to separate the port number as its own parameter for each node, the other is to have an optional parameter that is the SNI.

I'm working on a branch with a few fixes, I can implement this and let me know if it doesn't pass the tests.

from drand.

nikkolasg avatar nikkolasg commented on May 1, 2024

I've come up with a way to disable the serverNameOverride ( = ""): I found out that the third party library I use to generate on the fly certificates did not add correctly the IP SANS when I gave the IP address of a node so it was added as a regular DNS name. I'm working on a PR to fix that, should be done soon.

from drand.

nikkolasg avatar nikkolasg commented on May 1, 2024

Hopefully #44 should have solved the problem, let me know if you have still issues with it otherwise feel free to close it.

from drand.

mahrud avatar mahrud commented on May 1, 2024

It seems to be working, thanks!

from drand.

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.