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

[ipfs/go-ipfs-files] Fix encoding of filename in Content-Disposition #29

Open
Stebalien opened this issue Dec 11, 2018 · 4 comments
Open
Labels
kind/bug A bug in existing code (including security flaws)

Comments

@Stebalien
Copy link
Member

We should use RFC5987 to encode the filename in the Content-Disposition header. GO will already gracefully handle line-breaks but we should still be escaping better.

@Stebalien Stebalien added the kind/bug A bug in existing code (including security flaws) label Dec 11, 2018
@hacdias hacdias transferred this issue from ipfs/go-ipfs-files Jan 13, 2023
@hacdias hacdias changed the title Fix encoding of filename in Content-Disposition [ipfs/go-ipfs-files] Fix encoding of filename in Content-Disposition Jan 13, 2023
@welcome
Copy link

welcome bot commented Jan 13, 2023

Thank you for submitting your first issue to this repository! A maintainer will be here shortly to triage and review.
In the meantime, please double-check that you have provided all the necessary information to make this process easy! Any information that can help save additional round trips is useful! We currently aim to give initial feedback within two business days. If this does not happen, feel free to leave a comment.
Please keep an eye on how this issue will be labeled, as labels give an overview of priorities, assignments and additional actions requested by the maintainers:

  • "Priority" labels will show how urgent this is for the team.
  • "Status" labels will show if this is ready to be worked on, blocked, or in progress.
  • "Need" labels will indicate if additional input or analysis is required.

Finally, remember to use https://discuss.ipfs.io if you just need general support.

@kstuart
Copy link

kstuart commented Jan 23, 2023

@Stebalien do you mean in multiFileReader? The filename is encoded using url.QueryEscape so should be encoded according to standards.

Test added in this commit: 66d91bf (#34)

Does this ticket remain an issue?

@Stebalien
Copy link
Member Author

I can't remember at this point. If that's where we set Content-Disposition, then yes.

@kstuart
Copy link

kstuart commented Jan 24, 2023

Yes, that's the only place it is set, since all values are escaped using url.QueryEscape this ticket is probably stale and could be closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug A bug in existing code (including security flaws)
Projects
None yet
Development

No branches or pull requests

2 participants