mozilla / sumo

Project management board for SUMO and Community properties.
Mozilla Public License 2.0
14 stars 5 forks source link

Tag slugs can be forced to uppercase and made similar to existing ones #2040

Closed emilghittasv closed 1 week ago

emilghittasv commented 2 weeks ago

Preconditions Sign in to SUMO with an account that has admin permissions.

Steps to reproduce Steps to reproduce the behavior:

  1. Go to /admin/taggit/tag/add/
  2. Add a tag which is similar to an existing one but force the slug to be in uppercase. Example create a test topic with slug Test (there is an existing test topic with slug test
  3. Access a random forum question and try adding the test topic,

Expected behavior Uppercase slugs similar to existing slugs cannot be added.

Actual behavior Uppercase slugs which are similar to existing ones can be added via admin and trying to apply them to questions returns Tag.MultipleObjectsReturned https://mozilla.sentry.io/issues/6047040063/?project=4504326797197312&query=is%3Aunresolved%20issue.priority%3A%5Bhigh%2C%20medium%5D&referrer=issue-stream&statsPeriod=24h&stream_index=0

Screencasts duplicateTags

akatsoulas commented 1 week ago

Only a very small group of people have access to the admin interface so the risk is small here. Moreover since this is the admin interface I would be hesitant on adding logic that will limit the ability to add any entry here even if it's a duplicate in upper and lower case.