Skip to content

Commit 9a5436c

Browse files
authored
Merge pull request #6635 from psiinon/pscan/del-old-stats
pscan: Remove the name based stats
2 parents 86a1d8d + 97a1679 commit 9a5436c

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

addOns/pscan/CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
88
### Added
99
- Allow to configure the option max body size through the API (Issue 8974).
1010

11+
### Changed
12+
- To only record `stats.pscan.<rule-name>` statistics for scanners that have no IDs.
13+
1114
## [0.3.0] - 2025-06-20
1215
### Changed
1316
- Adjusted further dialog, progress, and log messages with regard to preventing inclusion of commas in scan rule ID numbers. As well as ensuring consistency in use of ID (full caps) for table column headings.

addOns/pscan/src/main/java/org/zaproxy/addon/pscan/internal/scanner/PassiveScanTask.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -166,9 +166,9 @@ public void run() {
166166
PluginPassiveScanner pps = (PluginPassiveScanner) scanner;
167167
Stats.incCounter(
168168
"stats.pscan." + pps.getPluginId() + ".time", timeTaken);
169+
} else {
170+
Stats.incCounter("stats.pscan." + scanner.getName(), timeTaken);
169171
}
170-
// TODO remove at some point
171-
Stats.incCounter("stats.pscan." + scanner.getName(), timeTaken);
172172
if (timeTaken > 5000) {
173173
// Took over 5 seconds, thats not ideal
174174
String responseInfo = "";

0 commit comments

Comments
 (0)