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

send file name #88

Open
notune opened this issue Feb 7, 2024 · 2 comments
Open

send file name #88

notune opened this issue Feb 7, 2024 · 2 comments
Labels
working on it It's on the roadmap

Comments

@notune
Copy link
Contributor

notune commented Feb 7, 2024

I think it would be a great feature to include the file name as well. (or maybe just the file extension). This would only require a few additional bytes to be sent.

@sz3
Copy link
Owner

sz3 commented Feb 8, 2024

It'd be helpful.

I left it out initially due to (perceived) security risk on my part. I've sort of come around on it though -- I don't think it's too scary to have the file declare what it is, since a troublemaker would be able to do the same sort of things without it anyway:

😈 : just rename 1.123456 to "notavirus.pdf" and open it!

vs just getting the save dialogue for "notavirus.pdf"

There's kind of an inherent trust issue with being able to send the whole file in the bar code regardless, so I'd like to try to communicate that better as I (slowly) add more usability.

@sz3
Copy link
Owner

sz3 commented Feb 8, 2024

Implementation wise, I alluded to it here

another option is to use the "skippable frame" functionality of zstd to attach some metadata to the transfer.

That's probably how I would (hopefully will) do it: make it entirely optional on the receiver's end as to whether to pay attention to the filename, but make sure the sender includes it.

We're already using skippable frames to pad small files up to the fountain (wirehair) block size, so it's not too crazy.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
working on it It's on the roadmap
Projects
None yet
Development

No branches or pull requests

2 participants