License System for Dai Chao Online
Project description
License System
Project Description
License System is a lightweight Python package for managing desktop software licenses on Windows.
It generates license keys tied to a unique hardware ID (HWID), stores the license securely in the Windows Registry, and validates it online using Google Sheets.
This package is designed for developers who want a simple but effective way to:
- Control application access
- Bind licenses to specific machines
- Set expiry dates
- Approve or reject users remotely
- Receive Telegram notifications for new registrations
Fixed Issues
- Fixed the issue where the license key was not being generated correctly.
Usage
from license_system.license_manager import LicenseKeys
from license_system.telegram_notifier import TelegramNotifier
# Optional: enable Telegram notification
telegram = TelegramNotifier(
token="YOUR_BOT_TOKEN",
chat_id="YOUR_CHAT_ID"
)
# Create license manager
license_manager = LicenseKeys(
telegram=telegram,
sheetID="YOUR_GOOGLE_SHEET_ID"
)
# Step 1: Generate license if not exists
license_manager.check_or_generate_license()
# Step 2: Validate license
if license_manager.validate_local_license():
print("License is valid")
else:
print("License is invalid or expired")
# Step 3: Get expiry date
expiry = license_manager.get_online_expiry_date()
print("License expires on:", expiry)
Installation
pip install dc-license-system
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
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 dc_license_system-0.0.5.tar.gz.
File metadata
- Download URL: dc_license_system-0.0.5.tar.gz
- Upload date:
- Size: 3.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bfc5991f819bdf18b4716b0eba652a43d54fa3ac8c3bda680033a5dac4355702
|
|
| MD5 |
bd552194918d404270c18fb5b6450a2b
|
|
| BLAKE2b-256 |
dce19e6956a33a1c249b6e0b1ad2de2b840eca2db96e3836f3727f4a0e6da329
|
File details
Details for the file dc_license_system-0.0.5-py3-none-any.whl.
File metadata
- Download URL: dc_license_system-0.0.5-py3-none-any.whl
- Upload date:
- Size: 4.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
359060c4f2b0c0c421b8c9b4e2f221ccdaf3b7edc0fd5837de6abc7f87340548
|
|
| MD5 |
7488d5fe8a3682ce0bce2df442840801
|
|
| BLAKE2b-256 |
c35af86df48f8d4f7219de2b2293f7204233ec443ec0c5989176f1209a9e18d4
|