Skip to content

Commit a4005de

Browse files
SalmanDeveloperzshaheemazmalmmd
authored andcommitted
fix: exclude invalid characters from URL regex in copyright agent, Fixes fossology#317
Signed-off-by: Muhammad Salman <chsalmanramzan422@gmail.com>
1 parent 792818e commit a4005de

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/copyright/agent/copyright.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
# SPDX-License-Identifier: FSFAP
66
#
77
# Description: this file holds the regex configurations for the Copyright agent
8-
url=(?:(:?ht|f)tps?\:\/\/[^\s\<]+[^\<\.\,\s])
8+
url=(?:(?:ht|f)tps?://[^\s<>\"'`\[\]{}\\|\^]+?)(?=[\s<>\"'`\[\]{}\\]|$)
99
EMAILPART=[\w\-\.\+]{1,100}
1010
TLD=[a-zA-Z]{2,12}(?<!test)(?<!invalid)
1111
email=[\<\(]?(__EMAILPART__@__EMAILPART__\.__TLD__)(?<!example\.(com|net|org))[\>\)]?

0 commit comments

Comments
 (0)