[OpenSIPS-Devel] [OpenSIPS/opensips] a8dd90: fraud_detection: Fix a bug causing negative CC/CPM

Liviu Chircu noreply at github.com
Tue Aug 18 06:49:43 EST 2020


  Branch: refs/heads/2.4
  Home:   https://github.com/OpenSIPS/opensips
  Commit: a8dd905885e6da3bfc7a6520506004b491232e2c
      https://github.com/OpenSIPS/opensips/commit/a8dd905885e6da3bfc7a6520506004b491232e2c
  Author: Liviu Chircu <liviu at opensips.org>
  Date:   2020-08-18 (Tue, 18 Aug 2020)

  Changed paths:
    M modules/fraud_detection/fraud_detection.c
    M modules/fraud_detection/frd_events.c
    M modules/fraud_detection/frd_events.h
    M modules/fraud_detection/frd_stats.c
    M modules/fraud_detection/frd_stats.h

  Log Message:
  -----------
  fraud_detection: Fix a bug causing negative CC/CPM

Following a reset of the statistics for a (user, dialed_number) pair,
skip any pending subtraction operations scheduled during a previous
interval (e.g. a dialog which started during fraud detection interval A
and ended in interval B should not decrement CC anymore if it has
already been reset to 0 in the meantime during a more recent
check_fraud() call).

Many thanks to Inderjeet Sharma (@inderjeetsharma) for reporting and
helping track down this bug.

Fixes #2079

(cherry picked from commit 4f414366ee0fcc52fa2d18c59be0c5d753047934)





More information about the Devel mailing list