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

Fix string type issues with SOAP/Twisted #685

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

Conversation

Neurones67
Copy link

Fix some issues found when trying to use Twisted with SOAP protocol in Python3

@arskom-jenkins
Copy link

Can one of the admins verify this patch?

@@ -183,7 +183,7 @@ def _reconstruct_url(request):
url_scheme = 'http'

uri = _decode_path(request.uri)
return ''.join([url_scheme, "://", server_name, uri])
return ''.join([url_scheme, "://", server_name, uri.decode('utf-8')])
Copy link
Member

Choose a reason for hiding this comment

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

How do we know that uri is encoded with utf-8 here?

Copy link
Author

Choose a reason for hiding this comment

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

I thought it was assumed as we create a "context" with utf-8 content type at line 676, but it concerns more the content than the headers.
The standard doesn't seem to allow other chars than ascii in URI during transmission, maybe it's better to decode as ascii rather than utf-8

Copy link
Member

@plq plq left a comment

Choose a reason for hiding this comment

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

the change in soap11.py is ok but i'm not sure about the other one.

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.

None yet

3 participants