epoupon / fileshelter Goto Github PK
View Code? Open in Web Editor NEWFileShelter is a “one-click” file sharing web application
Home Page: https://fileshelter-demo.poupon.dev
License: GNU General Public License v3.0
FileShelter is a “one-click” file sharing web application
Home Page: https://fileshelter-demo.poupon.dev
License: GNU General Public License v3.0
Hi Emeric,
first of all thanks for your great contribution to the community. I think you have achieved a great balance between simple user interface and great feature set.
I have a test installation of it running behind a Caddy web server in reverse proxy mode. Everything runs just great however I'd like to suggest a small improvement:
Since my proxy does TLS termination all HTML links are rendered as TLS by default. However once you upload a file the generated URLs for "Public download link" and "Private edit link" are displayed as HTTP only since Fileshelter is not aware of the TLS termination happening at the proxy level. So I'd suggest a boolean option for "fileshelter.conf" such as "tls-urls" which toggles TLS URL rendering on or off.
Thanks,
Paul
Hi @epoupon ,
I have been running into an issue for a while where Safari adds a 'txt' file extension to every downloaded file. I have tested this on macOS 10.13.X and 10.14.6 as well as iOS 13.3. The issue does not come up using Chrome or Firefox. My guess is that Safari's behaviour is due to the HTTP Content-Type response header being set to "text/plain".
How to reproduce
Upload a test file to the demo instance and download it using Safari. Inspect the downloaded file. It has a "txt" extension attached to it.
Possible remediation
The HTTP response header when downloading a file is set to Content-Type: text/plain
. Changing it to Content-Type: application/octet-stream
might fix this behaviour.
I would like to submit a pull request but could not find the settings in your source code. Sorry.
Thanks for all your work!
When using synology reverse proxy , uploading a large file results in an error
small file is a usually ok but large files are usually stopped and then restarted over and over again.
http reverse proxy is working well but https reverse proxy has a problem
I can find this message in a log file : " [error] "WTemplateFormView: updateViewField: createFormWidget('hits-validity-limit') returned 0" "
It would be a lot easier to simply drag and drop files into a dedicated zone
However, it is only supported on recent wt 3.3.7, so it is likely that the current implementation would remain as a fallback.
I do all the installation process according to their new instructions without errors, but when running fileshelter get the following error:
[root@centos7 ~]# fileshelter
ARG = fileshelter
ARG = --config=/var/fileshelter/wt_config.xml
ARG = --docroot=/usr/share/fileshelter/docroot/;/resources,/css,/images,/favicon.ico
ARG = --approot=/usr/share/fileshelter/approot
ARG = --http-port=5091
ARG = --http-address=0.0.0.0
INFO: Opened log file (/var/fileshelter/fileshelter.log).
Segmentation fault
[root@centos7 ~]#
Hi,
first of all, thank you for this great tool!
I'm using FileShelter in a sub location with nginx and configured the following in fileshelter.conf
# Location for deployment
deploy-path = "/fileshelter/";
# Path to the resources used by the web interface
docroot = "/usr/share/fileshelter/docroot/;/fileshelter/resources,/fileshelter/css,/fileshelter/images,/fileshelter/js,/fileshelter/favicon.ico";
approot = "/usr/share/fileshelter/approot";
wt-resources = "/usr/share/Wt/resources";
This way, all resources are available at https://mydomain.com/fileshelter/, except for the download link, which is not in the sub location but in the root path at https://mydomain.com/share
I don't know C++, but I think the reason might be the hard coded path here?
Thank you,
Fabian
It's at 0% until nearly the last moment. Then it fills up smoothly/linearly at the end. It doesn't reflect actual progress on upload.
See screenshot here with 'actual' progress in bottom left corner of window.
Binary packages for Debian 11 are not built, resulting in errors when trying to install the application on the latest Debian version (11 Bullseye).
In Wt 4.5 the <behind-reverse-proxy>
was deprecated and replaced with <trusted-proxy-config>
so fileshelter don't work behind proxy with wt 4.5 and make this warning:
[2021-Jan-03 20:45:56.953] 47646 - [warning] "config: The behind-reverse-proxy configuration option is deprecated, use a <trusted-proxy-config> block instead"
Hi, this is a very good tool. Thanks for developing this.
I am trying to deploy FileShelter on a non-root URL behind a reverse proxy (Apache 2.4). However since I use this web server for other sites and web apps, I wish to deploy FileShelter under "/fileshelter", not the root (e.g., https://domain.tld/fileshelter).
I could not find a specific configuration option to specify web root, so it automatically navigates to https://domain.tld/home as default.
Is there a way to specify the web root?
Thanks in advance.
/usr/local/libexec/ccache/c++ -Dfilesheltershare_EXPORTS -I/usr/ports/www/fileshelter/work/fileshelter-5.1.0/src/libs/share/include -I/usr/ports/www/fileshelter/work/fileshelter-5.1.0/src/libs/utils/include -isystem /usr/local/include -O2 -pipe -fstack-protector-strong -fno-strict-aliasing -O2 -pipe -fstack-protector-strong -fno-strict-aliasing -DNDEBUG -fPIC -pthread -std=gnu++17 -MD -MT src/libs/share/CMakeFiles/filesheltershare.dir/impl/Db.cpp.o -MF src/libs/share/CMakeFiles/filesheltershare.dir/impl/Db.cpp.o.d -o src/libs/share/CMakeFiles/filesheltershare.dir/impl/Db.cpp.o -c /usr/ports/www/fileshelter/work/fileshelter-5.1.0/src/libs/share/impl/Db.cpp
/usr/ports/www/fileshelter/work/fileshelter-5.1.0/src/libs/share/impl/Db.cpp:82:28: error: no template named 'unordered_map' in namespace 'std'
static thread_local std::unordered_map<Db*, Wt::Dbo::Session*> tlsSessions {};
~~~~~^
1 error generated.
Did you forget to include <unordered_map>
which is required according to cppreference?
clang-14
FreeBSD 13.1
I'm looking for something like fileshelter but am not sure it has the features I am looking for. Currently still comparing a few different projects.
Would it be possible to add IMAP as an authentication provider? That way I could easily give all existing users of an IMAP server access or is authentication meant to happen outside fileshelter?
How are uploaded files treated, are they encrypted? If yes. client-side or server-side?
Title. Probably should take down the URL in case someone gets something nasty.
I have created a custom .conf file in /etc/ folder, as upgrades are overwriting the config file.
The customised TOS settings work fine, but it seems Fileshelter doesn't respect the config defined docroot and approot. Fileshelter still takes the default docroot and approot (as in /usr/share/fileshelter).
Below the relevant part of my redacted config file
# Path to the resources used by the web interface
docroot = "/usr/share/<redacted>/docroot/;/resources,/css,/images,/favicon.ico";
approot = "/usr/share/<redacted>/approot";
Below my redacted systemd file:
[Unit]
Description=<redacted>
[Service]
ExecStart=/usr/bin/fileshelter /etc/<redacted>.conf
Restart=on-failure
[Install]
WantedBy=multi-user.target
Hi! First of all thanks for fileshelter, I love the simplicity of it and the Docker image makes setting it up amazingly easy!
I just tried it out and it works really well. 👍 I do believe I just found a small bug though:
Whenever I try to download something that doesn't exist, the server downloads a Zero-bytes file with the same filename as the last downloaded file.
For example a URL like this would work: https://fileshelter-demo.poupon.dev/share?id=asdguhahsdugasdg
No contents are exposes, only the filename. This might be of a private file that's password protected.
The spinbox is always limited to 0-99, but manual set of the the input works fine.
Hello,
first, great file sharer. It is really simple while offering everything needed. Well done!
However, for me the auto cleaning of expired shares does not work. If I understand the source code correct, the auto cleaning should occur every 6 hours. My Setup is Debian in an LXC container.
On 2021-Jan-11 around 18:15 I upload a small test file with a life time of one hour. So expiration date is according to the private link Mon Jan 11 19:15:34 2021 UTC
.
This morning, the private and public link are still accessible. (It shows that the file is expired).
Checking the log, I can see at least two attempts to cleaning expired shares (see below), but as described above it is not deleted.
If I understand correctly, the file should be already deleted in the file system.
Jan 12 01:15:05 fileshelter fileshelter[293]: [2021-Jan-12 01:15:05.601] 293 - [info] - [DB] Cleaning expired shares...
Jan 12 01:15:05 fileshelter fileshelter[293]: [2021-Jan-12 01:15:05.601] 293 - [info] - [DB] Current number of shares: 1
Jan 12 01:15:05 fileshelter fileshelter[293]: [2021-Jan-12 01:15:05.602] 293 - [info] - [DB] Cleaning expired shares: complete!
Jan 12 07:15:05 fileshelter fileshelter[293]: [2021-Jan-12 07:15:05.602] 293 - [info] - [DB] Cleaning expired shares...
Jan 12 07:15:05 fileshelter fileshelter[293]: [2021-Jan-12 07:15:05.602] 293 - [info] - [DB] Current number of shares: 1
Jan 12 07:15:05 fileshelter fileshelter[293]: [2021-Jan-12 07:15:05.602] 293 - [info] - [DB] Cleaning expired shares: complete!
Small feature or improvement: It would be good to add the 6 hour cycle in the README. And maybe have the frequency of the cleaning as an option in the config (every X hour)?
Best regards
HI,
your software is wonderful!
I want to allow the upload to different peoples , how to add multiple users upload password?
Thank you.
I am trying to turn https in Fileshelter app. It does not work.
First I made a CSR using this command
openssl req -new -newkey rsa:2048 -nodes -keyout yourdomain.key -out yourdomain.csr
Then I got SSL based on CSR.
Then I get dh2048.pem using
openssl dhparam -dsaparam -out dh2048.pem 2048
When I trying to run app it does not want to start.
fileshelter.conf
...
tls-enable = true;
tls-cert = "/var/fileshelter/myssl1.crt";
tls-key = "/var/fileshelter/mykey1.key";
tls-dh = "/var/fileshelter/dh2048.pem";
...
Fileshelter.log
[2017-Jan-30 13:37:03.670257] 17362 - [info] "config: reading Wt config file: /var/fileshelter/wt_config.xml (location = 'fileshelter')"
[2017-Jan-30 13:37:03.670977] 17362 - [info] - [DB] Creating connection pool on file "/var/fileshelter/fileshelter.db"
[2017-Jan-30 13:37:03.672228] 17362 - [info] - [MAIN] Starting database cleaner...
[2017-Jan-30 13:37:03.672246] 17362 - [info] - [DB] Scheduled next scan at UTC 2017-Jan-30 13:37:03
[2017-Jan-30 13:37:03.672313] 17362 - [info] - [MAIN] Starting server...
[2017-Jan-30 13:37:03.672326] 17362 - [info] "WServer/wthttp: initializing built-in wthttpd"
[2017-Jan-30 13:37:03.672357] 17362 - [info] - [DB] Cleaning expired shares...
[2017-Jan-30 13:37:03.672496] 17362 - [info] "wthttp: starting server: https://0.0.0.0:80"
[2017-Jan-30 13:37:03.673174] 17362 - [info] - [MAIN] Now running...
[2017-Jan-30 13:37:03.817054] 17362 - [info] "wthttp/async: SSL handshake error: http request"
[2017-Jan-30 13:37:03.823317] 17362 - [info] "wthttp/async: SSL handshake error: http request"
[2017-Jan-30 13:37:06.168150] 17362 - [info] "wthttp/async: SSL handshake error: http request"
[2017-Jan-30 13:37:10.117308] 17362 - [info] "wthttp/async: SSL handshake error: short read"
[2017-Jan-30 13:37:19.740073] 17362 - [info] "wthttp/async: SSL handshake error: short read"
Hello, this looks like a great tool! I first tried a source install in a CentOS 7 container, without luck.
Then I rolled a Debian container and install of fileshelter_2.0.0-1_amd64.deb seemed to go well. However after install, the web interface looks all borked, because my "/usr/share/fileshelter/docroot" looks like this:
drwxr-xr-x 3 root root 3 Feb 10 18:56 .
drwxr-xr-x 4 root root 4 Feb 10 18:56 ..
drwxr-xr-x 2 root root 3 Feb 10 18:56 css
I suppose there should be a symlink to something? Did not happen for me though.
A freshly compiled instance of fileshelter looks like the demo instance.
Apparently the bootstrap and font-awesome stylesheets are neither provided in the repo nor fetched during build or runtime, which leads to 404 Responses when one tries to use fileshelter and thus the fileshelter page looks incomplete:
ARG = --config=/var/lib/fileshelter/workdir/wt_config.xml
ARG = --docroot=/var/lib/fileshelter/docroot;/resources,/css,/images,/favicon.ico
ARG = --approot=/var/lib/fileshelter/approot
ARG = --deploy-path=/
ARG = --http-port=5091
ARG = --http-address=0.0.0.0
INFO: Opened log file (/var/lib/fileshelter/workdir/fileshelter.log).
127.0.0.1 - - [2017-Dec-22 13:40:17.885931] "GET /home HTTP/1.1" 200 3741
127.0.0.1 - - [2017-Dec-22 13:40:17.992152] "POST /?wtd=Xce0k99EP0oXWDga HTTP/1.1" 200 76
127.0.0.1 - - [2017-Dec-22 13:40:18.011929] "GET /resources/themes/bootstrap/3/bootstrap.css HTTP/1.1" 404 85
127.0.0.1 - - [2017-Dec-22 13:40:18.012637] "GET /resources/font-awesome/css/font-awesome.min.css HTTP/1.1" 404 85
127.0.0.1 - - [2017-Dec-22 13:40:18.012833] "GET /css/fileshelter.css HTTP/1.1" 200 32
127.0.0.1 - - [2017-Dec-22 13:40:18.012990] "GET /resources/moz-transitions.css HTTP/1.1" 404 85
127.0.0.1 - - [2017-Dec-22 13:40:18.013029] "GET /resources/themes/bootstrap/3/wt.css HTTP/1.1" 404 85
127.0.0.1 - - [2017-Dec-22 13:40:18.170322] "GET /home?wtd=GGArnrb52kcnFTGb&sid=1398964801&webGL=true&scrW=1920&scrH=1080&tz=60&htmlHistory=true&deployPath=%2F&request=script&rand=527347002 HTTP/1.1" 200 42347
127.0.0.1 - - [2017-Dec-22 13:40:18.261433] "POST /?wtd=GGArnrb52kcnFTGb HTTP/1.1" 200 50
The only stylesheet provided is /docroot/css/fileshelter.css
The missing ones are expected to be found under:
/docroot/resources/font-awesome/css/font-awesome.min.css
/docroot/resources/font-awesome/fonts/fontawesome-webfont.woff2
/docroot/resources/moz-transitions.css
/docroot/resources/themes/bootstrap/3/bootstrap.css
/docroot/resources/themes/bootstrap/3/wt.css
Handle UTF-8 characters, in both description and file name fields
When the reverse proxy handles SSL, wApp->environment().urlScheme()
still seems to return "http"
.As a result, the links displayed after a share is created are incorrect. Because the linked documents are relative urls, this only shows up when the text is copied, not when the link is followed.
A cursory investigation suggests there is no way to make WT understand that it's hosted as SSL. This is not really a bug in FileShelter, but it's usability is affected by this issue. As I've never actually worked with WT, I'm reluctant to post the bug there, as my credibility as a non-user limited.
Any advice for me to move forward appreciated! Not knowing C++ I had fixed 2 other compile errors and like to have this running on OpenBSD!
% DEBUG=1 make
[ 22%] Built target fileshelterutils
Consolidate compiler generated dependencies of target filesheltershare
[ 25%] Building CXX object src/libs/share/CMakeFiles/filesheltershare.dir/impl/Db.cpp.o
[ 28%] Building CXX object src/libs/share/CMakeFiles/filesheltershare.dir/impl/File.cpp.o
[ 31%] Building CXX object src/libs/share/CMakeFiles/filesheltershare.dir/impl/Share.cpp.o
[ 34%] Building CXX object src/libs/share/CMakeFiles/filesheltershare.dir/impl/ShareCleaner.cpp.o
[ 37%] Building CXX object src/libs/share/CMakeFiles/filesheltershare.dir/impl/ShareManager.cpp.o
fileshelter/src/libs/share/impl/ShareManager.cpp:45:20: error: reference to 'Share' is ambiguous
shareToDesc(const Share::Share& share)
^
fileshelter/src/libs/share/impl/ShareCleaner.hpp:27:11: note: candidate found by name lookup is 'Share'
namespace Share
^
fileshelter/src/libs/share/impl/ShareCleaner.hpp:30:8: note: candidate found by name lookup is 'Share::Share'
class Share;
^
fileshelter/src/libs/share/impl/ShareManager.cpp:58:4: error: reference to 'Share' is ambiguous
Share::FileDesc fileDesc;
^
fileshelter/src/libs/share/impl/ShareCleaner.hpp:27:11: note: candidate found by name lookup is 'Share'
namespace Share
^
fileshelter/src/libs/share/impl/ShareCleaner.hpp:30:8: note: candidate found by name lookup is 'Share::Share'
class Share;
^
2 errors generated.
*** Error 1 in . (src/libs/share/CMakeFiles/filesheltershare.dir/build.make:132 'src/libs/share/CMakeFiles/filesheltershare.dir/impl/ShareManager.cpp.o')
*** Error 2 in . (CMakeFiles/Makefile2:998 'src/libs/share/CMakeFiles/filesheltershare.dir/all': make -s -f src/libs/share/CMakeFiles/filesh...)
*** Error 2 in fileshelter/build (Makefile:146 'all': make -s -f CMakeFiles/Makefile2 all)!
Hello !
i uploaded 4 files to my Fileshelter, set them to expire after 1 hours.
12 hours later, they're still here (i checked in uploaded-files folder)
Does anyone know why ?
Thanks !
I've just tried a file with a max download limit (1) on the demo site.
After downloading it once via the public link, I expected to get a message about exceeding the limitation, but got this instead
This site can’t be reachedThe webpage at https://fileshelter.demo.poupon.io/?wtd=n9k8a1bsdG90PQH3&request=resource&resource=ovhng3x&rand=1004 might be temporarily down or it may have moved permanently to a new web address.
ERR_INVALID_RESPONSE
This is with current Google Chrome.
Hello, I'm facing an issue trying to compile fileshelter on Archlinux, when running ./configure script I receive the following error:
$ ../configure --prefix=/usr/lib
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking for g++... g++
checking whether the C++ compiler works... yes
checking for C++ compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking whether make supports the include directive... yes (GNU style)
checking dependency style of g++... gcc3
checking for pkg-config... /usr/bin/pkg-config
checking pkg-config is at least version 0.9.0... yes
checking for libzip... yes
checking how to run the C++ preprocessor... g++ -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking Wt/WApplication.h usability... yes
checking Wt/WApplication.h presence... yes
checking for Wt/WApplication.h... yes
checking for pthread_create in -lpthread... yes
checking for main in -lstdc++fs... yes
checking for main in -lboost_system... yes
checking for main in -lboost_signals... no
configure: error: libboost_signals not found!
The issue seems to be related to the absence of libboost_signals. On Arch I do have boost 1.72.0
installed but it doesn't seem to provide boost_signals.
$ gcc -lboost-signals
/usr/bin/ld: cannot find -lboost-signals
collect2: error: ld returned 1 exit status
What can I do beside using docker to compile and try fileshelter?
thanks
I'd love to set a default for "validity period". Currently this is always set to 1 day. So an option like "default-validity-days" in fileshelter.conf could come in really handy.
Perhaps this is of interest.
It seems that the max hits feature is more annoying than useful:
I think it would be easier to remove simply remove this setting.
checking dependency style of g++... gcc3
../configure: line 3410: syntax error near unexpected token libzip,' ../configure: line 3410:
PKG_CHECK_MODULES(libzip, libzip >= 0.11)'
I am getting the error even after installing all dependencies ( installed libzip from https://github.com/nih-at/libzip )
Hello thanks for creating this application.
I'm trying to implemented your docker image into a kubernetes cluster. It works, however there are a lot of info/warning logs written, which I don't really need. Can I somehow suppress them? You don't have to specify it for kubernets, if you know how to do it in docker, that should be enough for me.
Here is a example log
Defaulted container "fileshelter" out of: fileshelter, fileshelter-permissions (init)
ARG = /usr/bin/fileshelter
ARG = --config=/var/fileshelter/wt_config.xml
ARG = --docroot=/usr/share/fileshelter/docroot/;/resources,/css,/images,/js,/favicon.ico
ARG = --approot=/usr/share/fileshelter/approot
ARG = --deploy-path=/
ARG = --resources-dir=/usr/share/Wt/resources
ARG = --http-port=5091
ARG = --http-address=0.0.0.0
ARG = --threads=8
[2022-Nov-02 10:27:53.186] 1 - [info] "config: reading Wt config file: /var/fileshelter/wt_config.xml (location = '/usr/bin/fileshelter')"
[2022-Nov-02 10:27:53.208] 1 - [info] - [MAIN] Starting server...
[2022-Nov-02 10:27:53.209] 1 - [info] "WServer/wthttp: initializing built-in wthttpd"
[2022-Nov-02 10:27:53.211] 1 - [info] "wthttp: started server: http://0.0.0.0:5091"
[2022-Nov-02 10:27:53.211] 1 - [info] - [MAIN] Now running...
[2022-Nov-02 10:28:09.497] 1 - [info] "Wt: session created (#sessions = 1)"
[2022-Nov-02 10:28:09.497] 1 [/ P2uLVSFfvspNq8Qm] [info] "WEnvironment: UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36"
10.244.1.0 - - [2022-Nov-02 10:28:09.498] "GET /share-download/2903600d-2172-4fd8-900a-91ce802ea93b HTTP/1.1" 200 2381
[2022-Nov-02 10:28:09.575] 1 [/ P2uLVSFfvspNq8Qm] [info] - [UI] Client address = 10.244.1.0, UserAgent = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36', Locale = en-US, path = '/share-download/2903600d-2172-4fd8-900a-91ce802ea93b'
[2022-Nov-02 10:28:09.577] 1 [/ P2uLVSFfvspNq8Qm] [warning] "WApplication: WApplication::addMetaHeader() with no effect"
10.244.1.0 - - [2022-Nov-02 10:28:09.578] "GET /?wtd=P2uLVSFfvspNq8Qm&request=style&page=1 HTTP/1.1" 200 131
10.244.1.0 - - [2022-Nov-02 10:28:09.585] "GET /?wtd=P2uLVSFfvspNq8Qm&sid=2456928246&webGL=true&scrW=1536&scrH=864&tz=60&tzS=Europe%2FBerlin&htmlHistory=true&deployPath=%2F&request=script&rand=755350794 HTTP/1.1" 200 20851
10.244.1.0 - - [2022-Nov-02 10:28:09.745] "POST /?wtd=P2uLVSFfvspNq8Qm HTTP/1.1" 200 4578
10.244.1.0 - - [2022-Nov-02 10:28:18.918] "POST /?wtd=P2uLVSFfvspNq8Qm HTTP/1.1" 200 587
[2022-Nov-02 10:31:12.924] 1 - [info] "Wt: session created (#sessions = 2)"
[2022-Nov-02 10:31:12.924] 1 [/ KkjcBSCNsb4F52RI] [info] "WEnvironment: UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36"
[2022-Nov-02 10:31:12.924] 1 [/ KkjcBSCNsb4F52RI] [info] "Wt: signal from dead session, sending reload."
[2022-Nov-02 10:31:12.924] 1 - [info] "WebController: Removing session KkjcBSCNsb4F52RI"
[2022-Nov-02 10:31:12.925] 1 [/ KkjcBSCNsb4F52RI] [info] "Wt: session destroyed (#sessions = 1)"
10.244.1.0 - - [2022-Nov-02 10:31:12.926] "POST /?wtd=xnCP76ntWzB4iBAg HTTP/1.1" 200 76
[2022-Nov-02 10:31:12.946] 1 - [info] "Wt: session created (#sessions = 2)"
[2022-Nov-02 10:31:12.946] 1 [/ FKRKWD2hDlSIFcoO] [info] "WEnvironment: UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36"
10.244.1.0 - - [2022-Nov-02 10:31:12.947] "GET /share-create HTTP/1.1" 200 2337
[2022-Nov-02 10:31:13.033] 1 [/ FKRKWD2hDlSIFcoO] [info] - [UI] Client address = 10.244.1.0, UserAgent = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36', Locale = en-US, path = '/share-create'
[2022-Nov-02 10:31:13.035] 1 [/ FKRKWD2hDlSIFcoO] [warning] "WApplication: WApplication::addMetaHeader() with no effect"
10.244.1.0 - - [2022-Nov-02 10:31:13.036] "GET /share-create?wtd=FKRKWD2hDlSIFcoO&request=style&page=1 HTTP/1.1" 200 131
10.244.1.0 - - [2022-Nov-02 10:31:13.043] "GET /share-create?wtd=FKRKWD2hDlSIFcoO&sid=865238637&webGL=true&scrW=1536&scrH=864&tz=60&tzS=Europe%2FBerlin&htmlHistory=true&deployPath=%2F&request=script&rand=1522010287 HTTP/1.1" 200 20819
10.244.1.0 - - [2022-Nov-02 10:31:15.928] "POST /?wtd=FKRKWD2hDlSIFcoO HTTP/1.1" 200 4573
[2022-Nov-02 10:31:25.015] 1 - [info] "Wt: session created (#sessions = 3)"
[2022-Nov-02 10:31:25.015] 1 [/ QSKJSzimJHwmO3Ec] [info] "WEnvironment: UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36"
10.244.1.0 - - [2022-Nov-02 10:31:25.017] "GET /share-download/edf62a4b-c16b-441b-80a4-a94b4b753b77 HTTP/1.1" 200 2381
[2022-Nov-02 10:31:25.097] 1 [/ QSKJSzimJHwmO3Ec] [info] - [UI] Client address = 10.244.1.0, UserAgent = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36', Locale = en-US, path = '/share-download/edf62a4b-c16b-441b-80a4-a94b4b753b77'
[2022-Nov-02 10:31:25.099] 1 [/ QSKJSzimJHwmO3Ec] [warning] "WApplication: WApplication::addMetaHeader() with no effect"
10.244.1.0 - - [2022-Nov-02 10:31:25.100] "GET /?wtd=QSKJSzimJHwmO3Ec&request=style&page=1 HTTP/1.1" 200 131
10.244.1.0 - - [2022-Nov-02 10:31:25.107] "GET /?wtd=QSKJSzimJHwmO3Ec&sid=295931474&webGL=true&scrW=1536&scrH=864&tz=60&tzS=Europe%2FBerlin&htmlHistory=true&deployPath=%2F&request=script&rand=1183589201 HTTP/1.1" 200 20249
10.244.1.0 - - [2022-Nov-02 10:31:25.254] "POST /?wtd=QSKJSzimJHwmO3Ec HTTP/1.1" 200 4574
[2022-Nov-02 10:31:29.460] 1 - [info] "Wt: session created (#sessions = 4)"
[2022-Nov-02 10:31:29.460] 1 [/ 3MrPwFQGPg5Ps6i1] [info] "WEnvironment: UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36"
10.244.1.0 - - [2022-Nov-02 10:31:29.461] "GET /share-download/edf62a4b-c16b-441b-80a4-a94b4b753b77 HTTP/1.1" 200 2381
[2022-Nov-02 10:31:29.544] 1 [/ 3MrPwFQGPg5Ps6i1] [info] - [UI] Client address = 10.244.1.0, UserAgent = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36', Locale = en-US, path = '/share-download/edf62a4b-c16b-441b-80a4-a94b4b753b77'
[2022-Nov-02 10:31:29.546] 1 [/ 3MrPwFQGPg5Ps6i1] [warning] "WApplication: WApplication::addMetaHeader() with no effect"
10.244.1.0 - - [2022-Nov-02 10:31:29.547] "GET /?wtd=3MrPwFQGPg5Ps6i1&request=style&page=1 HTTP/1.1" 200 131
10.244.1.0 - - [2022-Nov-02 10:31:29.552] "GET /?wtd=3MrPwFQGPg5Ps6i1&sid=3499203836&webGL=true&scrW=1536&scrH=864&tz=60&tzS=Europe%2FBerlin&htmlHistory=true&deployPath=%2F&request=script&rand=1447711313 HTTP/1.1" 200 20255
10.244.1.0 - - [2022-Nov-02 10:31:29.696] "POST /?wtd=3MrPwFQGPg5Ps6i1 HTTP/1.1" 200 4578
[2022-Nov-02 10:31:29.781] 1 - [info] "Wt: session created (#sessions = 5)"
[2022-Nov-02 10:31:29.781] 1 [/ hlfQoncIAI7MXakw] [info] "WEnvironment: UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36"
10.244.1.0 - - [2022-Nov-02 10:31:29.783] "GET /share-download/2903600d-2172-4fd8-900a-91ce802ea93b HTTP/1.1" 200 2381
[2022-Nov-02 10:31:29.848] 1 [/ hlfQoncIAI7MXakw] [info] - [UI] Client address = 10.244.1.0, UserAgent = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36', Locale = en-US, path = '/share-download/2903600d-2172-4fd8-900a-91ce802ea93b'
[2022-Nov-02 10:31:29.851] 1 [/ hlfQoncIAI7MXakw] [warning] "WApplication: WApplication::addMetaHeader() with no effect"
10.244.1.0 - - [2022-Nov-02 10:31:29.852] "GET /?wtd=hlfQoncIAI7MXakw&request=style&page=1 HTTP/1.1" 200 131
10.244.1.0 - - [2022-Nov-02 10:31:29.861] "GET /?wtd=hlfQoncIAI7MXakw&sid=2851919068&webGL=true&scrW=1536&scrH=864&tz=60&tzS=Europe%2FBerlin&htmlHistory=true&deployPath=%2F&request=script&rand=2249219771 HTTP/1.1" 200 20853
10.244.1.0 - - [2022-Nov-02 10:31:29.990] "POST /?wtd=hlfQoncIAI7MXakw HTTP/1.1" 200 4573
10.244.1.0 - - [2022-Nov-02 10:31:39.730] "POST /?wtd=hlfQoncIAI7MXakw HTTP/1.1" 200 585
Some ideas brought by other people in #63:
As described in the title, when I try to map the '/var/fileshelter' directory from inside the container, to the host, FileShelter fails to start, showing the following error:
Caught std::exception: filesystem error: cannot create directories: Permission denied [/var/fileshelter/uploaded-files]
max-validity-hits = 0;
in /etc/fileshelter.conf
http(s)://server.tld/share-create
User can set expiry in days without a limit like stated in the comment ("Max number of downloads for a share that the user can set. 0 means unlimited").
max-validity-hits
behaves like max-validity-days
and must be > 0. Maybe copy 'n' paste mistake in the comment?
fileshelter.service: Main process exited, code=killed, status=11/SEGV
fileshelter.service: Failed with result 'signal'.
4.2.0 installed on Debian Buster via apt using your repo.
Hi,
If I want to upload a file of 2.6 GB there is a timeout. The log states (there are only 2 lines):
[2020-Jun-13 08:17:14.146] 881 [/ TZ1U3U0Bqi2eZRP6] [info] "WebController: timeout: expiring"
[2020-Jun-13 08:17:14.147] 881 [/ TZ1U3U0Bqi2eZRP6] [info] "Wt: session destroyed (#sessions = 1)"
How can I extend the time?
Thanks and have a nice day!
I want to use second table to keep additional data there.
I am using the same approach ad described in "Share.cpp", "Share.hpp", "DbHandler.cpp", "DbHandler.hpp".
This is how it looks:
I am trying to add data to new table:
These lines do not execute. Seems like "transaction.commit();" silently fails. And question is why? I can not get a clue.
std::cout << "it success" << std::endl;
std::cout << "Yes, we are here. Done3___________________ " << std::endl;
Hello, what are the dependencies for Centos 7?
I install:
yum groupinstall 'Development Tools'
yum install gcc gcc-c++ make openssl-devel
yum install -y libxml2 libxml2-devel libxslt libxslt-devel
yum install boost boost-devel boost-doc
[root@centos7 ~]# cd /opt/
[root@centos7 opt]# ls
[root@centos7 opt]# git clone https://github.com/epoupon/fileshelter.git fileshelter
Cloning into 'fileshelter'...
remote: Counting objects: 462, done.
remote: Total 462 (delta 0), reused 0 (delta 0), pack-reused 462
Receiving objects: 100% (462/462), 88.12 KiB | 0 bytes/s, done.
Resolving deltas: 100% (317/317), done.
[root@centos7 opt]# ls
fileshelter
[root@centos7 opt]# cd fileshelter
[root@centos7 fileshelter]# autoreconf -vfi
autoreconf: Entering directory .' autoreconf: configure.ac: not using Gettext autoreconf: running: aclocal --force autoreconf: configure.ac: tracing autoreconf: configure.ac: not using Libtool autoreconf: running: /usr/bin/autoconf --force autoreconf: running: /usr/bin/autoheader --force autoreconf: running: automake --add-missing --copy --force-missing configure.ac:3: installing './install-sh' configure.ac:3: installing './missing' src/Makefile.am: installing './depcomp' autoreconf: Leaving directory
.'
[root@centos7 fileshelter]# mkdir build
[root@centos7 fileshelter]# cd build
[root@centos7 build]# ../configure --prefix=/usr --sysconfdir=/etc
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking for g++... g++
checking whether the C++ compiler works... yes
checking for C++ compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking for style of include used by make... GNU
checking dependency style of g++... gcc3
checking how to run the C++ preprocessor... g++ -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking Wt/WApplication usability... no
checking Wt/WApplication presence... no
checking for Wt/WApplication... no
configure: error: Header not found or unusable !
Thank you.-
I'm looking for a drop-in replacement for WeTransfer and this is almost exactly what I'm looking for. Two requests I'd love to be added:
I'm happy to buy a coffee/beer for these two features.
I have tried you nice application.
Don't you know if there are any download speed issue?
It is too slow on large files. I am guessing why
Wt is used with debug verbose level. This can generate a lot of log lines for a single upload.
It would be cool if files that are protected with a password would be encrypted on the server, or even better, end-to-end encrypted (the server will send the encrypted data for the client to decrypt themselves).
What if I want to edit text of "Terms of Service" on the fly? Without recompiling sources with "tos.xml?
Any ideas? Put the whole text of "tos.xml" in to database? Maybe more elegant way?
Hello,
Nice project. I couldn't get this working by compiling it on my own so I simply installed the .deb because I was anxious to simply 'get going'. At any rate, is there some easy way to use bootstrap themes and also to use the bootstrap.min.css
rather than the un-minified one? In the 3
directory there's a bootstrap-theme.min.css
but it isn't being called by the application, if I'm not mistaken. At least I see no calls for it.
[edit]
As for using a customised bootstrap 'theme', I suppose it could be possible to just override bootstrap.css
with the new contents.
Any ideas?
Make the form used to upload files locked by a password.
This would be a new option in the configuration file.
Is it possible – or can we have this implemented – to upload to an upload-password-protected instance by passing the password in the url?
One use case would be to request files from someone and make life easy for them ('please upload at https://myfiles.example/share-create/password123')
This feature might also be useful to bypass upload passwords for "safe" ip-addresses by configuring the forward proxy to proxy https://myfiles.example/share-create as http://localhost/share-create/password123 for ip-addresses which are considered "safe"
Maybe I could try to implement this myself but I'd like to hear your opinion first.
Hi Emeric,
as briefly mentioned I have finally managed to publish my Docker workflow to get FileShelter running with Caddy easily. There is one issue I have come across though: I can't delete uploaded shares after upgrading to wt 3.3.6 (running on Debian Stretch Slim) running FileShelter v2.0.1.
How to reproduce?
Using the Docker workflow provided (https://github.com/paulgalow/fileshelter-docker), upload a file. Then hit the red delete button.
Erroneous behaviour:
First error message issued by web browser (pop up):
Wt internal error; code: undefined, description: url.indexOf is not a function
Second message issued by web browser (pop up):
Wt internal error; code: undefined, description: tr.size is not a function
After hitting OK a second time the page stays in a "Loading..." stage indefinitely. Could this be related to some changes in wt?
Regards,
Paul
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.