Commit graph

187 commits

Author SHA1 Message Date
JustAnotherArchivist
6bd3e97186 Only increment download counter on files that have a download limit
For files that have no limit, there is no reason to track the download counter as its value will never be used anyway. This reduces costs on storage backends that have an operation fee (e.g. AWS S3) or a minimum retention (e.g. Wasabi S3).
2021-04-25 17:47:23 +00:00
JustAnotherArchivist
4daca97f89 Only rewrite metadata file when the download counter changed
Previously, the metadata file would be rewritten even if the download counter stayed the same (i.e. `increaseDownload = false`, previews and HEAD requests). Because the metadata doesn't change in that case, this would simply rewrite the exact same contents needlessly, which may also incur extra costs depending on the storage backend.
2021-04-19 18:37:47 +00:00
Andrea Spacca
69519d8fa4 Unwrap unnecessary bytes.NewReader 2021-03-19 08:25:40 +01:00
Andrea Spacca
b36711c1ea sanitize only on inline content-disposition 2021-03-02 16:50:53 +01:00
Andrea Spacca
27f84e719a Content-Type metadata to lower 2021-03-02 16:48:04 +01:00
Andrea Spacca
7ea65c5a24 go get -u, go build ldflags, docker tag, inline handler 2021-02-19 14:50:40 +01:00
Andrea Spacca
7cf688e86e fix bug in purge for local storage 2021-01-11 16:02:00 +01:00
Andrea Spacca
d554eb8e2d clone url 2021-01-06 13:33:46 +01:00
Andrea Spacca
322310d47f fix bug in gdrive purge 2021-01-06 12:41:40 +01:00
Andrea Spacca
d3381a2293 GOFMT 2021-01-05 17:24:16 +01:00
Andrea Spacca
6ac6c8fa99 PURGE FEATURE 2021-01-05 17:23:47 +01:00
Andrea Spacca
e53d599e09 ISSUE-332 2020-12-31 20:08:42 +01:00
Stefan Benten
614a7fd23d Merge remote-tracking branch 'dutchcoders/master' 2020-12-16 01:13:04 +01:00
Andrea Spacca
06d87eac8e Remove fuzzit 2020-12-15 20:13:12 +01:00
Stefan Benten
b372dc97b5 Merge remote-tracking branch 'dutchcoders/master'
# Conflicts:
#	README.md
#	go.sum
2020-12-15 16:42:12 +01:00
Andrea Spacca
9430e53689
Merge pull request #307 from cheeseandcereal/add_proxy_port
add proxy-port for port override when running behind a proxy
2020-05-17 19:28:21 +02:00
Adam Crowder
0a6b5817a9
use cryptographically secure rng seed
Signed-off-by: Adam Crowder <adam@adamcrowder.net>
2020-05-11 18:57:04 -07:00
Adam Crowder
f909ad3ce2
fix missing metadata security vuln 2020-05-08 16:23:32 -07:00
Adam Crowder
d830bf1afc
revert println
Signed-off-by: Adam Crowder <adam@adamcrowder.net>
2020-05-08 11:49:21 -07:00
Adam Crowder
f366e8217e
add proxy-port for port override when running behind a proxy
Signed-off-by: Adam Crowder <adam@adamcrowder.net>
2020-05-03 13:26:49 -07:00
Andrea Spacca
ef28bcb28f ISSUE-296 add CORS 2020-04-04 14:29:33 +02:00
stefanbenten
c89b7f56c2 use general errors package 2020-03-20 13:29:47 +01:00
stefanbenten
8bb5094ccc handle obscure Errors properly 2020-03-20 13:02:27 +01:00
stefanbenten
b7deec505b Update Dependencies to Release Version and Interface Compliance 2020-03-20 12:41:05 +01:00
stefanbenten
c62e5757ef Merge remote-tracking branch 'origin/master'
# Conflicts:
#	go.mod
#	go.sum
2020-03-20 12:30:59 +01:00
Andrea Spacca
38d643e12b fix fuzzy 2020-03-15 20:09:12 +01:00
Andrea Spacca
3b1b5b890a Removed contentType from storage, rely on metadata 2020-03-15 19:35:43 +01:00
stefanbenten
fb3d410004 Update Dependencies to latest RC Candidate 2020-03-11 14:33:52 +01:00
stefanbenten
924275e45b Code Review Tweaks 2020-03-06 20:36:46 +01:00
stefanbenten
fdca501681 Fix Typo's 2020-03-06 15:43:14 +01:00
stefanbenten
38996c9c7f Update to RC 2020-03-06 15:37:52 +01:00
stefanbenten
9f9e1b66b2 CR Changes 2020-02-21 23:39:12 +01:00
stefanbenten
867471aa9c Clean up documentation and remove unnecessary flag 2020-02-21 23:10:56 +01:00
stefanbenten
96fb3cbe61 Commit the upload 2020-02-21 22:48:09 +01:00
stefanbenten
800dd6658e Remove old and reduce dependencies 2020-02-21 22:42:24 +01:00
Andrea Spacca
2e33f7c716 v1.1.3 2020-01-06 17:19:52 +01:00
Stefan Benten
dcaf572f3d Remove Error Wrapping and update Dependencies 2019-12-29 15:16:07 +01:00
Stefan Benten
7dc3982c77 Adding missing IsNotExist Function and proper Path Handling 2019-12-01 17:43:04 +01:00
Stefan Benten
fcbddcee17 Switch to Scope Handling 2019-11-22 15:14:04 +01:00
stefanbenten
b22a410a78 Actually append Config to Uplink Creation 2019-10-28 22:44:46 +01:00
stefanbenten
f22bfbf804 Merge remote-tracking branch 'origin/master' 2019-10-28 22:37:27 +01:00
Andrea Spacca
bef766f605 FIX BUILD 2019-10-07 21:33:45 +02:00
stefanbenten
060dbdf152 Add Ability to run against local test-network 2019-10-06 17:06:26 +02:00
Andrea Spacca
8c5ef8f2e1 Fuzz local storage test 2019-09-01 10:31:47 +02:00
Book Moons
6b148d3574 Define fuzz targets 2019-09-01 10:31:47 +02:00
stefanbenten
6eabb248da Rename variable for consistency 2019-08-29 22:17:38 +02:00
stefanbenten
5bb0e84fa5 Wrap Errors and rename class 2019-08-29 22:14:48 +02:00
stefanbenten
cf00af36f2 Changing Error Handling and increase Logging 2019-08-29 16:58:14 +02:00
stefanbenten
79c5130066 Changes according to CR 2019-08-29 16:35:24 +02:00
stefanbenten
c1691c58dc Switch to Salted Key Generation 2019-08-29 16:33:37 +02:00
stefanbenten
874268d80e Add Storj Storage Adapter - add Binding 2019-08-28 15:29:35 +02:00
stefanbenten
59014f2110 Add Storj Storage Adapter - Base Functions 2019-08-28 15:18:00 +02:00
Andrea Spacca
6c54ddccef
Merge pull request #250 from n8225/fixS3MultiPartUpload
Fix s3 100MB max upload issue.
2019-08-24 17:12:22 +02:00
n8225
a2ab63c7b8 Remove commented debug line. 2019-08-24 08:47:04 -05:00
Douglas Pessoa
6c73f13fd0 Fixes "mkdir /basedir: no such file or directory" by creating the directory recursively 2019-08-23 20:44:35 +00:00
n8225
ce7e008bb3 Remove maxUploadParts and PartSize options 2019-08-22 14:10:11 -05:00
nrew225
372ff5f368 Fix s3 100MB max upload issue. 2019-07-21 15:01:57 -05:00
nrew225
6cb2de3cff Add support for S3 path style URLS. 2019-07-21 09:29:01 -05:00
Andrea Spacca
58edf68fd7 no need for abs path flag param 2019-07-16 21:23:19 +02:00
Andrea Spacca
2e41852860 fix resolved url 2019-07-16 20:51:31 +02:00
Andrea Spacca
1809ffe8b5 ISSUE-240 negative max metadata instead of big enough 2019-07-06 20:33:35 +02:00
Andrea Spacca
2ee646590d ISSUE-241 check metadata on preview 2019-07-06 20:13:20 +02:00
Andrea Spacca
4a1697ee60 error checking 2019-06-24 07:45:47 +02:00
Andrea Spacca
2cebb7520c ISSUE-242 just some small refactoring 2019-06-23 21:06:58 +02:00
Alexander Lauster
6e03965c8b Merge branch 'ISSUE-242' of https://github.com/dutchcoders/transfer.sh into ISSUE-242 2019-06-23 15:59:37 +02:00
Andrea Spacca
c072345869 ISSUE-242 fix head/get 2019-06-23 15:22:49 +02:00
Alexander Lauster
47d4907a06 Add option to set the S3 region to support other regions as eu-west-1 2019-06-23 13:04:37 +02:00
Andrea Spacca
9355bab9d4 ISSUE-242 fix forgotten dead code 2019-06-23 09:25:13 +02:00
Andrea Spacca
703987c516 ISSUE-242 2019-06-23 09:25:13 +02:00
Douglas Pessoa
b8faedc92f Add X-Remaining-Downloads and X-Remaining-Days headers to HEAD and GET responses 2019-06-17 00:43:22 +00:00
JustAnotherArchivist
568f917c67 Fix encoding of spaces in filenames from + to %20 2019-06-13 16:35:10 +02:00
Andrea Spacca
e8ccf543f6 ISSUE-221 2019-05-18 14:13:23 +02:00
Andrea Spacca
6ac8ae20e3 ISSUE-223 2019-05-12 10:14:27 +02:00
Andrea Spacca
a4e4cafc30 ISSUE-223 2019-05-11 15:12:38 +02:00
Andrea Spacca
4d88a2fbc4 ISSUE-223 2019-05-11 15:01:00 +02:00
Andrea Spacca
9148f20aee ISSUE-203 2019-05-11 14:47:58 +02:00
Andrea Spacca
cc401433a6 ISSUE-203 2019-05-11 14:42:59 +02:00
Andrea Spacca
61a4b4fe33 ISSUE-203 2019-05-08 09:14:08 +02:00
Andrea Spacca
b5b58f9b3b ISSUE-217 2019-04-29 07:23:24 +02:00
Andrea Spacca
ba0e2ac711 ISSUE-215 2019-04-27 11:50:36 +02:00
Andrea Spacca
6d23a8f5f3 ISSUE-207 #6 2019-04-07 17:41:58 +02:00
Andrea Spacca
18f6d76bee ISSUE-207 #4 2019-04-07 17:20:46 +02:00
Andrea Spacca
121a8d824e ISSUE-207 #3 2019-04-07 17:13:41 +02:00
Andrea Spacca
ee417b9db1 ISSUE-207 #2 2019-04-07 17:12:11 +02:00
Andrea Spacca
ad6cf77017 ISSUE-207 2019-04-07 17:06:27 +02:00
Akito13
3c7904cd67
Fixed typo 2019-03-30 02:30:12 +01:00
stefanbenten
bb6edbdaca Renaming 2019-03-25 18:04:26 +01:00
stefanbenten
f448fc7206 Variable Naming 2019-03-25 18:03:16 +01:00
stefanbenten
f3e49e3913 Revert Logic, due to refactoring 2019-03-19 21:20:15 +01:00
stefanbenten
f644a930dc Refactor and update Readme 2019-03-19 18:48:28 +01:00
Stefan Benten
7be8c21044 Add CLI Flag and update Function Flow 2019-03-19 11:35:30 +01:00
Stefan Benten
e7e894dd7f Add Put Function without MultiPart Upload 2019-03-19 11:02:39 +01:00
Andrea Spacca
5fa36e25c8 Add gdrive-chunk-size 2019-03-18 20:52:38 +01:00
Andrea Spacca
5310566b81 fixes 2019-03-18 19:09:22 +01:00
Andrea Spacca
af80d889af support range header 2019-01-16 19:58:11 +01:00
Andrea Spacca
f4d00db5e1 REMOVE DEBUG LOG 2018-12-15 21:42:53 +01:00
Andrea Spacca
64344fcf4d FIX MISSING TEMPLATE DATA 2018-12-15 21:42:18 +01:00
Andrea Spacca
d2c8b85b15 REFERENCING CURRENT HOSTING 2018-12-15 21:16:30 +01:00
Andrea Spacca
6982590cb0
implements log option (#171)
* implements log option
2018-10-27 00:15:55 +02:00
Andrea Spacca
84ee48d8b1
save token in gdrive local config path (#170) 2018-10-26 23:28:47 +02:00