Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

enforce lowlevel ciphers for legacy environments by ctx.set_ciphers #21

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

MisterMountain
Copy link
Member

fixes #20

@@ -171,6 +171,7 @@ def get_data(base_url, timeout, insecure):
# Default context for connection
ctx = ssl.create_default_context()
if insecure is True:
ctx.set_ciphers("DHE-RSA-AES256-GCM-SHA384:@SECLEVEL=1")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any reason for this specific cipher?

If possible, we want to use something as broad as possible, that works for everyone

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I took this specific cipher due to the output of openssl s_client --connect smsgw1.invalid.local:443 --cipher 'ALL:@SECLEVEL=1'

However, i am pretty sure any of the ciphers on the medium level would fit:
image

https://docs.brevis.one/current/de/Content/Installation/Setting%20Up%20the%20Gateway/General%20configuration.htm

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that might be too specific for your use case/

Suggested change
ctx.set_ciphers("DHE-RSA-AES256-GCM-SHA384:@SECLEVEL=1")
ctx.set_ciphers("ALL:@SECLEVEL=0")

If we can do something like this, that would probably work for most users.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: --ssl-insecure does not allow small diffie-hellman keys
2 participants