Skip to content

Commit

Permalink
Remove suid bit from Docker image files to mitigate Stack Clash (#56826)
Browse files Browse the repository at this point in the history
  • Loading branch information
mieciu authored and jbudz committed Feb 6, 2020
1 parent 9c46ce8 commit c9b77f2
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,9 @@ function generator({
RUN chmod g+ws /usr/share/kibana && \\
find /usr/share/kibana -gid 0 -and -not -perm /g+w -exec chmod g+w {} \\;
# Remove the suid bit everywhere to mitigate "Stack Clash"
RUN find / -xdev -perm -4000 -exec chmod u-s {} +
# Provide a non-root user to run the process.
RUN groupadd --gid 1000 kibana && \\
useradd --uid 1000 --gid 1000 \\
Expand Down

0 comments on commit c9b77f2

Please sign in to comment.