"Based on a cursory audit of django, I could not find any condition where the 
user agent would be
returned as anything other than a string."

I confirm this assessment - in examining the code there does not appear
to be any means for user input to trigger the exceptions in is_robot().
The only situation I can envision is if some day the code changes,
either by adding a new assertion/exception in is_robot(), or if
hyperkitty tweaks the useragent input parameter before the call.  It
would be very surprising if either of those things ever came to pass.

However, for sake of defensive programming it probably would hurt little
to paper over this case via a trivial patch such as attached.

** Patch added: "0001-Treat-all-exceptions-from-is_robot-as-a-robot.patch"
   
https://bugs.launchpad.net/ubuntu/+source/robot-detection/+bug/1820225/+attachment/5263492/+files/0001-Treat-all-exceptions-from-is_robot-as-a-robot.patch

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1820225

Title:
  [MIR] robot-detection as dependency of mailman3

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/robot-detection/+bug/1820225/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to