Secure token generation and verification engine with rate limiting
Project description
๐ก๏ธ SyckSec โ Next-Gen Token Security
Unbreakable โข Unpredictable โข Unrecognizable
SyckSec is a context-aware, multi-layer token security system designed to replace brittle, predictable authentication tokens like JWTs.
It blends encryption, obfuscation, visual camouflage, and adaptive intelligence to create tokens that are unreadable, unpredictable, and bound to the environment.
๐ Table of Contents
- Problem
- Solution
- Core Features
- Architecture Overview
- Security Advantages
- Open Source vs SaaS
- Installation
- Quick Start
- Configuration
- API Usage
- Security Considerations
- Contributing
- License
- Contact
โ Problem
Authentication tokens in most applications suffer from:
- Predictable structures (e.g., JWT = header.payload.signature)
- Weak context binding (valid anywhere until expiry)
- Replay vulnerabilities
- Lack of built-in anti-analysis
Result:
Tokens can be stolen, replayed, or brute-forced offline, leading to costly breaches in finance, healthcare, and government applications.
๐ก Solution
SyckSec creates multi-layer encrypted, context-bound tokens with dynamic obfuscation and visual camouflage.
- Unreadable: AES-256 encryption + HMAC signature + per-layer random IVs.
- Unpredictable: Dynamic per-user obfuscation patterns rotate hourly.
- Unrecognizable: UUID-like visual formatting + checksum validation.
- Context-Aware: Tokens bound to device, location, and behavior.
๐ก Core Features
Multi-Layer Adaptive Security
- 1โ3 layers of AES-256 encryption
- HMAC signatures for integrity
- Constant-time signature verification
Advanced Obfuscation Engine
- Dynamic pattern generation (hourly)
- Pattern-based noise injection
- Base64 encoding with intelligent padding
Visual Camouflage
- UUID-like formatting
- SHA-256 checksum
- Anti-analysis formatting
Context Awareness
- Device fingerprint binding
- Location & usage pattern checks
- Client type identification
Enterprise Features
- Built-in rate limiting
- Batch token verification
- LRU caching for pattern recipes
- Full audit trail
๐ Architecture Overview
Generation
Client Request
โ
โโโถ Token Generator
โ โโ Context Binding (device/location/behavior)
โ โโ Payload Signing (HMAC)
โ โโ Multi-Layer Encryption (AES-256)
โ โโ Visual Camouflage + Checksum
โ
โโโถ Secure Delivery (cookie/header)
Verification
Incoming Token
โ
โโโถ Pattern Detection
โโโถ De-camouflage
โโโถ Signature Verification
โโโถ Context Check
โโโถ Allow / Reject
๐ Security Advantages
| Attack Surface | JWT (typical) | SyckSec (implemented) |
|---|---|---|
| Token tampering | Signature only | Signature + deterministic obfuscation + checksum |
| Replay | exp/nbf only | Context binding (device/location/behavior) |
| Key rotation | Manual kid | Recipe versioning + per-layer keys |
| Offline brute force | Base64url, 3 dots โ easy to spot | UUID-like camouflage + decoys |
| Stolen token | Valid until expiry | Self-healing refresh + context check |
| Mass issuance abuse | N/A | Built-in rate limiting + audit logs |
| Side-channel | Timing attacks possible | Timing variance + constant-time ops |
๐ Open Source vs ๐ผ SaaS
| Feature | Open Source | SaaS / Enterprise |
|---|---|---|
| AES Encryption (1โ2 layers) | โ | โ |
| AES Encryption (3 layers) | โ | โ |
| HMAC Signature | โ | โ |
| Dynamic Patterns | โ | โ |
| Device Fingerprint Binding | โ | โ |
| GeoIP & Behavioral Analytics | โ | โ |
| Built-in Rate Limiting | โ | โ |
| Dashboard & Forensics Export | โ | โ |
| SLA & Enterprise Support | โ | โ |
โ Installation
# Python SDK
pip install sycksec
๐ Quick Start
from sycksec import SyckSec
import os
# Set secret (in production, use env vars)
os.environ['SYCKSEC_SECRET'] = 'your-secure-secret-32-chars-long!'
# Initialize client
sycksec = SyckSec()
# Custom recipe
custom_recipe = {
"version": "custom_secure_v1",
"pattern": [10, "core", 15, "core", 8],
"charset": "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!@#$%^&*()-_=+",
"randomize_noise": False,
"noise_variance": 0
}
# Device info (optional)
device_info = {
"fingerprint": "web_browser_123",
"location": "US",
"pattern": "standard",
"client_type": "web"
}
# Generate token
token = sycksec.generate(
user_id="test_user_123",
ttl=3600, # 1 hour
device_info=device_info,
custom_recipe=custom_recipe
)
print("Generated Token:", token)
โ Verify a Token
# Verify token with custom recipe
payload = sycksec.verify(
token=token,
user_id="test_user_123",
custom_recipe=custom_recipe
)
print("Verified Payload:", payload)
โป Refresh Token if Needed
# Simulate near-expiry in test mode
os.environ['SYCKSEC_ENV'] = 'test' # For demo; remove in production
refreshed_token = sycksec.refresh_token_if_needed(
token=token,
user_id="test_user_123"
)
if refreshed_token:
print("Refreshed Token:", refreshed_token)
else:
print("Token still valid, no refresh needed")
๐ก API Usage
generate(user_id, context, custom_recipe)โ Create a new token bound to the provided context.verify(token, user_id, custom_recipe)โ Verify, decrypt, and check context validity.refresh_token_if_needed(token, user_id)โ Refresh before expiry while keeping context.
โ Security Considerations
- Always transmit SyckSec tokens over HTTPS.
- Use
HttpOnly+Securecookies for web delivery. - Enable context binding for sensitive applications.
- Rotate keys regularly in SaaS mode.
- Review audit logs for anomalies.
๐ค Contributing
We welcome contributions! See CONTRIBUTING.md for details.
๐ License
- Core SDKs โ MIT License (Open Source)
- Enterprise SaaS โ Proprietary License
๐ฌ Contact
Website: https://sycksec.com Email: contact@sycksec.com
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file sycksec_token-1.0.0.tar.gz.
File metadata
- Download URL: sycksec_token-1.0.0.tar.gz
- Upload date:
- Size: 27.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6e7d9a63b99368bef922050e8e65d6b038fe3a52413cc67f05542375ecc03baa
|
|
| MD5 |
bc897ac78046a725100b601b8c948bea
|
|
| BLAKE2b-256 |
e132c7e90bf2f513b114a08f80efc6c65ab846ae784388368ef442f765535fec
|
File details
Details for the file sycksec_token-1.0.0-py3-none-any.whl.
File metadata
- Download URL: sycksec_token-1.0.0-py3-none-any.whl
- Upload date:
- Size: 23.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
51159b382d58e28925bc404ca729647ec95c6298bdb985452a205f3f097ab523
|
|
| MD5 |
cf98b64974956a304ff357038c24b757
|
|
| BLAKE2b-256 |
d9ef5d15a4acb71f54f073cfd019c685ab489c75e692d7d9c7835b35d8d3a7e1
|