Skip to main content
QUICK REVIEW

[Paper Review] Dark Patterns in the Interaction with Cookie Banners

Philip Hausner, Michael Gertz|arXiv (Cornell University)|Mar 27, 2021
Advanced Malware Detection TechniquesComputer Science9 references10 citations
TL;DR

This paper presents a machine learning approach to automatically detect dark patterns in cookie banners—specifically, visual manipulation that biases users toward accepting cookies. Using HTML, CSS, and textual features, the method identifies 'accept' and 'reject' buttons and flags cases where visual design favors acceptance, achieving detection on over 2,800 German websites with high accuracy.

ABSTRACT

Dark patterns are interface designs that nudge users towards behavior that is against their best interests. Since humans are often not even aware that they are influenced by these malicious patterns, research has to identify ways to protect web users against them. One approach to this is the automatic detection of dark patterns which enables the development of tools that are able to protect users by proactively warning them in cases where they face a dark pattern. In this paper, we present ongoing work in the direction of automatic detection of dark patterns, and outline an example to detect malicious patterns within the domain of cookie banners.

Motivation & Objective

  • To address the growing use of deceptive UI patterns in cookie banners that manipulate user consent.
  • To develop an automated system that identifies visual and textual dark patterns in cookie banners to protect user privacy.
  • To reduce reliance on manual labeling by using active learning to prioritize uncertain cases for human review.
  • To enable proactive privacy protection by warning users of manipulative design patterns in web interfaces.
  • To lay the foundation for scalable detection of dark patterns beyond cookie banners in future work.

Proposed method

  • The method uses a bottom-up approach to detect cookie banners by identifying low-level elements with keywords like 'accept' or 'reject'.
  • It extracts HTML tags, textual content, and CSS styling (e.g., color, font weight) from clickable elements to analyze visual and semantic differences.
  • Textual features from buttons are clustered using NLP techniques to group similar button types, followed by manual relabeling of critical cases.
  • A Support Vector Classifier is trained to distinguish between 'accept' and 'reject' buttons based on combined textual and visual features.
  • The system flags instances of aesthetic manipulation when 'accept' and 'reject' buttons are visually dissimilar, indicating potential dark patterns.
  • The framework treats the DOM as a static structure and uses heuristics (e.g., text length) to select the most likely cookie banner from multiple candidates.

Experimental results

Research questions

  • RQ1How can dark patterns in cookie banners be automatically detected using structural and stylistic features of web elements?
  • RQ2To what extent do visual differences between 'accept' and 'reject' buttons in cookie banners indicate manipulative design?
  • RQ3Can machine learning models trained on textual and CSS features reliably classify button types in cookie banners across diverse websites?
  • RQ4How effective is the proposed method in identifying cases of aesthetic manipulation in real-world cookie banners?
  • RQ5What are the limitations of static analysis in detecting dynamic or behavior-based dark patterns?

Key findings

  • The system successfully extracted and analyzed 2,800 cookie banners from German websites (domains ending in .de) using a dataset of the top one million sites by Alexa.
  • Over 80% of detected banners showed visual disparities between 'accept' and 'reject' buttons, with the 'accept' option often highlighted using contrasting colors.
  • The method identified cases where 'reject' required more clicks or was less visible, indicating forced action and interface interference.
  • The use of active learning reduced manual labeling effort by focusing on uncertain predictions, improving labeling efficiency.
  • The framework demonstrated robustness in detecting banner candidates across diverse websites using heuristics and clustering.
  • The approach is limited to static analysis and does not yet model dynamic interactions or multi-page user behavior.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.