@@ -3,12 +3,14 @@ filedrop
33
44[ ![ Travis CI] ( https://img.shields.io/travis/com/foxcpp/filedrop.svg?style=flat-square&logo=Linux )] ( https://travis-ci.com/foxcpp/filedrop )
55[ ![ CodeCov] ( https://img.shields.io/codecov/c/github/foxcpp/filedrop.svg?style=flat-square )] ( https://codecov.io/gh/foxcpp/filedrop )
6- [ ![ Latest Release] ( https://img.shields.io/github/release/foxcpp/filedrop.svg?style=flat-square )] ( https://github.com/foxcpp/filedrop/releases/latest )
76[ ![ Issues] ( https://img.shields.io/github/issues-raw/foxcpp/filedrop.svg?style=flat-square )] ( https://github.com/foxcpp/filedrop/issues )
87[ ![ License] ( https://img.shields.io/github/license/foxcpp/filedrop.svg?style=flat-square )] ( https://github.com/foxcpp/filedrop/blob/master/LICENSE )
98
109Too lightweight file storage server with HTTP API.
1110
11+ ** Currently filedrop is implemented only as a library. Sections below also
12+ document ideas for standalone server. See issue #3 .**
13+
1214### HTTP API
1315
1416POST single file to ` /filedrop ` to save it.
@@ -34,16 +36,20 @@ You can specify `max-uses` and `store-time-secs` to override default settings
3436from server configuration (however you can't set value higher then configured).
3537
3638```
37- POST /filedrop/screenshot.png?max-uses=5&store-time- secs=3600
39+ POST /filedrop/screenshot.png?max-uses=5&store-secs=3600
3840```
3941Following request will store file screenshot.png for one hour (3600 seconds)
4042and allow it to be downloaded not more than 10 times.
4143
44+
4245### Authorization
4346
4447filedrop supports very basic access control. Basically, it can execute SQL
45- query with contents of ` Authorization ` header and file name. If query returns 1
46- - access will be allowed, if query returns 0 or fails - client will get 403.
48+ query with contents of ` Authorization ` header and file name. If query returns 1 - access
49+ will be allowed, if query returns 0 or fails - client will get 403.
50+
51+ Also if you are using filedrop as a library, you can instead just pass custom
52+ authorization callback.
4753
4854See [ configuration example] ( filedrop.example.yml ) for details.
4955
0 commit comments