=== StreamDRM Forensic Video & Document Protection ===
Contributors: streamdrm
Tags: video-protection, drm, woocommerce, watermarking, learndash, memberpress
Requires at least: 5.8
Tested up to: 6.7
WC requires at least: 6.0
WC tested up to: 9.4
Requires PHP: 7.4
Stable tag: 1.1.0
License: GPL-2.0-or-later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Zero-dependency drop-in plugin for WordPress, WooCommerce, MemberPress, and LearnDash that protects courses, paid PDFs, and videos with per-buyer forensic passes and server-side ticket minting.

== Description ==

StreamDRM protects high-ticket courses, books/PDFs, trading communities, and research libraries by binding every playback session to the buyer or viewer identity (`user_ref`) with a camera-survivable spread-spectrum watermark.

**Two zero-friction WordPress modes included:**
1. **Member Shortcode (`[streamdrm]`):** Configure `ApiBaseUrl` (`https://streamdrm.com`), `TenantID`, and `ApiKey` under **Settings -> StreamDRM**, then drop `[streamdrm asset="ast_..." width="100%" height="540px"]` into any LearnDash lesson or MemberPress page. WordPress calls `POST /v1/tickets` server-side via `wp_remote_post()` so your API key never touches the browser.
2. **Native WooCommerce Storefront Protection (HPOS-ready):** Set **StreamDRM Asset ID / Ref** on any WooCommerce product or variation. On purchase completion (`Completed` or optional `Processing`), WooCommerce automatically mints a personal buyer access pass (`POST /v1/passes` with order idempotency), renders the protected viewer button on the Thank-You page, My Account Orders page, and customer emails, and automatically revokes access (`POST /v1/passes/{id}/revoke`) if the order is refunded or cancelled.
3. **Privacy & Handshake Hardening:** Supports **GDPR Zero-PII Mode** (sending `wp_user_42` / `wc_order_101` instead of buyer emails) and **Origin-Locked `postMessage` Ticket Handshake** (`player.html?mode=postmessage`) with immediate DOM attribute scrubbing so DevTools inspection (`F12`) reveals zero tokens.

== Installation ==

1. Download `streamdrm-embed.zip` from your StreamDRM Studio Console (`/integrations/wordpress/streamdrm-embed.zip`).
2. In WordPress Admin, go to **Plugins -> Add New -> Upload Plugin** and activate **StreamDRM Forensic Video & Document Protection**.
3. Go to **Settings -> StreamDRM** and enter your `ApiBaseUrl` (`https://streamdrm.com`), `TenantID`, and `ApiKey`.
4. For gated membership/course lessons, add `[streamdrm asset="YOUR_ASSET_ID" width="100%" height="540px"]`.
5. For WooCommerce products (ebooks, PDFs, standalone courses), enter your **StreamDRM Asset ID / Ref** under **Product Data -> General**.
