wsgidav
wsgidav is a generic and extendable WebDAV server written in Python and based on WSGI. It allows sharing filesystem folders over WebDAV protocol with configurable authentication and server options.
Description
wsgidav provides a flexible WebDAV server implementation for sharing filesystem folders. Available as Python 3 library (python3-wsgidav) and documentation package (python-wsgidav-doc), it supports multiple WSGI servers and authentication methods. The tool is useful for quickly setting up WebDAV shares for testing, development, or penetration testing scenarios requiring remote file access.
Key features include anonymous access, NT or PAM-login authentication, and support for various WSGI servers like cheroot, gevent, and uvicorn. Configuration can be done via command-line flags or YAML files, with a default search for 'wsgidav.yaml' in the current directory. This makes it suitable for rapid deployment in cybersecurity contexts, such as client-side attacks involving code execution via Windows library files as referenced in PEN-200 training.
The server publishes specified filesystem paths as WebDAV shares, enabling read-write access over HTTP. Licensed under MIT, it is maintained on GitHub with extensive configuration documentation.
How It Works
wsgidav operates as a WSGI-based WebDAV server, using pre-installed WSGI servers like cheroot (default) to handle HTTP requests and implement WebDAV protocol (RFC 4918). It mounts a filesystem folder at the root path, exposing it for RW operations. Authentication modes (anonymous, NT, PAM-login) control access, while SSL adapters (builtin, pyopenssl) enable secure connections. Configuration files in YAML format override CLI flags for advanced setups including multi-share definitions and custom providers.
Installation
sudo apt install python3-wsgidavFlags
Examples
wsgidav --port=80 --host=0.0.0.0 --root=/temp --auth=anonymouswsgidav --port=80 --host=0.0.0.0 --config=~/my_wsgidav.yamlwsgidav -p 8080wsgidav -H 0.0.0.0wsgidav --root=/shared --auth=ntwsgidav --server=gevent --ssl-adapter=builtinwsgidav -c wsgidav.yaml