This repository was archived by the owner on Apr 25, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 5 files changed +17
-0
lines changed
Expand file tree Collapse file tree 5 files changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -112,6 +112,7 @@ RUN \
112112 -L "http://security.ubuntu.com/ubuntu/pool/universe/libp/libpam4j/libpam4j-java_1.4-2+deb8u1build0.16.04.1_all.deb" && \
113113 dpkg -i /tmp/libpam.deb && \
114114 echo "**** cleanup ****" && \
115+ mv /usr/bin/passwd /usr/bin/passwdbin && \
115116 apt-get autoclean && \
116117 rm -rf \
117118 /var/lib/apt/lists/* \
Original file line number Diff line number Diff line change @@ -112,6 +112,7 @@ RUN \
112112 -L "http://security.ubuntu.com/ubuntu/pool/universe/libp/libpam4j/libpam4j-java_1.4-2+deb8u1build0.16.04.1_all.deb" && \
113113 dpkg -i /tmp/libpam.deb && \
114114 echo "**** cleanup ****" && \
115+ mv /usr/bin/passwd /usr/bin/passwdbin && \
115116 apt-get autoclean && \
116117 rm -rf \
117118 /var/lib/apt/lists/* \
Original file line number Diff line number Diff line change @@ -112,6 +112,7 @@ RUN \
112112 -L "http://security.ubuntu.com/ubuntu/pool/universe/libp/libpam4j/libpam4j-java_1.4-2+deb8u1build0.16.04.1_all.deb" && \
113113 dpkg -i /tmp/libpam.deb && \
114114 echo "**** cleanup ****" && \
115+ mv /usr/bin/passwd /usr/bin/passwdbin && \
115116 apt-get autoclean && \
116117 rm -rf \
117118 /var/lib/apt/lists/* \
Original file line number Diff line number Diff line change 1+ #!/usr/bin/with-contenv bash
2+
3+ if [ -f /config/shadow ] && [ "$(md5sum /config/shadow| cut -c -32)" != "$(md5sum /etc/shadow| cut -c -32)" ]; then
4+ cp /config/shadow /etc/shadow
5+ chown root:shadow /etc/shadow
6+ chmod 640 /etc/shadow
7+ fi
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ /usr/bin/passwdbin " $@ "
3+ sudo cp /etc/shadow /config/shadow
4+ sudo chown ${USER} :${USER} /config/shadow
5+ echo " A wrapper has been executed to save shadow so your password survives upgrades"
6+ echo " If you would like to disable this feature please run:"
7+ echo " sudo mv /usr/bin/passwdbin /usr/bin/passwd"
You can’t perform that action at this time.
0 commit comments