You are not logged in.

#1 2009-11-28 18:11:47

Xyne
Moderator/TU
Registered: 2008-08-03
Posts: 5,616
Website

quickserve - easy ad-hoc file sharing

Project Info

http://xyne.archlinux.ca/projects/quickserve

Quickserve is a very easy to use HTTP server that lets you quickly share files with others. It supports HTTP Digest authentication, HTTPS (with both server and client certificates), and file uploads, among other things. Take a look at the project page above for more information.

Screenshots

quickserve_01_small.png
quickserve_02_small.png

News

2013-05-12
Quickserve now has some peer-to-peer functionality via multicast and static peers. The interface will optionally detect other servers and query them for requested files.

Install it on two different systems, open up the ports if necessary and try this:

quickserve --multicast --remote-remote /path/to/whatever

You now have a file-sharing server that will show you all files available on the local Quickserve network. big_smile


2013-05-10
Quickserve has been completely rewritten in Python 3.

  • new HTML pages

  • support for mapping arbitrary server paths to local file paths

  • multiple local directories can now appear as a single directory

  • much cleaner, modular code that has been moved to a separate module

  • standardized page generators (not provides HTML, JSON, plaintext, very easy to add more)

  • new options: --unhide, --index


Questions, comments and other feedback are welcome as always. Enjoy!

Last edited by Xyne (2013-05-12 22:32:15)

Offline

#2 2009-11-28 18:16:17

DonVla
Member
From: Bonn, Germany
Registered: 2007-06-07
Posts: 997

Re: quickserve - easy ad-hoc file sharing

Looks pretty nice, Xyne.
Though some simple authentication and port change would be very useful.

Offline

#3 2009-11-28 18:21:03

Xyne
Moderator/TU
Registered: 2008-08-03
Posts: 5,616
Website

Re: quickserve - easy ad-hoc file sharing

Xyne wrote:

There are options for changing the port and binding the address.

DonVla wrote:

Though some simple authentication and port change would be very useful.

I'll look into simple authentication but I think Python's BaseHTTPServer is rather limited. It doesn't really matter though as this is intended to be run behind a LAN firewall anyway, i.e. to share files with someone in the same house, not over the network, and it's not meant to be running constantly.

As for the port... you can change that with "-p <port>".

Last edited by Xyne (2009-11-28 18:21:22)

Offline

#4 2009-11-28 18:38:03

DonVla
Member
From: Bonn, Germany
Registered: 2007-06-07
Posts: 997

Re: quickserve - easy ad-hoc file sharing

I was thinking of smth to share files with friends over the inet.
I used gnump3d for music and now dropbox for all kind of files. And I always wanted to setup a  simple httpd for that, so quickserve comes just handy.
Sure I do not intend to run it all the time, but I feel safer if there is a password set for the 1-2 hours it's running.

Vlad

PS: And what about the speed in LAN?
For now I'm using sshfs, because I'm too lazy to setup samba/nfs, and it's quite slow (~1MB/s). Is quickserve faster?

Last edited by DonVla (2009-11-29 04:41:25)

Offline

#5 2009-11-28 18:43:49

Xyne
Moderator/TU
Registered: 2008-08-03
Posts: 5,616
Website

Re: quickserve - easy ad-hoc file sharing

I'm looking at the 'WWW-Authenticate' headers right now and will probably add an option to authenticate users.

As for speed it should be faster because it just sends the file (i.e. it does not encrypt it) but I would not use it for anything sensitive over a public connection, even if I doubt that anyone would be sniffing my packets. You'll have to test it yourself to see what kind of speed you get.

Offline

#6 2009-11-28 20:51:43

badboy
Member
Registered: 2009-01-02
Posts: 32

Re: quickserve - easy ad-hoc file sharing

what exactly does it more than a simple

python -m SimpleHTTPServer

?

I aliased this command to "http". It's simple, easy and works.

Offline

#7 2009-11-28 21:08:21

Xyne
Moderator/TU
Registered: 2008-08-03
Posts: 5,616
Website

Re: quickserve - easy ad-hoc file sharing

badboy wrote:

what exactly does it more than a simple

python -m SimpleHTTPServer

?

I aliased this command to "http". It's simple, easy and works.

I didn't know about that, but how can you specify which files are served?
Does it support authorization using the Digest method?



Anyway, I've added support for authorization. Curl and wget only seem to send 'Basic" headers and not 'Digest"... not sure why, but it works in Firefox.

Offline

#8 2009-11-29 00:25:55

DonVla
Member
From: Bonn, Germany
Registered: 2007-06-07
Posts: 997

Re: quickserve - easy ad-hoc file sharing

Hi Xyne,

I've tried quickserve and it works ok. But I can share only files not directories.
It would be nice if I could add whole directories. Smth like "quickserve /home/mp3" and then the directory is available for browsing. Is this possible? Or is it too much hassle?

