pardnchiu / session
This package is abandoned and no longer maintained.
No replacement package was suggested.
PD\Session is a flexible PHP session manager with Redis support and filesystem fallback. Provides secure session handling.
1.0.0
2025-02-02 21:20 UTC
Requires
- php: >=8.0
Requires (Dev)
None
Suggests
- pardnchiu/redis: For Redis caching support
Provides
None
Conflicts
None
Replaces
None
README
Last updated: 2026-10-25
Note
This README was generated by SKILL, get the ZH version from here.
SESSIONS THAT SURVIVE A REDIS OUTAGE!
A PHP session manager with Redis-backed storage, automatic filesystem fallback, and session fixation protection
Table of Contents
Features
composer require pardnchiu/session· Documentation
- Redis First, Files as Fallback — Native PHP sessions move to Redis while it is available and fall back to storage/sessions under the document root when it is not.
- Native Session Compatible — Only the save handler and save path change, so existing code that reads and writes $_SESSION keeps working untouched.
- Seven-Day Login Retention — Cookie lifetime and garbage collection lifetime are both set to 7 days, keeping users signed in across browser restarts.
- Session Fixation Protection — One method regenerates the session ID and deletes the old session data at the same time.
- Creation Time Tracking — The session creation time is recorded on first lookup, making idle or absolute timeouts easy to build.
Architecture
graph TB
A[new PD\Session] --> B{Redis connected?}
B -->|Yes| C[save_handler = redis]
B -->|No| D[save_handler = files]
C --> E[session_start]
D --> E
E --> F[set / get / delete / regenerateId]
Loading
License
This project is licensed under the MIT LICENSE.
Author
Just open an issue to share an idea.
©️ 2024 邱敬幃 Pardn Chiu