X-Git-Url: http://gitweb.hugovil.com/?a=blobdiff_plain;f=stage3%2Fpkg%2Fshadow;h=a73e8a094d78e0d79f820121f68f70b9a9a1e917;hb=e7af14234a490713f91b3efbea721681bd4d0c1b;hp=63850f0d57121026848944f368c2ce0fc61f7b11;hpb=e941771d74ef457edb2c321a76e88a7c9a79c7f8;p=hvlinux.git diff --git a/stage3/pkg/shadow b/stage3/pkg/shadow index 63850f0..a73e8a0 100644 --- a/stage3/pkg/shadow +++ b/stage3/pkg/shadow @@ -13,10 +13,11 @@ hvconfig_pre() sed -i 's/groups$(EXEEXT) //' src/Makefile.in find man -name Makefile.in -exec sed -i 's/groups\.1 / /' {} \; - # Instead of using the default crypt method, use the more secure SHA-512 method - # of password encryption, which also allows passwords longer than 8 characters. - # It is also necessary to change the obsolete /var/spool/mail location for user - # mailboxes that Shadow uses by default to the /var/mail location used currently: + # Instead of using the default crypt method, use the more secure SHA-512 + # method of password encryption, which also allows passwords longer than 8 + # characters. It is also necessary to change the obsolete /var/spool/mail + # location for user mailboxes that Shadow uses by default to the /var/mail + # location used currently: sed -i -e 's@#ENCRYPT_METHOD DES@ENCRYPT_METHOD SHA512@' \ -e 's@/var/spool/mail@/var/mail@' /etc/login.defs } @@ -75,4 +76,13 @@ hvbuild_post() # resources, Linux-PAM uses the pam_limits.so module along with the # /etc/security/limits.conf file. Rename the /etc/limits file: [ -f /etc/limits ] && mv -v /etc/limits{,.NOUSE} + + # Set system group ID range from 1 to 90: + # 0 is reserved for group 'root' + # 99 is reserved for group 'nogroup' + sed -e "s/\(SYS_UID_MIN\s\+\)[0-9]\+/\1 1/" \ + -e "s/\(SYS_UID_MAX\s\+\)[0-9]\+/\1 90/" \ + -e "s/\(SYS_GID_MIN\s\+\)[0-9]\+/\1 1/" \ + -e "s/\(SYS_GID_MAX\s\+\)[0-9]\+/\1 90/" \ + -i /etc/login.defs }