Install build dependencies:
sudo apt install python3 python3-pip python3-dev build-essential
# Install Python dependencies from the pinned requirements file
pip install -r requirements.txt
pip install pyinstallerpython3 -m PyInstaller FadCrypt_Linux.spec --clean --noconfirmCreates: dist/fadcrypt (single executable file)
python3 -m PyInstaller FadCrypt_Linux_CLI.spec --clean --noconfirmCreates: dist/fadcrypt-cli (single executable file)
chmod +x build-deb.sh
./build-deb.shCreates: fadcrypt_<version>_amd64.deb
Note: Both executables are built in onefile mode (single self-extracting executable), providing:
- ✅ Fast installation (only 2 files to copy)
- ✅ Smaller .deb package size
- ✅ Automatic extraction to
/tmpat runtime - ✅ No dependency on bundle structure
The --clean --noconfirm flags ensure a fresh build without prompts.
sudo dpkg -i fadcrypt_<version>_amd64.deb# Copy single-file executables
sudo cp dist/fadcrypt /usr/bin/
sudo cp dist/fadcrypt-cli /usr/bin/
sudo chmod 755 /usr/bin/fadcrypt
sudo chmod 755 /usr/bin/fadcrypt-cli
# Copy desktop files and icons
sudo cp debian/fadcrypt.desktop /usr/share/applications/
sudo cp debian/fadcrypt-cli.desktop /usr/share/applications/
sudo cp img/1.png /usr/share/pixmaps/fadcrypt.png
sudo cp img/fadcrypt_cli.png /usr/share/pixmaps/fadcrypt_cli.png- From application menu: Search for "FadCrypt"
- Or run:
fadcryptorfadcrypt --gui
- From application menu: Search for "FadCrypt CLI"
- Or run:
fadcrypt-cliorfadcrypt-cli --cli
fadcrypt-cli --lock file # Lock a file
fadcrypt-cli --unlock file # Unlock a file
fadcrypt-cli --list # List locked itemsAfter installation, the .deb provides:
- GUI Executable:
/usr/bin/fadcrypt(single-file, self-extracting) - CLI Executable:
/usr/bin/fadcrypt-cli(single-file, self-extracting) - Daemon Script:
/usr/share/fadcrypt/elevated-daemon.py - Systemd Service:
/etc/systemd/system/fadcrypt-elevated.service - Desktop Files:
/usr/share/applications/fadcrypt.desktop(GUI launcher)/usr/share/applications/fadcrypt-cli.desktop(CLI launcher)
- Icons:
/usr/share/pixmaps/fadcrypt.png(GUI)/usr/share/pixmaps/fadcrypt_cli.png(CLI)
- Documentation:
/usr/share/doc/fadcrypt/ - User Config:
~/.config/FadCrypt/ - User Backups:
~/.local/share/FadCrypt/Backup/ - Runtime Temp:
/tmp/_MEI*(auto-cleaned on exit)
Note: Onefile executables extract dependencies to /tmp/_MEI* at runtime and clean up on exit. This provides fast installation while maintaining full functionality.
The .deb package automatically installs and enables the systemd daemon:
# View status
sudo systemctl status fadcrypt-elevated.service
# View logs
sudo journalctl -u fadcrypt-elevated.service -f
# Restart service
sudo systemctl restart fadcrypt-elevated.service
# Stop service
sudo systemctl stop fadcrypt-elevated.service
# Start service
sudo systemctl start fadcrypt-elevated.serviceService Details:
- Name:
fadcrypt-elevated.service - Configuration:
/etc/systemd/system/fadcrypt-elevated.service - Socket:
/run/fadcrypt/elevated.sock
When you enable monitoring in FadCrypt GUI:
- Creates:
~/.config/autostart/FadCrypt.desktop - Exec:
fadcrypt --auto-monitor - Will start automatically on next system boot
To disable:
- Open FadCrypt GUI and click "Stop Monitoring"
- Or delete:
~/.config/autostart/FadCrypt.desktop
When you lock a file or folder:
- Backup: Original permissions saved to
~/.config/FadCrypt/permission_backups/ - Lock: Applied via daemon:
chmod 000- Remove all permissionschattr +i- Set immutable flag
- Encryption: File encrypted to
.fadcryptformat (optional)
When you unlock:
- Immutability Removed: Daemon removes immutable flag
- Permissions Restored: Original permissions restored
- Decryption:
.fadcryptfile decrypted (optional)
- File operations require root privileges (handled by daemon)
- Immutable flag prevents accidental deletion even by root
- Permissions enforced at filesystem level
- All operations are atomic and recoverable
sudo dpkg -r fadcryptThis removes:
- Both GUI and CLI binaries
- Daemon service
- Desktop files and icons
- User config is preserved in
~/.config/FadCrypt/
Daemon not starting:
sudo journalctl -u fadcrypt-elevated.service -n 20
sudo systemctl restart fadcrypt-elevated.servicePermission denied errors:
# Ensure daemon is running
sudo systemctl status fadcrypt-elevated.service
# Check socket exists
ls -la /run/fadcrypt/
# Restart daemon
sudo systemctl restart fadcrypt-elevated.serviceFor development and testing, run directly from source:
# Start the development daemon (test-only helper)
sudo python3 tests/start_daemon_dev.py
# Run GUI mode
python3 FadCrypt.py --gui
# Run CLI/TUI mode
python3 FadCrypt.py --cli
# Run with verbose logging
python3 FadCrypt.py --cli --verbose