On 5/28/21 12:06 PM, Henrik K wrote: > On Fri, May 28, 2021 at 09:52:25AM +0300, Henrik K wrote: >> >> The current (legacy) way that DecodeShortURLs works need to be changed. >> Calling got_hit() for random rules that are not defined, especially things >> like SHORT_C<SHORTENER>_C<CODE> should not be used. One can't score them >> properly and it also breaks the upcoming meta-rule logic. All of the checks >> need to have dedicated eval: rules. > > Also I'm not sure what's the point of these rules > > SHORT_URL_200 > SHORT_URL_404 > > If there's multiple shorteners in a message, you might get both results or > maybe even neither. > > Also at a quick glance, those cannot even hit if result is cached, since the > cache doesn't store return codes. cache must be invalidated every day with sql queries, to detect if a return code has changed for a cached url, we should run a head request so cache will be of no use.
> And stuff like $self->{short_url_chained} > isn't even reset, so it might keep hitting in new messages. This module > needs a lot of extra love. > I will take a look to improve it. Giovanni
OpenPGP_signature
Description: OpenPGP digital signature