apache / apache/ponymail

Bug: stats.lua - inconsistent use of anchors in match patterns

Open
#116 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
80
Forks
32
PR merge metrics
No merged PRs in 30d

Description

The stats.lua script uses string:match() lots of times when processing query parameters.

In most cases the regex is not anchored, which means that the parameter can contain additional characters. This may cause unexpected behaviour, especially if the parameter is matched more than once with different REs.

Contributor guide

No contributing guide indexed for this repository

Research direction

Read stats.lua and enumerate the string:match calls used for query parameters. Check how each pattern handles the full parameter value, then verify that valid parameters still match while values with additional characters no longer do.

Written by the indexing model from the issue text.

Assessment

Tech stack
lua
Domain
analytics
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.