SafeInCloud DB β KeePass/KeePassXC DB without losing any custom fields
Convert SafeInCloud DB files to KeePass/KeePassXC compatible .kdbx format with automatic category detection and complete data preservation.
# Install dependencies
pip install -r requirements.txt
# Convert your database
python main.py safeincloud.db output.kdbx
# Done! All data, custom fields, and attachments are preservedPython 3.10+ | Windows/Linux/macOS | No data loss β
Existing converters like SIC2KeePass by Alezy often discard custom fields, leaving you with incomplete data. This tool was built to preserve everything - every custom field, attachment, timestamp, and piece of data from your SafeInCloud database.
- π Secure Decryption - Safely decrypt SafeInCloud databases using AES-256 and PBKDF2 key derivation
- π Format Conversion - Convert to KeePass/KeePassXC compatible
.kdbxformat - π» Cross-Platform - Windows, Linux, and macOS support
- π Python 3.10+ - Modern Python support (tested with 3.14)
- πΎ Full Data Preservation - All fields, custom attributes, and metadata are preserved
- β° Timestamp Preservation - Original creation and modification dates are maintained
- π Attachment Support - Binary attachments are converted and stored in KeePass
- π·οΈ Custom Fields - All custom field types are preserved with automatic protection for sensitive data
- π Multi-Password Entries - Intelligently handles entries with multiple URLs and passwords by splitting them into separate entries
- π― Automatic Categorization - Keywords-based automatic grouping into 6 categories (Finance, Social, Shopping, Gaming, Work, Email)
- π Original Group Structure - Preserves your existing SafeInCloud labels/groups
- π Duplicate Handling - Automatically resolves duplicate entry names with numbered suffixes
- π¨ Icon Mapping - Maps field types to appropriate KeePass icons:
- π Website/URL fields
- π§ Email addresses
- π³ Credit cards
- π¦ Bank accounts
- π Passwords and security keys
- π Membership/ID fields
- π Protected Fields - Password fields automatically marked as protected in KeePass
- ποΈ Optional Keyfile - Support for additional keyfile-based protection
- βοΈ Password Confirmation - Confirmation prompt when setting new KeePass password
- β‘ Secure Extraction - No temporary files; data stays in memory during processing
- Python Version: 3.10+ (tested with 3.14)
- Operating Systems: Windows, Linux, macOS
git clone https://github.com/nom0x0nk/sic2kp.git
cd sic2kppython -m venv venv
venv\Scripts\activate.batpython -m venv venv
venv\Scripts\Activate.ps1sudo apt-get update
sudo apt-get install python3 python3-venv
python3 -m venv venv
source venv/bin/activatesudo pacman -Syu
sudo pacman -S python
python -m venv venv
source venv/bin/activatesudo pacman -Syu
sudo pacman -S python
python -m venv venv
source venv/bin/activate.fishpip install --upgrade pip
pip install -r requirements.txtOr install packages directly:
pip install pycryptodomex xmltodict passlib pykeepass| Package | Version | Purpose |
|---|---|---|
pycryptodomex |
Latest | Cryptography for decryption |
xmltodict |
Latest | XML parsing |
passlib |
Latest | Password hashing utilities |
pykeepass |
Latest | KeePass database handling |
python main.py safeincloud.db output.kdbxYou will be prompted for:
- SafeInCloud Master Password - Your original SafeInCloud database password
- New KeePass Password - Password for the new KeePass database (with confirmation)
Protect your KeePass database with both a password and keyfile:
python main.py safeincloud.db output.kdbx --keyfile /path/to/keyfile.keypython main.py --helpThe tool intelligently categorizes entries based on GROUP_RULES keyword matching:
π‘ Tip: You can customize these categories! Edit the
GROUP_RULESdictionary at the top of main.py to add your own categories and keywords.
| Group | Keywords | Use Case |
|---|---|---|
| Finance | bank, insurance, tax, finance, paypal | Banking and financial accounts |
| Social | facebook, twitter, instagram, linkedin, tiktok | Social media accounts |
| Shopping | amazon, ebay, aliexpress, shop, store | E-commerce and shopping sites |
| Gaming | steam, epic, origin, uplay, battle.net, blizzard | Gaming platforms |
| Work | office, slack, zoom, teams, work | Work and productivity tools |
| gmail, outlook, webmail, mail | Email accounts |
How it Works:
- Each entry's Title and Email/Login fields are scanned for keyword matches (case-insensitive)
- The first matching category determines the entry's group
- Entries that don't match any rule stay in their original SafeInCloud group
- Groups are automatically created if needed
SafeInCloud: "Facebook Account" (facebook@example.com)
β Converted with 1 URL + 1 Password
KeePass Group: Social β "Facebook Account"
SafeInCloud: "Work VPN"
- URL 1: vpn1.company.com (password1)
- URL 2: vpn2.company.com (password2)
β Intelligently split into multiple entries
KeePass Group: Work
βββ "Work VPN"
βββ "vpn1 - Work VPN"
βββ "vpn2 - Work VPN"
SafeInCloud: "Cloud Service" (user@example.com)
β Domain automatically extracted
KeePass: Entry with URL "https://example.com"
All SafeInCloud field types are mapped appropriately:
- Standard fields: Username, password, URL, notes β Native KeePass fields
- Custom fields: Preserved as KeePass custom attributes
- Sensitive data: Fields containing "password", "pin", or "secret" are marked protected
Binary attachments from SafeInCloud are:
- Decoded from base64 format
- Stored as KeePass binary attachments
- Linked to the corresponding entry
If multiple entries have the same title:
Entry name: "Gmail (1)", "Gmail (2)", etc.
sic2kp/
βββ main.py # Main conversion script
βββ requirements.txt # Python dependencies
βββ README.md # This file
βββ .gitignore # Git ignore rules
"Failed to decrypt file. Check password."
- Verify your SafeInCloud master password is correct
- Ensure the
.dbfile is a valid SafeInCloud database - Try reopening your SafeInCloud app to ensure the database isn't corrupted
- Linux/macOS: If
venvcommand fails, install with:sudo apt-get install python3-venv(Debian) orbrew install python3(macOS) - Windows: Ensure Python is in your system PATH; reinstall Python with "Add Python to PATH" option checked
pip install --upgrade pip setuptools wheel
pip install -r requirements.txt --no-cache-dirIf specific packages fail:
pip install pycryptodomex xmltodict passlib pykeepass --force-reinstallchmod +x main.py
python main.py safeincloud.db output.kdbxEnsure all dependencies are properly installed:
pip list | grep -E "pycryptodomex|xmltodict|passlib|pykeepass"If any are missing:
pip install -r requirements.txt- The tool automatically converts
.kdbto.kdbxformat - If no extension is provided,
.kdbxis automatically added - Ensure you have write permissions in the output directory
- Decryption - SafeInCloud database is decrypted using AES-256-CBC with PBKDF2 derivation
- Parsing - XML structure is parsed to extract all cards (entries) and labels (groups)
- Classification - Each entry is categorized using keyword matching
- Group Creation - Original groups and automatic category groups are created in KeePass
- Entry Processing:
- Data is extracted from SafeInCloud fields
- Multiple URLs/passwords are intelligently split into separate entries if needed
- Icons are assigned based on field types
- Custom fields are preserved with protection for sensitive data
- Timestamps are migrated
- Attachments are converted
- Saving - Final KeePass database is saved with your specified password
- Your original SafeInCloud password is never saved or stored - it's only used to decrypt
- The new KeePass password is only set when you create the database - you set it yourself
- All processing happens in memory - no temporary unencrypted files are created
- Original SafeInCloud file remains untouched
- Perform this conversion on a trusted, secure computer
- Keep backup copies of both your SafeInCloud and KeePass databases
To customize how entries are categorized, edit the GROUP_RULES dictionary in main.py:
GROUP_RULES = {
"Finance": ["bank", "insurance", "tax", "finance", "paypal"],
"Social": ["facebook", "twitter", "instagram", "linkedin", "tiktok"],
"Shopping": ["amazon", "ebay", "aliexpress", "shop", "store"],
"Gaming": ["steam", "epic", "origin", "uplay", "battle.net", "blizzard"],
"Work": ["office", "slack", "zoom", "teams", "work"],
"Email": ["gmail", "outlook", "webmail", "mail"]
}Add or modify categories and keywords as needed. Keywords are case-insensitive.
Q: Can I reverse the conversion and go back to SafeInCloud? A: No, this tool is one-way only. Conversion to KeePass is permanent. Always keep a backup of your original SafeInCloud file.
Q: Will my folder structure be preserved? A: Yes! Your original SafeInCloud labels/groups are preserved as KeePass groups. Automatic categories are created additionally based on keyword rules.
Q: What if SafeInCloud has duplicate entry titles?
A: The tool automatically appends (1), (2), etc. to resolve duplicates.
Q: Can I use the same password for both SafeInCloud and KeePass? A: Yes, you can, but it's recommended to use a different, strong password for KeePass.
Q: What file formats does this support?
A: Input: SafeInCloud .db files only. Output: .kdbx format (KeePass 2.x and KeePassXC compatible).
Q: Is this tool official? A: No, this is a community tool. It's not affiliated with SafeInCloud or KeePass/KeePassXC projects.
Q: What happens to empty fields or notes? A: All non-empty fields are preserved. Empty fields and blank notes are discarded to keep the database clean.
Q: Can I convert multiple SafeInCloud databases? A: Yes, run the tool multiple times with different input/output files, or merge KeePass databases manually using KeePass.
Contributions are welcome! Please open an issue or pull request.
Note: Always keep your passwords and sensitive data secure. This tool handles encrypted databases carefully and respects your privacy.
