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

Implement command line upload #474

Open
DBa2016 opened this issue Oct 25, 2021 · 1 comment
Open

Implement command line upload #474

DBa2016 opened this issue Oct 25, 2021 · 1 comment

Comments

@DBa2016
Copy link

DBa2016 commented Oct 25, 2021

Is your feature request related to a problem? Please describe.
Some slicers - e.g. lychee - offer a possibility to call a command on the sliced file. A curl call there would be able to upload a file, however when trying the naive "curl -F 'file=@my_file_name' http://mariner_host/api_upload_file", I am getting a "The CSRF token is missing." error message.

Describe the solution you'd like
Enable upload from other sources than the frontend.

@luizribeiro
Copy link
Owner

Hey! Doing this over HTTP is probably not a good idea - unless we have a proper API that uses some form of authentication (that does not rely on cookies). Otherwise your mariner instance would be vulnerable to CSRF attacks

Have you considered just using scp to copy your files to your pi? That's what I generally use when I don't want to upload with the UI.

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

No branches or pull requests

2 participants