Commit | Line | Data |
---|---|---|
805e021f CE |
1 | # Copyright 2000, International Business Machines Corporation and others. |
2 | # All Rights Reserved. | |
3 | # | |
4 | # This software has been released under the terms of the IBM Public | |
5 | # License. For details, see the LICENSE file in the top-level source | |
6 | # directory or online at http://www.openafs.org/dl/license10.html | |
7 | ||
8 | # An InstallGuide for the AFS modified Unix commands | |
9 | # | |
10 | ||
11 | sub AIXunix { | |
12 | &Copy("etc/inetd", "/usr/sbin/inetd.afs"); | |
13 | &Copy("etc/ftpd", "/usr/sbin/ftpd.afs"); | |
14 | &Copy("etc/rlogind", "/usr/sbin/rlogind.afs"); | |
15 | &Symlink ("/usr/sbin/inetd.afs", "/etc/inetd.afs"); | |
16 | &Symlink ("/usr/sbin/ftpd.afs", "/etc/ftpd.afs"); | |
17 | &Symlink ("/usr/sbin/rlogind.afs", "/etc/rlogind.afs"); | |
18 | ||
19 | &ErrorsAreFatal(1); | |
20 | &Patch::Verbose if ($InstallVerbose); | |
21 | &CreateDir("/usr/vice/bin"); | |
22 | ||
23 | &Copy("bin/rcp", "/usr/vice/bin"); | |
24 | &Chown (0,2, "/usr/vice/bin/rcp"); | |
25 | &Chmod (04755, "/usr/vice/bin/rcp"); | |
26 | ||
27 | &Copy("bin/rsh", "/usr/vice/bin"); | |
28 | &Chown (0,2, "/usr/vice/bin/rsh"); | |
29 | &Chmod (04755, "/usr/vice/bin/rsh"); | |
30 | ||
31 | # Create the inetd.conf.afs file | |
32 | $InetdConfAfs = "/etc/inetd.conf.afs"; | |
33 | open(INETD, ">$InetdConfAfs") || &ErrorMsg("Can't open file", $InetdConfAfs); | |
34 | print INETD <<"EOINETD"; | |
35 | ftp stream tcp nowait root /etc/ftpd.afs ftpd.afs | |
36 | shell stream tcp nowait root /etc/rshd rshd | |
37 | login stream tcp nowait root /etc/rlogind.afs rlogind.afs | |
38 | ta-rauth stream tcp nowait root internal ta-rauth | |
39 | EOINETD | |
40 | ||
41 | # comment out the rshd line in inetd.conf | |
42 | $InetdConf = "/etc/inetd.conf"; | |
43 | &CopyStat($InetdConf, $InetdConfAfs); | |
44 | &Patch::FileOpen($InetdConf); | |
45 | ||
46 | $Search1 = "^(ftp\\s+.+)"; | |
47 | $Replace1 = '"#".$1'; | |
48 | ||
49 | $Search2 = "^(shell\\s+.+)"; | |
50 | $Replace2 = '"#".$1'; | |
51 | ||
52 | $Search3 = "^(login\\s+.+)"; | |
53 | $Replace3 = '"#".$1'; | |
54 | ||
55 | if (!&Patch::Patch($InetdConf, [[1, "Substitution", $Search1, $Replace1], | |
56 | [1, "Substitution", $Search2, $Replace2], | |
57 | [1, "Substitution", $Search3, $Replace3]])) { | |
58 | &ErrorMsg("Did not succeed with patch", $InetdConf); | |
59 | } | |
60 | ||
61 | # Modify the /etc/services file | |
62 | &ReadInstallGuide("$InstallGuideDir/GENERIC/unix"); | |
63 | &unix; | |
64 | } | |
65 | ||
66 | sub unix { | |
67 | goto &AIXunix; | |
68 | } | |
69 | ||
70 |