Page MenuHomePhabricator

Automated Media Scraper Detection (PP3.1.2)
Open, Needs TriagePublic

Description

If we apply advanced signal processing and clustering techniques to media requests data, we will be able to recommend a set of new signals that can be used by SRE to detect media scrapers automatically.

Context: Over the past years, we have seen a substantial increase in automated traffic to Wikipedia. Specifically, media scrapers are the most costly for our infrastructure, see also a recent scraping incident. Unfortunately, identifying those scrapers is an open problem. While we have some individual heuristics, they are very noisy and, as a result, there is a high risk of unintentionally also blocking actual user traffic. Therefore, the goal of this project is to identify potential patterns that can more reliably detect media scrapers. We will apply embedding techniques to webrequest data from media scrapers to capture the similarity between individual requests or actors. One starting point is the tooling developed in T415637 and apply to this specific use case. Alternative approaches include integrating the individual signals used in previous heuristics into a common feature space. Applying clustering techniques, we can identify characteristic patterns by manually labeling a small number of known scrapers. The deliverable of this work is a recommendation of a set of new signals that can be used by SRE to detect media scrapers automatically.

Event Timeline

weekly update

  • Reading up on existing work relevant for this work
    • Bot threat model: processing pipeline for (media) requests; specifically, annotation with known bots, and how to calculate relevant metrics
      • RDS investigation on scraping incident : provides some intuition about additional metrics that can be used as features (on top of the bot thread model)
      • Media traffic dashboard: relevant details about how to process media requests, e.g., identifying different file types (images vs thumbnails)
  • Starting to collect small sample to run exploratory analysis of media requests with summary statistics
  • Collecting a set of relevant features for dimensionality reduction/clustering

weekly update

  • Defined the set of variables for analysis of individual media requests based on previous
  • Collected a sample dataset of one hour (~100M requests) for exploratory analysis
  • Built data-processing pipeline for represeting categorical data as numeric data via one-hot-encoding
  • Currently building the clustering model to group individual requests based on their characteristics combining PCA and Kmeans (potentially later to be updated with more robust clustering such as HDBSCAN)