Coder Social home page Coder Social logo

SSL/TLS support about riemann-ruby-client HOT 7 CLOSED

riemann avatar riemann commented on August 19, 2024
SSL/TLS support

from riemann-ruby-client.

Comments (7)

eric avatar eric commented on August 19, 2024

I believe that ruby establishes a connection when TCPSocket.new() is called.

Some of the changes you made appear to thwart the existing logic that implements timeouts on establishing connections.

Instead of overriding blank_socket, you may be better off wrapping connect_nonblock with your SSL logic and return the SSL socket from the socket method in your SSLSocket implementation.

from riemann-ruby-client.

nukemberg avatar nukemberg commented on August 19, 2024

great input, i re-wrote as per your suggestions, much better now. There are still OpenSSL constants in TcpSocket unfortunately - i could override readpartial and write but that seems excessive.

from riemann-ruby-client.

eric avatar eric commented on August 19, 2024

My thought would be that it would make more sense to override the methods instead of including exceptions in a class that isn't relevant.

from riemann-ruby-client.

nukemberg avatar nukemberg commented on August 19, 2024

Makes sense. Another question regarding Riemman::Client interface: do we want to have the TLS client exposed under client.tcp? the current implementation which automatically chooses between UDP and TCP will probably be useless for people using TLS and client.tcp may confuse people.

from riemann-ruby-client.

nukemberg avatar nukemberg commented on August 19, 2024

I added spec tests, however, i'm not sure if I sure if I should save the certificates in fixtures as at least the ca should match riemann instance certificates. How is testing done? i don't see the test config of riemann in the repo

from riemann-ruby-client.

jamtur01 avatar jamtur01 commented on August 19, 2024

@avishai-ish-shalom Want to submit this as a PR and we'll do from there?

from riemann-ruby-client.

jamtur01 avatar jamtur01 commented on August 19, 2024

Closed in favor of #24.

from riemann-ruby-client.

Related Issues (11)

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.