You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 62f6f55
Browse filesBrowse the repository at this point in the historyBrowse files
The check required a separator after "..", so a tag of exactly ".." or
"foo/.." passed and injected a parent directory component into the output
path. Validate ".." as a path component, reject Windows drive
specifications, and always run the parent directory count check after the
substitution.
Signed-off-by: Shizuo Fujita <fujita@clear-code.com>
raiseFluent::UnrecoverableError,"Invalid path component detected, replaced to: #{rvalue}"
886
-
end
887
-
end
895
+
end
896
+
897
+
# Verifies that the number of parent directory traversals (..) has not increased after variable substitution.
898
+
# While each replaced value is validated individually, this step prevents harmless values from concatenating into a dangerous path (e.g., ${tag}${key}/ becoming ../ if both tag and key are .).
0 commit comments