Django Application Error Exceptions Matching SuspiciousOperation and Security Exceptions

Identifies Django logs containing suspicious security-related exception names that may indicate exploitation attempts.

FreeReviewedSigma · Medium · v5
Product
django
Category
application
Author
Thomas Patzke (SigmaHQ), DRL 1.1
Published
2017-08-05
Updated
2026-07-31
title: Django Application Error Exceptions Matching SuspiciousOperation and Security Exceptions
id: d4e72cea-ee5c-466c-bac8-cdad39947b2a
status: stable
description: This rule flags application log events from Django that contain exception names related to SuspiciousOperation and specific security-focused subclasses such as DisallowedHost, DisallowedRedirect, InvalidSessionKey, PermissionDenied, and RequestDataTooBig. These exceptions can occur when an attacker sends unexpected or malicious requests designed to trigger validation, authorization, or request-handling failures. The detection relies on application telemetry where Django exceptions are recorded as keyworded exception identifiers in log messages.
references:
  - https://docs.djangoproject.com/en/1.11/ref/exceptions/
  - https://docs.djangoproject.com/en/1.11/topics/logging/#django-security
  - https://github.com/SigmaHQ/sigma/blob/master/rules/application/django/appframework_django_exceptions.yml
author: Thomas Patzke, Huntrule Team
date: 2017-08-05
modified: 2020-09-01
tags:
  - attack.initial-access
  - attack.t1190
logsource:
  category: application
  product: django
detection:
  keywords:
    - SuspiciousOperation
    - DisallowedHost
    - DisallowedModelAdminLookup
    - DisallowedModelAdminToField
    - DisallowedRedirect
    - InvalidSessionKey
    - RequestDataTooBig
    - SuspiciousFileOperation
    - SuspiciousMultipartForm
    - SuspiciousSession
    - TooManyFieldsSent
    - PermissionDenied
  condition: keywords
falsepositives:
  - Application bugs
level: medium
license: DRL-1.1
related:
  - id: fd435618-981e-4a7c-81f8-f78ce480d616
    type: derived