GithubHelp home page GithubHelp logo

Comments (5)

adiroiban avatar adiroiban commented on September 26, 2024 1

Thanks for the report.

I am not sure that serverFromString is designed to provide such a level of customization.

In all my use cases, I am using serverFromString only for quick testing code. Never in production, where it needs a high degree of configuration.


Can you suggest what would be the expected string that will include custom ciphers?

OpensSSL cipher configuration is something like this HIGH:!PSK:!RSP:!eNULL:!aNULL:!RC4:!MD5:!DES:!3DES:!aDH:!kDH:!DSS ... but we already use the colon (:) as a separator ... maybe use a comma

ssl:443:privateKey=key.pem:certKey=crt.pem:cipher=HIGH,!PSK,!DSS


Feel free to summit a PR with a possible solution for this.

Regards

from twisted.

glyph avatar glyph commented on September 26, 2024 1

I am not sure that serverFromString is designed to provide such a level of customization.

Design-wise, any static configuration like this should be doable from the Twisted-provided plugins for serverFromString. The one place where extra customization for serverFromString is out of scope would be things like per-connection state or changing parameters based on the peer; basically if you need to run Python code to figure out your parameters you need to use a different API, we shouldn't have Python functions to call stuffed into the string. But a static ciphersuite selection string is a perfectly reasonable parameter to have in there.

(I will say that for most users we should be providing good defaults and strongly encouraging usage of those defaults so we can evolve them to be up-to-date in terms of consensus security practices, but it sounds like @KaviHarjani has a very clear and specific idea of what they want here)

from twisted.

KaviHarjani avatar KaviHarjani commented on September 26, 2024

Hey guys this is my first open-source contribution
Thank you for giving me this opportunity @glyph @adiroiban
I didn't make many changes but the tests seem to have been failing for Windows and Macos

Could you guys help me here

from twisted.

glyph avatar glyph commented on September 26, 2024

thank you @KaviHarjani !

from twisted.

glyph avatar glyph commented on September 26, 2024

Could you guys help me here

The failures that you are pointing at are not on Windows & macOS, they are failures on every platform that runs with SSL. The message, twisted.trial.unittest.FailTest: (<twisted.internet.endpoints.SSL4ServerEndpoint object at 0x7f8a4e0add00>,) is not an instance of <class 'twisted.internet.endpoints.SSL4ServerEndpoint'> , is showing you that the object you are asserting about is a 1-element tuple containing the endpoint rather than the endpoint itself.

from twisted.

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.