diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2023-05-01 15:11:08 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2023-05-01 15:11:08 +0300 |
commit | c14adba064aa86114dc43cae657212a4b19d6189 (patch) | |
tree | bf1e9a630b154317aaa7e61e6ba1ee6f7349eca7 /lib/gitlab | |
parent | c6cc9bc94e23e01a01ed191aba993ccf2b443680 (diff) |
Add latest changes from gitlab-org/security/gitlab@15-9-stable-ee
Diffstat (limited to 'lib/gitlab')
-rw-r--r-- | lib/gitlab/checks/branch_check.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/gitlab/checks/branch_check.rb b/lib/gitlab/checks/branch_check.rb index e8f13a92ee7..fa7c4972c91 100644 --- a/lib/gitlab/checks/branch_check.rb +++ b/lib/gitlab/checks/branch_check.rb @@ -42,7 +42,7 @@ module Gitlab def prohibited_branch_checks return if deletion? - if branch_name =~ /\A\h{40}\z/ + if branch_name =~ %r{\A\h{40}(/|\z)} raise GitAccess::ForbiddenError, ERROR_MESSAGES[:prohibited_hex_branch_name] end end |