Video Sniffing

Complete technical documentation for FlowPick video detection and download, covering HLS, DASH, direct video files, encrypted stream decryption, and troubleshooting.

FlowPick automatically detects video content on webpages by monitoring browser network requests, supporting streaming protocols (HLS/DASH) and direct video files, with automatic decryption of AES-128 encrypted streams.


Detection Principles

FlowPick's video detection is based on the Chrome extension's webRequest API, intercepting requests at the browser network layer:

  1. Network Interception: Extension listens to all network requests via webRequest.onBeforeRequest, identifying video and streaming resources based on response Content-Type headers
  2. Manifest Parsing: For HLS (.m3u8) and DASH (.mpd), automatically downloads and parses manifest files to extract available stream information
  3. Quality Analysis: Parses all available resolution and bitrate options from Master Playlist
  4. Encryption Detection: Checks for presence of EXT-X-KEY (HLS) or ContentProtection (DASH) tags to determine if decryption is needed
  5. Resource Display: Detected videos are displayed categorized by type in popup window

Detection Timing:

  • After extension installation, need to refresh target page before detection can begin
  • Streaming manifests typically load when video starts playing; recommend playing for 3-5 seconds before opening extension
  • For dynamically loaded videos (e.g., loading when scrolling to specific position), need to trigger loading before detection
For extension webRequest API permissions and Manifest V3 limitations, see Known Limitations — Manifest V3 Limitations. For complete troubleshooting flow when media is not detected, see Common Issues Troubleshooting — Media Detection Issues.

Supported Video Formats

Streaming Protocols

ProtocolManifest FileContent-TypeDescription
HLS.m3u8application/x-mpegurlApple HTTP Live Streaming, most common streaming protocol
HLS.m3u8application/vnd.apple.mpegurlApple-specific MIME type for HLS
DASH.mpdapplication/dash+xmlMPEG-DASH, commonly used for high-quality content

Direct Video Files

Content-TypeExtensionDescription
video/mp4.mp4Most universal video format
video/x-m4v.mp4iTunes video format
video/webm.webmOpen-source Web video format
video/ogg.ogvOgg container video
video/x-flv.flvFlash Video (legacy format)
video/x-matroska.mkvMatroska container
video/quicktime.movApple QuickTime
video/x-msvideo.aviWindows AVI
video/3gpp.3gpMobile device video
video/3gpp2.3g2CDMA mobile device video
video/mpeg.mpegMPEG video

HLS (M3U8) Streams

HLS (HTTP Live Streaming) is a streaming protocol developed by Apple and currently the most widely used video transmission method on the web. Major platforms like Bilibili, Tencent Video, and Youku all use HLS.

Master Playlist vs Media Playlist

HLS manifests are divided into two levels:

TypeContentExample
Master PlaylistLists all available quality variants, each pointing to a Media PlaylistIndex containing multiple streams at 360p, 720p, 1080p, etc.
Media PlaylistLists specific TS fragment URL sequenceContains addresses of hundreds of .ts files

FlowPick auto-identifies Master Playlists, parses out all quality options for you to select. After selecting quality, downloads corresponding Media Playlist to get fragment list.

Master Playlist (index.m3u8)
    │
    ├── 360p  → 360p.m3u8  →  segment-001.ts, segment-002.ts, ...
    ├── 720p  → 720p.m3u8  →  segment-001.ts, segment-002.ts, ...
    └── 1080p → 1080p.m3u8 →  segment-001.ts, segment-002.ts, ...

Quality Selection

Quality options parsed from Master Playlist are sorted by bitrate from high to low:

QualityTypical ResolutionTypical BitrateUse Case
Original/Ultra HD1080p+5-12 MbpsLarge screen viewing, best quality needed
HD720p1.5-3 MbpsLaptop viewing
SD480p0.8-1.5 MbpsSmall screen devices
Smooth360p0.4-0.8 MbpsAudio only, mobile networks
For quality selection configuration (auto/manual), see Configuration Reference — Quality Selection Strategy.

Fragment Download & Merging

HLS videos consist of large numbers of TS fragments (typically 2-10 seconds each). FlowPick's processing flow:

  1. Parse Media Playlist to get all fragment URLs
  2. Multi-threaded concurrent download of fragments (concurrency adjustable in settings)
  3. After download completes, merge fragments into single file
  4. If MP4 output selected, use FFmpeg WASM for remuxing
For Worker Pool implementation of concurrent fragment download and retry mechanism, see Download Engine Architecture. For TS to MP4 remuxing principles, see Format Conversion.

Encrypted Streams (AES-128)

Some HLS streams use AES-128 encryption to protect content. FlowPick supports automatic decryption:

  • Detects #EXT-X-KEY:METHOD=AES-128,URI="..." tag
  • Auto-downloads decryption key
  • Uses Web Crypto API to decrypt each fragment in browser
  • Decrypted fragments merge normally, output unencrypted file