Vlad

Offline

#9 2009-11-29 17:07:45

Xyne
Moderator/TU
Registered: 2008-08-03
Posts: 5,616
Website

Re: quickserve - easy ad-hoc file sharing

added directory support

Offline

#10 2009-11-29 19:37:30

kjon
Member
From: Temuco, Chile
Registered: 2008-04-16
Posts: 398

Re: quickserve - easy ad-hoc file sharing

Xyne, this is a very nice app... xD

However, I got this message when sharing a directory with non english characters.

----------------------------------------
Exception happened during processing of request from ('127.0.0.1', 33302)
Traceback (most recent call last):
  File "/usr/lib/python2.6/SocketServer.py", line 281, in _handle_request_noblock
    self.process_request(request, client_address)
  File "/usr/lib/python2.6/SocketServer.py", line 307, in process_request
    self.finish_request(request, client_address)
  File "/usr/lib/python2.6/SocketServer.py", line 320, in finish_request
    self.RequestHandlerClass(request, client_address, self)
  File "/usr/lib/python2.6/SocketServer.py", line 615, in __init__
    self.handle()
  File "/usr/lib/python2.6/BaseHTTPServer.py", line 329, in handle
    self.handle_one_request()
  File "/usr/lib/python2.6/BaseHTTPServer.py", line 323, in handle_one_request
    method()
  File "/usr/bin/quickserve", line 102, in do_GET
    self.wfile.write(html.encode("utf-8"))
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 36: ordinal not in range(128)
----------------------------------------
^C^C received, shutting down server

Is there a way to solve this issue? Thanks.


They say that if you play a Win cd backward you hear satanic messages. That's nothing! 'cause if you play it forwards, it installs windows.

Offline

#11 2009-11-29 20:08:57

Xyne
Moderator/TU
Registered: 2008-08-03
Posts: 5,616
Website

Re: quickserve - easy ad-hoc file sharing

@kjon
Try again with the latest version and let me know if it works.

Offline

#12 2009-11-29 20:58:59

y27
Member
Registered: 2009-05-27
Posts: 147
Website

Offline

#13 2009-11-29 21:22:05

badboy
Member
Registered: 2009-01-02
Posts: 32

Re: quickserve - easy ad-hoc file sharing

Xyne wrote:
badboy wrote:

what exactly does it more than a simple

python -m SimpleHTTPServer

?

I aliased this command to "http". It's simple, easy and works.

I didn't know about that, but how can you specify which files are served?
Does it support authorization using the Digest method?



Anyway, I've added support for authorization. Curl and wget only seem to send 'Basic" headers and not 'Digest"... not sure why, but it works in Firefox.

I'm not a python coder and I don't know anything about how it works. I got this useful alias from the grml-zsh-config (http://grml.org/zsh/)
It just serves all files of the directory you started the server, listening on 0.0.0.0, port 8000.
Useful for quick data exchange here at home smile

But if your little script supports basic auth, than it's quite useful, too

Offline

#14 2009-11-29 21:38:28

wuischke
Member
From: Suisse Romande
Registered: 2007-01-06
Posts: 630

Re: quickserve - easy ad-hoc file sharing

I like mongoose for setting up an ad-hoc web server. Just execute "mongoose" in the directory you want to share.

Offline

#15 2009-11-29 21:51:14

kjon
Member
From: Temuco, Chile
Registered: 2008-04-16
Posts: 398

Re: quickserve - easy ad-hoc file sharing

Xyne wrote:

@kjon
Try again with the latest version and let me know if it works.

Well, I could access to *some* of my folders, but these were empty. Others were, simply, unaccessible.

Thanks for your efforts, you solved me from a huge problem with this app. Thanks. again

[kjon@kjon-nc10 ~]$ quickserve .
started httpserver on :8080...
localhost.localdomain - - [29/Nov/2009 18:47:14] "GET / HTTP/1.1" 200 -
localhost.localdomain - - [29/Nov/2009 18:47:14] "GET /favicon.ico HTTP/1.1" 404 -
localhost.localdomain - - [29/Nov/2009 18:47:18] "GET /kjon HTTP/1.1" 200 -
localhost.localdomain - - [29/Nov/2009 18:47:24] "GET /kjon/medios HTTP/1.1" 200 -
localhost.localdomain - - [29/Nov/2009 18:47:28] "GET /kjon/medios/Im%C3%A1genes HTTP/1.1" 404 -
^C^C received, shutting down server

Im%C3%A1genes should be read as Imágenes (images in spanish).


They say that if you play a Win cd backward you hear satanic messages. That's nothing! 'cause if you play it forwards, it installs windows.

Offline

#16 2009-11-29 22:00:14

Xyne
Moderator/TU
Registered: 2008-08-03
Posts: 5,616
Website

Re: quickserve - easy ad-hoc file sharing

Considering the previous posts it seems that I need to specify exactly what quickserve does differently:

quickserve...
*) let's you specify whole directories and individual files anywhere on the system
*) supports HTTP Digest authorization
*) does not require a configuration file for specifying files, binding an address, choosing a port, setting up authorization, etc

