| 1 | .\" -*-nroff-*- |
| 2 | .TH cvssh 1 "21 April 1999" "Local tools" |
| 3 | .SH NAME |
| 4 | cvssh \- quick shell for anonymous CVS servers |
| 5 | .SH SYNOPSIS |
| 6 | .B cvssh |
| 7 | .SH DESCRIPTION |
| 8 | The |
| 9 | .B cvssh |
| 10 | is intended to be used as the login shell of an anonymous CVS server |
| 11 | account. It's not terribly useful in the outside world, because it |
| 12 | requires a patched version of CVS which I haven't released. |
| 13 | .SH ANONYMOUS CVS |
| 14 | Suppose you want to set up a CVS repository in |
| 15 | .B /home/cvs/cvs |
| 16 | with the anonymous user |
| 17 | .BR anoncvs . |
| 18 | The following steps will get this done: |
| 19 | .IP " 1." |
| 20 | Make the directory |
| 21 | .B /home/cvs |
| 22 | owned by |
| 23 | .B root |
| 24 | with mode 755, and execute |
| 25 | .sp 1 |
| 26 | .RS 10 |
| 27 | .nf |
| 28 | .ft B |
| 29 | cvs -d /home/cvs/cvs init |
| 30 | .ft R |
| 31 | .fi |
| 32 | .RE |
| 33 | .IP "" |
| 34 | to create the repository. |
| 35 | .IP " 2." |
| 36 | Add a user |
| 37 | .B anoncvs |
| 38 | with a disabled password, shell set to |
| 39 | .B chrootsh |
| 40 | and home directory set to |
| 41 | .BR /home/cvs/./cvs . |
| 42 | .IP " 3." |
| 43 | As the super-user, run the following commands: |
| 44 | .PP |
| 45 | .RS 10 |
| 46 | .nf |
| 47 | .ft B |
| 48 | # cd /home/cvs |
| 49 | # mkdir -m 711 bin dev etc lib |
| 50 | # mkdir -m 1777 tmp |
| 51 | .ft R |
| 52 | .fi |
| 53 | .RE |
| 54 | .IP "" |
| 55 | You may need some other directories as well. For example, Digital Unix |
| 56 | users will want to make |
| 57 | .B shlib |
| 58 | and |
| 59 | .B sbin |
| 60 | for the shared library system to work properly. |
| 61 | .IP " 4." |
| 62 | Copy the programs |
| 63 | .BR cvs , |
| 64 | .B gzip |
| 65 | and |
| 66 | .B sh |
| 67 | into |
| 68 | .BR /home/cvs/bin . |
| 69 | If your version of |
| 70 | .B /bin/sh |
| 71 | is really the Free Software Foundation's |
| 72 | .B bash |
| 73 | in disguise (e.g., you're a Linux user) then you're probably better off |
| 74 | installing something lighter-weight like the FreeBSD shell (available in |
| 75 | a guise called |
| 76 | .B ash |
| 77 | with Debian GNU/Linux). It's smaller and doesn't need as many shared |
| 78 | libraries. |
| 79 | .IP "" |
| 80 | Also copy in the |
| 81 | .B cvssh |
| 82 | binary. |
| 83 | .IP " 5." |
| 84 | Copy in the shared libraries needed. If you have an |
| 85 | .B ldd |
| 86 | binary handy, run |
| 87 | .sp 1 |
| 88 | .RS 10 |
| 89 | .nf |
| 90 | .ft B |
| 91 | # ldd bin/* |
| 92 | .ft R |
| 93 | .fi |
| 94 | .RE |
| 95 | .IP "" |
| 96 | and copy in what it tells you to. Otherwise you'll have to find things |
| 97 | out the hard way by looking at error messages. Do any other |
| 98 | configuration your shared library system needs or desires here. For |
| 99 | example, Linux users should run |
| 100 | .sp 1 |
| 101 | .RS 10 |
| 102 | .nf |
| 103 | .ft B |
| 104 | # ldconfig -r/home/cvs |
| 105 | .ft R |
| 106 | .fi |
| 107 | .RE |
| 108 | .IP "" |
| 109 | to make a cache file for the shared loader. |
| 110 | .IP " 6." |
| 111 | Make any devices needed in the |
| 112 | .B /dev |
| 113 | directory. For Linux, that probably involves |
| 114 | .sp 1 |
| 115 | .RS 10 |
| 116 | .nf |
| 117 | .ft B |
| 118 | # mknod -m666 dev/null c 1 3 |
| 119 | # mknod -m666 dev/zero c 1 5 |
| 120 | .ft R |
| 121 | .fi |
| 122 | .RE |
| 123 | .IP "" |
| 124 | Other operating systems will, of course, be different. |
| 125 | .IP " 7." |
| 126 | Edit the password and group files the |
| 127 | .B etc |
| 128 | directory. My versions are extremely minimal. The important thing is |
| 129 | that the |
| 130 | .B anoncvs |
| 131 | user should have an entry like the one in the main password database but |
| 132 | with home directory |
| 133 | .B /cvs |
| 134 | and shell |
| 135 | .BR /bin/cvssh . |
| 136 | The |
| 137 | .B passwd |
| 138 | file should contain no passwords or other useful information. Only put |
| 139 | other users in the files if you really feel like it. |
| 140 | .IP " 8." |
| 141 | Finishing touches. Run the command |
| 142 | .sp 1 |
| 143 | .RS 10 |
| 144 | .nf |
| 145 | .ft B |
| 146 | # touch cvs/.hushlogin |
| 147 | .ft R |
| 148 | .fi |
| 149 | .RE |
| 150 | .IP "" |
| 151 | to make sure that logging in doesn't spew junk everywhere. |
| 152 | Also, if you're planning on using SSH, do |
| 153 | .sp 1 |
| 154 | .RS 10 |
| 155 | .nf |
| 156 | .ft B |
| 157 | # mkdir cvs/.ssh |
| 158 | # touch cvs/.ssh/rc |
| 159 | .ft R |
| 160 | .fi |
| 161 | .RE |
| 162 | .IP "" |
| 163 | to make SSH stop trying to play silly games with |
| 164 | .BR xauth . |
| 165 | .IP " 9." |
| 166 | Relax. You're done. |
| 167 | .SH BUGS |
| 168 | None planned. |
| 169 | .SH "SEE ALSO" |
| 170 | .BR chrootsh (8), |
| 171 | .BR cvs (1). |
| 172 | .SH AUTHOR |
| 173 | Mark Wooding (mdw@nsict.org) |