https://github.com/shamallakshan/binswap
A simple string encoding algorithm I wrote in Python.
https://github.com/shamallakshan/binswap
binary binswap decode decrypt encode encrypt hex hexadecimal python reverse string-encryption
Last synced: about 1 month ago
JSON representation
A simple string encoding algorithm I wrote in Python.
- Host: GitHub
- URL: https://github.com/shamallakshan/binswap
- Owner: ShamalLakshan
- License: unlicense
- Created: 2022-03-13T14:08:26.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2024-08-08T15:28:05.000Z (almost 2 years ago)
- Last Synced: 2025-03-17T15:58:52.197Z (over 1 year ago)
- Topics: binary, binswap, decode, decrypt, encode, encrypt, hex, hexadecimal, python, reverse, string-encryption
- Language: C++
- Homepage:
- Size: 669 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# BinSwap
A lightweight, key-based text encoder/decoder implementing XOR encryption with binary manipulation. Designed for personal, low-security encoding tasks.
## Features
- **Key-based encryption** using XOR cipher
- **Binary bit reversal** for additional obfuscation
- **Dual output formats**: Base-4 (Quaternary) and Hexadecimal
- **Text and file operations** with intuitive TUI
- **Cross-platform** Python implementation
## How It Works

### Encryption Process
1. **Extend Key**: Repeat encryption key to match input length
2. **XOR Operation**: Apply XOR cipher using extended key
3. **Binary Conversion**: Convert result to 8-bit binary
4. **Bit Reversal**: Reverse each byte for obfuscation
5. **Format Encoding**: Output as Base-4 or Hexadecimal
### Example
```
Input: "hello"
Key: "secret"
Output: "d8e0781450" (Hexadecimal)
```
## Requirements
Python 3.6 or higher (no external dependencies)
## Security Notice
**WARNING**: BinSwap is intended for personal, low-security use only. Not cryptographically secure.
## Technical Details
- **Algorithm**: XOR cipher with binary bit reversal
- **Output formats**: Base-4 (quaternary) and Hexadecimal
---
**Remember**: Always keep your encryption key safe. Without it, encoded data cannot be recovered.