URI::InvalidURIError on untrimmed webhooks

Hi

After upgrading to 8.4 yesterday I've discovered warnings in sidekiq.log complaining about

  • "URI::InvalidURIError: bad URI(is not URI?): https://hooks.slack.com/services/..."
  • and "/usr/lib/ruby/2.3.0/uri/rfc3986_parser.rb:67:in `split'"

Turns out that a webhook URL in a project's service (Slack) had surrounding white-spaces which caused the URI parser to choke on the input.

Please sanitise input fields such as "Project Services" webhooks if the underlying library has specific pre-conditions, syntax requirements. In this particular case please trim white spaces of URI fields

  • on updates to the service configuration
  • on migrations, GitLab upgrades for all configured project services.

Best

Edited Nov 24, 2022 by 🤖 GitLab Bot 🤖
Assignee Loading
Time tracking Loading