Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2023-12-13 02:03:36 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2023-12-13 02:03:36 +0300
commitcffe7caa43575aead057d8779827bada786f84b6 (patch)
tree0782bf1cd66a7753caabafb10ab3feb15a5c1d2f /lib/gitlab/checks
parent734bfe3a2e8b86c3e049f6f13d380b3d30e4e359 (diff)
Add latest changes from gitlab-org/security/gitlab@16-6-stable-ee
Diffstat (limited to 'lib/gitlab/checks')
-rw-r--r--lib/gitlab/checks/tag_check.rb10
1 files changed, 0 insertions, 10 deletions
diff --git a/lib/gitlab/checks/tag_check.rb b/lib/gitlab/checks/tag_check.rb
index cdc648bf005..d5addab74b8 100644
--- a/lib/gitlab/checks/tag_check.rb
+++ b/lib/gitlab/checks/tag_check.rb
@@ -12,7 +12,6 @@ module Gitlab
create_protected_tag: 'You are not allowed to create this tag as it is protected.',
default_branch_collision: 'You cannot use default branch name to create a tag',
prohibited_tag_name: 'You cannot create a tag with a prohibited pattern.',
- prohibited_sha_tag_name: 'You cannot create a tag with a SHA-1 or SHA-256 tag name.',
prohibited_tag_name_encoding: 'Tag names must be valid when converted to UTF-8 encoding'
}.freeze
@@ -22,8 +21,6 @@ module Gitlab
protected_tag_checks: "Checking if you are creating, updating or deleting a protected tag..."
}.freeze
- STARTS_WITH_SHA_REGEX = %r{\A#{Gitlab::Git::Commit::RAW_FULL_SHA_PATTERN}}o
-
def validate!
return unless tag_name
@@ -60,7 +57,6 @@ module Gitlab
end
# rubocop: enable Style/SoleNestedConditional
# rubocop: enable Style/GuardClause
- validate_tag_name_not_sha_like!
end
def protected_tag_checks
@@ -92,12 +88,6 @@ module Gitlab
end
end
end
-
- def validate_tag_name_not_sha_like!
- return unless STARTS_WITH_SHA_REGEX.match?(tag_name)
-
- raise GitAccess::ForbiddenError, ERROR_MESSAGES[:prohibited_sha_tag_name]
- end
end
end
end