Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/junker/davesync
Synchonizes and encrypts a local directory with a remote WebDAV folder
https://github.com/junker/davesync
encryption gpg nextcloud sync syncronization webdav
Last synced: about 2 months ago
JSON representation
Synchonizes and encrypts a local directory with a remote WebDAV folder
- Host: GitHub
- URL: https://github.com/junker/davesync
- Owner: Junker
- License: gpl-3.0
- Created: 2021-07-30T16:26:28.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2024-10-29T01:49:54.000Z (about 2 months ago)
- Last Synced: 2024-10-29T02:33:24.926Z (about 2 months ago)
- Topics: encryption, gpg, nextcloud, sync, syncronization, webdav
- Language: Python
- Homepage:
- Size: 57.6 KB
- Stars: 4
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# DavESync (WebDav Encrypted Synchronization)
Sync and encrypt your local directory to WebDav folder or your cloud with WebDav
support (NextCloud, Yandex.Disk etc).All files are encrypted with GPG symmetric passphrase, you can download any file
from your webdav or cloud and decrypt it with GPG app, which exists in any OS
(Android, iOS, Linux, Windows etc).## Dependencies
- [webdav4](https://pypi.org/project/webdav4/)
- [python-gnupg](https://pypi.org/project/python-gnupg/)
- [colorlog](https://pypi.org/project/colorlog/)## Installation
### Manual
```shell
pip install -r requirements.txt
cp davesync.py /usr/local/bin/davesync
```### Arch Linux
```shell
yay -S davesync
```## Result example
Local folder:
```
/home/bob/mydata
│
├─bank_records.xlsx
├─my_nude_photo.jpg
├─very_secret_document.docx
└─passport.pdf
```WebDav folder:
```
https://nextcloud.example.org/remote.php/dav/files/bob/mydata
│
├─bank_records.xlsx.gpg
├─my_nude_photo.jpg.gpg
├─very_secret_document.docx.gpg
├─passport.pdf.gpg
└─davesync-metadata.json
```## Usage
e.g.:
```bash
$ davesync.py /home/bob/mydata https://nextcloud.example.org/remote.php/dav/files/bob/mydata \
--webdav-user=bob \
--webdav-password 123 \
--gpg-passphrase qwe \
--delete \
--verbose
``````
davesync.py local_base remote_base [options]
sync and encrypt your local directory to WebDav serverpositional arguments:
local_base Local directory to sync, e.g. /home/bob/myfolder
remote_base Base WebDav URL, e.g. https://example.org/dav/myfolderoptional arguments:
-h, --help show this help message and exit
--webdav-user USER, -u USER
WebDav Username
--webdav-password PASSWORD, -p PASSWORD
WebDav Password
--webdav-password-file PASSWORD_FILE
WebDav Password file
--gpg-passphrase PASSPHRASE, -gp PASSPHRASE
GPG Passphrase
--gpg-passphrase-file PASSPHRASE_FILE
GPG Passphrase file
--delete delete extraneous files/dirs from remote dirs.
--delete-excluded Delete excluded files from dest dirs
--force, -f Force copying of files. Do not check files modifications
--timeout N, -t N WebDav operation timeout N seconds. Default: 10
--exclude PATTERN exclude files matching PATTERN
--save-metadata-step N
save metadata every N uploaded files. Default: 10
--no-check-certificate
Do not verify SSL certificate
--cipher-algo CIPHER Cipher algorithm. Default: AES. (IDEA, 3DES, CAST5,
BLOWFISH, AES, AES192, AES256, TWOFISH, CAMELLIA128,
CAMELLIA192, CAMELLIA256 etc.
Check your "gpg" command line help to see what symmetric
cipher algorithms are supported)
--compress-algo ALGO Compression algorithm. Default: none.
(zip, zlib, bzip2, none etc. Check your "gpg" command
line help to see what compression algorithms are supported)
--compress-level N, -z N
Set compression level to N. Default: 0
--verbose, -v verbose (-v,-vv,-vvv)```
## Decrypt
### CLI
```bash
gpg example.docx.gpg
```### GUI
Windows:
- [WinGPG](https://scand.com/products/wingpg/)
OSX:
- [GPGTools](https://gpgtools.org/)
Android:
- [OpenKeychain: Easy PGP](https://play.google.com/store/apps/details?id=org.sufficientlysecure.keychain)
## Caveats
- filenames not encrypted