Revisión | 261c58872c1a71f2be2e6ed593e23f08f321a0ff (tree) |
---|---|
Tiempo | 2021-08-24 17:43:11 |
Autor | root <root@loca...> |
Commiter | root |
[BLFS] Modify Linux-PAM.
@@ -44,48 +44,36 @@ Making | ||
44 | 44 | make \ |
45 | 45 | 1> $LOG/$TARGET.2_make.log 2>&1 || exit 1 |
46 | 46 | |
47 | +install -v -m755 -d /etc/pam.d | |
48 | + | |
49 | +cat > /etc/pam.d/other << "EOF" | |
50 | +auth required pam_deny.so | |
51 | +account required pam_deny.so | |
52 | +password required pam_deny.so | |
53 | +session required pam_deny.so | |
54 | +EOF | |
55 | + | |
56 | +rm -fv /etc/pam.d/other | |
57 | + | |
47 | 58 | Installing |
48 | 59 | porg -lp $TARGET -E`pwd` "make install" \ |
49 | 60 | 1> $LOG/$TARGET.3_install.log 2>&1 || exit 1 |
50 | 61 | |
51 | -chmod -v 4755 /sbin/unix_chkpwd \ | |
52 | - 1>> $LOG/$TARGET.3_install.log 2>&1 || exit 1 | |
53 | - | |
54 | -for file in pam pam_misc pamc | |
55 | -do | |
56 | - porg -lp+ $TARGET "\ | |
57 | - mv -v /usr/lib/lib${file}.so.* /lib" \ | |
58 | - 1>> $LOG/$TARGET.3_install.log 2>&1 || exit 1 | |
59 | - | |
60 | - porg -lp+ $TARGET "\ | |
61 | - ln -sfv ../../lib/$(readlink /usr/lib/lib${file}.so) /usr/lib/lib${file}.so" \ | |
62 | - 1>> $LOG/$TARGET.3_install.log 2>&1 || exit 1 | |
63 | -done | |
62 | +chmod -v 4755 /sbin/unix_chkpwd | |
64 | 63 | |
65 | 64 | install -v -m755 -d /etc/pam.d |
66 | 65 | |
67 | -cat > /etc/pam.d/other << "EOF" | |
68 | -# Begin /etc/pam.d/other | |
69 | - | |
70 | -auth required pam_unix.so nullok | |
71 | -account required pam_unix.so | |
72 | -session required pam_unix.so | |
73 | -password required pam_unix.so nullok | |
74 | - | |
75 | -# End /etc/pam.d/other | |
76 | -EOF | |
77 | -porg -lp+ $TARGET "touch /etc/pam.d/other" | |
78 | - | |
79 | 66 | install -vdm755 /etc/pam.d |
80 | - | |
81 | -cat > /etc/pam.d/system-account << "EOF" | |
67 | +cat > /etc/pam.d/system-account << "EOF" && | |
82 | 68 | # Begin /etc/pam.d/system-account |
83 | 69 | |
84 | 70 | account required pam_unix.so |
85 | 71 | |
86 | 72 | # End /etc/pam.d/system-account |
87 | 73 | EOF |
88 | -porg -lp+ $TARGET "touch /etc/pam.d/system-account" | |
74 | +porg -lp+ $TARGET " | |
75 | +touch /etc/pam.d/system-account" \ | |
76 | + 1>> $LOG/$TARGET.3_install.log 2>&1 || exit 1 | |
89 | 77 | |
90 | 78 | cat > /etc/pam.d/system-auth << "EOF" |
91 | 79 | # Begin /etc/pam.d/system-auth |
@@ -93,8 +81,10 @@ cat > /etc/pam.d/system-auth << "EOF" | ||
93 | 81 | auth required pam_unix.so |
94 | 82 | |
95 | 83 | # End /etc/pam.d/system-auth |
96 | -EOF | |
97 | -porg -lp+ $TARGET "touch /etc/pam.d/system-auth" | |
84 | +EOF | |
85 | +porg -lp+ $TARGET " | |
86 | +touch /etc/pam.d/system-auth" \ | |
87 | + 1>> $LOG/$TARGET.3_install.log 2>&1 || exit 1 | |
98 | 88 | |
99 | 89 | cat > /etc/pam.d/system-session << "EOF" |
100 | 90 | # Begin /etc/pam.d/system-session |
@@ -103,7 +93,9 @@ session required pam_unix.so | ||
103 | 93 | |
104 | 94 | # End /etc/pam.d/system-session |
105 | 95 | EOF |
106 | -porg -lp+ $TARGET "touch /etc/pam.d/system-session" | |
96 | +porg -lp+ $TARGET " | |
97 | +touch /etc/pam.d/system-session" \ | |
98 | + 1>> $LOG/$TARGET.3_install.log 2>&1 || exit 1 | |
107 | 99 | |
108 | 100 | cat > /etc/pam.d/system-password << "EOF" |
109 | 101 | # Begin /etc/pam.d/system-password |
@@ -114,7 +106,27 @@ password required pam_unix.so sha512 shadow try_first_pass | ||
114 | 106 | |
115 | 107 | # End /etc/pam.d/system-password |
116 | 108 | EOF |
117 | -porg -lp+ $TARGET "touch /etc/pam.d/system-password" | |
109 | +porg -lp+ $TARGET " | |
110 | +touch /etc/pam.d/system-password" \ | |
111 | + 1>> $LOG/$TARGET.3_install.log 2>&1 || exit 1 | |
112 | + | |
113 | +cat > /etc/pam.d/other << "EOF" | |
114 | +# Begin /etc/pam.d/other | |
115 | + | |
116 | +auth required pam_warn.so | |
117 | +auth required pam_deny.so | |
118 | +account required pam_warn.so | |
119 | +account required pam_deny.so | |
120 | +password required pam_warn.so | |
121 | +password required pam_deny.so | |
122 | +session required pam_warn.so | |
123 | +session required pam_deny.so | |
124 | + | |
125 | +# End /etc/pam.d/other | |
126 | +EOF | |
127 | +porg -lp+ $TARGET " | |
128 | +touch /etc/pam.d/other" \ | |
129 | + 1>> $LOG/$TARGET.3_install.log 2>&1 || exit 1 | |
118 | 130 | |
119 | 131 | TimeEnd |
120 | 132 |