FlowPick only supports AES-128 encryption. Streams using DRM technologies like Widevine, PlayReady, or FairPlay cannot be decrypted. If DRM protection detected, corresponding error message displayed. For detailed technical explanation of DRM protection, see Known Limitations — DRM Protected Content.

DASH (MPD) Streams

DASH (Dynamic Adaptive Streaming over HTTP) is an international standard streaming protocol established by MPEG, widely used by platforms like YouTube and Netflix.

DASH Characteristics

Compared to HLS, DASH has these characteristics:

FeatureHLSDASH
Fragment FormatUsually TSUsually FMP4 (segmented MP4)
Audio/VideoUsually combined togetherUsually separated as independent tracks
Manifest FormatM3U8 (text)MPD (XML)
EncryptionAES-128AES-128 or DRM
CodecsH.264 dominantH.264, H.265, VP9, AV1

Separate Audio/Video Processing

A key characteristic of DASH is that video and audio are usually separated into independent tracks. FlowPick's processing flow:

  1. Parse MPD manifest, identify video track and audio track
  2. Download video fragments and audio fragments separately
  3. Download initialization segments (init segment), containing codec configuration info
  4. Use FFmpeg WASM to merge video and audio into single MP4 file
MPD Manifest
    │
    ├── AdaptationSet: Video (H.264, 1080p)
    │   ├── init segment (codec config)
    │   ├── segment-001.m4s
    │   ├── segment-002.m4s
    │   └── ...
    │
    └── AdaptationSet: Audio (AAC, 128kbps)
        ├── init segment (codec config)
        ├── segment-001.m4s
        ├── segment-002.m4s
        └── ...
                    ↓
            FFmpeg WASM Merge
                    ↓
              output.mp4
For technical implementation of DASH FMP4 reassembly and audio-video merging, see Download Engine Architecture — DASH Processing. For FFmpeg WASM loading and performance, see Format Conversion — FFmpeg WASM Engine.

Encryption Support

Same as HLS, FlowPick supports AES-128 fragment-level encryption for DASH streams. DRM-protected streams (Widevine, PlayReady) cannot be handled.


Direct Video Files

For direct video files (MP4, WebM, MKV, etc.), detection and download process is simplest:

  • Instant Detection: Video URL immediately detected when appears in network requests
  • Direct Download: No fragment merging or format conversion needed, browser directly downloads original file
  • Size Preview: If server returns Content-Length header, file size displayed

Direct video files typically appear in following scenarios:

  • MP4 videos embedded directly in websites
  • Short videos on social media
  • Video assets on gallery websites
  • Directly linked video files
For direct video file download operations, see Usage Guide — Download Single Resource.

Detection Differences: Extension vs Online Tool

CapabilityBrowser ExtensionOnline Tool
Auto DetectionAuto-monitors all network requestsRequires manual paste of stream URL
CORS RestrictionsUnrestricted (extension permissions)Subject to same-origin policy
Encrypted StreamsSupports AES-128 decryptionSupports AES-128 decryption
Detection ScopeAll requests on current tabOnly user-provided URLs
Usage BarrierRequires extension installationNo installation needed
If you encounter CORS errors using online tool, it means streaming server hasn't configured cross-origin headers. In this case, recommend installing browser extension to bypass restrictions. For detailed feature comparison between extension and online tool and selection recommendations, see Online Tools — Comparison with Extension.

Troubleshooting

Video Not Detected

CauseSolution
Page loaded before extension installedRefresh page and replay video
Video not started playingPlay video for 3-5 seconds, ensure manifest file loaded
Video uses dynamic loadingDrag progress bar to different positions to trigger more fragment requests
Website uses non-standard protocolsCheck if HLS/DASH/direct video files supported
Other extension conflictsTemporarily disable ad blockers or other network extensions and retry

Encrypted Stream Download Failed

CauseSolution
DRM protection (Widevine etc.)Not supported, FlowPick cannot decrypt DRM content
Key server requires authenticationSome paid content keys require Cookie/Token, ensure logged in
Key URL inaccessibleCheck network connection, key server may be blocked by firewall

Slow Download Speed

CauseSolution
Concurrent threads too lowIncrease concurrent threads in settings (recommend 4-6)
CDN rate limitingSome CDNs limit per-IP speed, cannot bypass
Insufficient network bandwidthSelect lower quality to reduce file size

Merged Video Cannot Play

CauseSolution
Some fragments failed to downloadRe-download, ensure all fragments complete
Output format incompatibleTry switching output format (MP4 ↔ TS)
Encryption key errorRefresh page to re-obtain key
If above methods don't resolve issue, please check Common Issues Troubleshooting for more detailed diagnostic steps. For technical limitations and edge cases of current version, see Known Limitations.