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

S3 doesn't work with literal IPv6 hosts #159

Open
juha-aiven opened this issue Nov 22, 2023 · 0 comments
Open

S3 doesn't work with literal IPv6 hosts #159

juha-aiven opened this issue Nov 22, 2023 · 0 comments

Comments

@juha-aiven
Copy link
Contributor

When using S3Transfer with host being an IPv6 address such as ::1 Rohmu fails. This can happen when using a "non-S3 S3" such as MinIO and IPv6.

The exact reason of the failure is here:

custom_url = f"{scheme}://{host}:{port}"

According to RFC 2732

To use a literal IPv6 address in a URL, the literal address should be enclosed in "[" and "]" characters.

Obviously, the code doesn't do this.

I tried with a simple change and Rohmu seems to work.

            custom_url = f"{scheme}://[{host}]:{port}"
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

No branches or pull requests

1 participant