Skip to main content

GTK3 GUI for managing Samba user shares

Project description

Samba Usershare Manager

A GTK3 desktop application for managing Samba user shares through a simple GUI.

Disclaimer: This project was written entirely by Claude AI (Anthropic). It has not been manually reviewed or audited. Use at your own risk. If you have concerns about correctness, security, or behaviour, please open an issue or review the source yourself before running it on any system you care about.

Features

  • List all user shares with name, path, comment, guest access level, and user count
  • Create, edit, and delete shares
  • Per-share user access control with read or write permissions
  • Guest access: none, read-only, or read/write

Requirements

  • Linux (Arch Linux recommended)
  • Samba (/usr/bin/net must be present)
  • Python ≥ 3.10
  • GTK 3 + PyGObject

On Arch Linux:

pacman -S samba python-gobject

Installation

pip install samba-usershare-manager

For development (editable install from a local clone):

pip install -e .

Usage

samba-usershare-manager

The application manages shares for the currently logged-in user. Samba must be configured to allow user shares in /etc/samba/smb.conf:

[global]
   usershare path = /var/lib/samba/usershares
   usershare max shares = 100
   usershare allow guests = yes

The usershare allow guests option is optional. If it is absent or set to no, the application automatically hides all guest access controls in the UI.

Configuration

The application reads an optional config file at:

~/.config/samba-usershare-manager/config.ini

All keys are optional — omit any you don't need. Available options and their defaults:

[app]
# Window title
title = Samba Usershare Manager
# Absolute path to a PNG/SVG icon file (leave empty to use no custom icon)
icon =

[samba]
# Path to the net binary
net = /usr/bin/net
# Path to smb.conf (used to detect whether guest access is enabled)
smb_conf = /etc/samba/smb.conf

Run and debug without installing

Set PYTHONPATH to point at the src/ directory and run the package directly:

PYTHONPATH=src python -m samba_usershare_manager

For verbose GTK/GLib output:

PYTHONPATH=src G_MESSAGES_DEBUG=all python -m samba_usershare_manager

VS Code launch configuration

Add to .vscode/launch.json:

{
  "version": "0.2.0",
  "configurations": [
    {
      "name": "Run samba-usershare-manager",
      "type": "debugpy",
      "request": "launch",
      "module": "samba_usershare_manager",
      "env": { "PYTHONPATH": "${workspaceFolder}/src" }
    }
  ]
}

License

"THE BEER-WARE LICENSE" (Revision 42):
Claude AI wrote this file. As long as you retain this notice you can do
whatever you want with this stuff. If we meet some day, and you think this
stuff is worth it, you can buy me a beer in return 🍺
(I'm an AI — I can't drink it, but I'll appreciate the thought at
the speed of light across several data centers.)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

samba_usershare_manager-0.1.0.tar.gz (11.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

samba_usershare_manager-0.1.0-py3-none-any.whl (11.8 kB view details)

Uploaded Python 3

File details

Details for the file samba_usershare_manager-0.1.0.tar.gz.

File metadata

  • Download URL: samba_usershare_manager-0.1.0.tar.gz
  • Upload date:
  • Size: 11.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.3

File hashes

Hashes for samba_usershare_manager-0.1.0.tar.gz
Algorithm Hash digest
SHA256 ff0b07997d4078b415ec7304a2dc31397f9a0317e33738b12b171c1bac75fca7
MD5 727fa8b7072c9fb0e038802d22f8427e
BLAKE2b-256 88789b40bbe36a6b3dbee05deffd25b297db2309316e7ced808bad82d13c5533

See more details on using hashes here.

File details

Details for the file samba_usershare_manager-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for samba_usershare_manager-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 1febd02788ae21779d90b2643463c64080628be694d2536bb1c9a9ea9be480d0
MD5 635d808a1be9fe395e34c4776fd3aee1
BLAKE2b-256 7ac9d99060dbbe56803ff4ab1683c9dbeef88e405077b7dbf16ba56141a37f81

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page