I wrote it to suite my particular needs and am sharing it with others who might find it useful. If you don't, then don't use it. I don't mind questions to the effect of "What does it do differently than foo?" (for one, I got to learn about "python -m SimpleHTTPServer"), but what exactly is the point of posting a preference for another application in a contribution thread, especially when there are noticeable differences between it and the one under discussion?

It's like showing up at someone's house for taco night and then telling them that you don't like tacos so you're going to eat some burritos instead. Why bother coming to taco night in the first place?

Offline

#17 2009-11-29 22:31:36

Xyne
Moderator/TU
Registered: 2008-08-03
Posts: 5,616
Website

Re: quickserve - easy ad-hoc file sharing

@kjon
Ok, I think I've discovered the problem (url encoding). The console will still display "Im%C3%A1genes" but now it should serve the files correctly.

Dime si puedes bajar tus imágenes ahora wink

Offline

#18 2009-11-30 00:06:22

kjon
Member
From: Temuco, Chile
Registered: 2008-04-16
Posts: 398

Re: quickserve - easy ad-hoc file sharing

@xine

La descarga fue un éxito xD

(That translation was too good for google-translate. Do you support spanish on your locales ? xD)


They say that if you play a Win cd backward you hear satanic messages. That's nothing! 'cause if you play it forwards, it installs windows.

Offline

#19 2009-11-30 00:22:06

ammon
Member
Registered: 2008-12-11
Posts: 413

Re: quickserve - easy ad-hoc file sharing

Thanks!

This is super awsome! big_smile

Offline

#20 2009-11-30 07:29:02

badboy
Member
Registered: 2009-01-02
Posts: 32

Re: quickserve - easy ad-hoc file sharing

Xyne wrote:

Considering the previous posts it seems that I need to specify exactly what quickserve does differently:

quickserve...
*) let's you specify whole directories and individual files anywhere on the system
*) supports HTTP Digest authorization
*) does not require a configuration file for specifying files, binding an address, choosing a port, setting up authorization, etc

I wrote it to suite my particular needs and am sharing it with others who might find it useful. If you don't, then don't use it. I don't mind questions to the effect of "What does it do differently than foo?" (for one, I got to learn about "python -m SimpleHTTPServer"), but what exactly is the point of posting a preference for another application in a contribution thread, especially when there are noticeable differences between it and the one under discussion?

It's like showing up at someone's house for taco night and then telling them that you don't like tacos so you're going to eat some burritos instead. Why bother coming to taco night in the first place?

is this related to my post?
i didn't wan't to offend you. I just wanted to know if it is a improvement to the method I use atm. And thanks to your posting I can answer this with yes, because it supports authorization and let's me specify the files, to serve. so it is very helpful in some situations, even to me.

And hey: I like tacos smile

Offline

#21 2009-11-30 09:42:34

Xyne
Moderator/TU
Registered: 2008-08-03
Posts: 5,616
Website

Re: quickserve - easy ad-hoc file sharing

kjon wrote:

@xine

sad

kjon wrote:

La descarga fue un éxito xD

big_smile



badboy wrote:

is this related to my post?

The statement of the differences was related to your post, but the part about being rude was only in reply to the post about using mongoose. I had hoped that the "I don't mind questions to the effect of 'What does it do differently than foo?'" would make this clear.

Offline

#22 2009-12-10 13:28:42

helpvampire
Member
Registered: 2009-08-10
Posts: 32

Re: quickserve - easy ad-hoc file sharing

Nice blue square picture.

How to know what my internal IP address is and can this work on debian?

Offline

#23 2009-12-10 21:44:31

Xyne
Moderator/TU
Registered: 2008-08-03
Posts: 5,616
Website

Re: quickserve - easy ad-hoc file sharing

@helpvampire
"ifconfig" will show you your IP on each interface ("inet addr")

You should be able to run quickserve on any system with Python installed.

Last edited by Xyne (2009-12-10 21:53:22)

Offline

#24 2009-12-11 14:01:48

helpvampire
Member
Registered: 2009-08-10
Posts: 32

Re: quickserve - easy ad-hoc file sharing

OK thanks and what licence is it under?

Offline

#25 2009-12-11 15:37:02

Xyne
Moderator/TU
Registered: 2008-08-03
Posts: 5,616
Website

Re: quickserve - easy ad-hoc file sharing

helpvampire wrote:

OK thanks and what licence is it under?

oO

The license is included in the source tarball, stated at the top of the script, visible on the AUR and included in the output of 'pacman -[SQ]i quickserve".




(GPLv2)

Offline

Board footer

Powered by FluxBB