You've already forked wc-licensed-product
Update CLAUDE.md with v0.4.0 session history
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
35
CLAUDE.md
35
CLAUDE.md
@@ -36,9 +36,9 @@ This project is proudly **"vibe-coded"** using Claude.AI - the entire codebase w
|
||||
|
||||
No known bugs at the moment.
|
||||
|
||||
### Version 0.4.0
|
||||
### Version 0.5.0
|
||||
|
||||
- Self-licensing prevention: Plugin automatically bypasses license validation when the configured license server URL points to the same WordPress installation (prevents circular dependency)
|
||||
No changes at the moment.
|
||||
|
||||
## Technical Stack
|
||||
|
||||
@@ -1159,3 +1159,34 @@ Fixed a critical bug where licenses were not generated for orders created manual
|
||||
- Created release package: `releases/wc-licensed-product-0.3.9.zip` (851 KB)
|
||||
- SHA256: `fdb65200c368da380df0cabb3c6ac6419d5b4731cd528f630f9b432a3ba5c586`
|
||||
- Tagged as `v0.3.9` and pushed to `main` branch
|
||||
|
||||
### 2026-01-24 - Version 0.4.0 - Self-Licensing Prevention
|
||||
|
||||
**Overview:**
|
||||
|
||||
Added self-licensing prevention to avoid circular dependency when the plugin tries to validate its license against itself.
|
||||
|
||||
**Implemented:**
|
||||
|
||||
- Self-licensing detection: Plugin automatically bypasses license validation when the configured license server URL points to the same WordPress installation
|
||||
- New `isSelfLicensing()` method in `PluginLicenseChecker` to detect circular licensing scenarios
|
||||
- New `normalizeDomain()` helper method for domain comparison (strips www prefix, lowercases)
|
||||
- Cache property `$isSelfLicensingCached` for efficient repeated checks
|
||||
|
||||
**Modified files:**
|
||||
|
||||
- `src/License/PluginLicenseChecker.php` - Added self-licensing detection methods and bypass logic
|
||||
|
||||
**Technical notes:**
|
||||
|
||||
- Self-licensing detection compares normalized domains of license server URL and current site URL
|
||||
- Prevents circular dependency where plugin would try to validate against itself
|
||||
- Plugins can only be validated against the original store from which they were obtained
|
||||
- Bypass check added to both `isLicenseValid()` and `validateLicense()` methods
|
||||
- Cache clearing via `clearCache()` also clears the self-licensing check cache
|
||||
|
||||
**Release v0.4.0:**
|
||||
|
||||
- Created release package: `releases/wc-licensed-product-0.4.0.zip` (852 KB)
|
||||
- SHA256: `cf8769c861d77c327f178049d5fac0d4e47679cc1a1d35c5b613e4cd3fb8674f`
|
||||
- Tagged as `v0.4.0` and pushed to `main` branch
|
||||
|
||||
Reference in New Issue
Block a user