=== VaaniLog ===
Contributors: ashwin91
Tags: activity log, audit log, user tracking, security, monitoring
Requires at least: 6.5
Tested up to: 7.1
Requires PHP: 8.1
Stable tag: 1.0.1
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Track every important change on your WordPress site — who did what, when, and what changed — in a clear, human-readable timeline.

== Description ==

VaaniLog is a lightweight activity log and audit trail plugin for WordPress. It records the changes that matter on your site so you always know who did what, and when — without digging through server logs or guessing what happened after something breaks.

**What VaaniLog tracks**

* Post and page edits — content changes, publishing, and deletions
* User and role changes — logins, logouts, profile and role updates
* Plugin and theme activity — activation, deactivation, and updates
* WordPress core updates
* Settings changes across your site

**Why use VaaniLog**

* **Human-readable timeline.** No raw database dumps — every event is shown in plain language with before/after context where it matters.
* **Fast to scan.** Filter by user, event type, or date to find what you're looking for in seconds.
* **Privacy-conscious by default.** Raw post content isn't stored in change snapshots, and common credential/token fields are automatically redacted from tracked settings.
* **Self-contained.** All logs stay in your own WordPress database — nothing is sent to an external service.
* **Automatic cleanup.** Old entries are pruned on a schedule you control (30, 90, 180, 365 days, or kept indefinitely), so the log table never grows unbounded.
* **Zero configuration to start.** Activate it and VaaniLog starts logging immediately, with sensible defaults you can adjust anytime.

Whether you're troubleshooting an unexpected change, keeping a client site accountable, or just want visibility into your own WordPress admin activity, VaaniLog gives you a clear record without the overhead of a full security-audit suite.

== Installation ==

1. Upload the plugin through the WordPress Plugins screen, or install it directly from the WordPress Plugin Directory.
2. Activate VaaniLog.
3. Open **VaaniLog** in the WordPress admin menu to view the Dashboard and Timeline.
4. Visit **VaaniLog → Settings** to adjust what's tracked and how long logs are retained.

== Frequently Asked Questions ==

= Does VaaniLog slow down my site? =

No. Logging runs on standard WordPress hooks and writes to a dedicated database table, so there's no measurable impact on front-end performance.

= Where is the log data stored? =

Everything is stored locally in a custom table in your own WordPress database. VaaniLog does not send any data to an external service.

= Does VaaniLog log post content? =

No. To reduce sensitive-data exposure, raw post content is not stored in change snapshots.

= How long are logs kept? =

By default, entries older than 90 days are removed automatically. You can change this under Settings to 30, 90, 180, or 365 days, or keep logs indefinitely.

= What happens to the logs if I deactivate or delete the plugin? =

Deactivating VaaniLog stops new logging but keeps existing data. Deleting the plugin removes its database table and stored settings.

= Can I control which events are tracked? =

Yes. Under Settings, you can toggle tracking for users, plugins, themes, posts/pages, and site settings independently.

== Screenshots ==

1. Dashboard — a quick overview of today's changes, activity trends, and system health at a glance.
2. Timeline — a searchable, filterable log of every tracked event with user, type, and timestamp.
3. Settings — control exactly what's tracked and how long log entries are retained.

== Changelog ==

= 1.0.1 =
* Fixed: Event Details screen referenced a non-existent IP address field, causing a PHP warning on that screen.
* Added: Automatic daily cleanup of old log entries, with a configurable retention period (30/90/180/365 days, or forever) under Settings.
* Added: Database schema now stays in sync automatically after plugin updates, without needing to deactivate and reactivate.
* Hardened: A few admin-screen output values that were not explicitly escaped (all were static strings, not user input, so this was a defense-in-depth fix rather than a fix for an actual vulnerability).

= 1.0.0 =
* Initial release.

== Upgrade Notice ==

= 1.0.1 =
Fixes a PHP warning on the Event Details screen and adds automatic log cleanup with a configurable retention period. Recommended for all users.

== Privacy ==

VaaniLog stores audit events in a custom database table on your WordPress site. It does not send logged data to an external service.

To reduce sensitive-data exposure, the plugin does not store raw post content in change snapshots and redacts common credential and token fields from tracked option values. Log entries are automatically deleted after 90 days by default; this retention period is configurable under Settings (30/90/180/365 days, or kept indefinitely). Administrators should review the site's tracking settings and retention practices before enabling monitoring on sensitive environments.