Restricting functions
Restricting functions
You can restrict the goshs functions, for example if you want to block download or upload of files. You can also activate silent mode, so that the UI is ommitted.
Block uploads (read-only)
You can block the upload function by using the read only mode with -ro. Uploads will not be possible anymore.
Block downloads (upload-only)
You can also block the downloads and use goshs as a file dropping service by utilizing the upload only mode with -uo. Downloading files will not be possible anymore.
Deactivate Clipboard (no-clipboard)
You can furthermore deactivate the clipboard sharing option. Using -nc the clipboard will not be shown in the UI and is deactivated.
Deactivate UI (silent mode)
By using -si you can deactivate the UI to use goshs in silent mode. The only thing that will be shown in the browser is the following.
Be invisible (invisible mode)
If you want to further reduce your footprint and be invisible use the invisible mode -I/--invisible. You can now only access files, if you know the name and path. The following features will work:
- Download (exact path needed)
- Upload (user curl PUT or POST with -f)
- Authentication
- TLS
- Command via websocket request (see example down below)
- Read Only
- Upload Only
- No-Delete
- Embedded
- Log Output
- IP Whitelist
- Webhook
Features that will not work:
- Dir listing
- Server Banner
- WebDav
- SFTP
- mDNS
If you want to use the command feature start goshs with auth and TLS enabled.
> goshs -s -ss -b test:test -c -IThen you can use the following command together with websocat.
> echo -e '{"type": "command", "content": "id"}' |./websocat -H "Authorization: Basic dGVzdDp0ZXN0" --insecure -t 'wss://127.0.0.1:8000/?ws' | jq -r .content
uid=1000(goshs) gid=1000(goshs) groups=1000(goshs)