CVSWEBNT - CVSWeb for Apache and Microsoft IIS on Windows
This code is based on the feature-rich cvsweb by Henner Zeller. Modifications for IIS were incorporated by Arthur Barrett. This distribution is based on Henner's cvsweb 1.93. Visit the cvswebnt home to see cvswebnt in action and to check for newer versions.
Alternative - ViewCVS
Machine Requirements when running on IIS
- Windows NT4 SP4 or later, Server or Workstation, with NT4 option pack
- Windows 2000 Server or Professional with IIS 5
Apache Installation
IIS Installation
Note: if you change the SYSTEM path, it will only take effect after a reboot.- Make sure to install a version of CVSNT other than builds 34-39.
- Install IIS (on NT4, via NT Option Pack 4) on the computer that has the raw CVS repository files. This machine is named
tigerin these instructions. You can use network shares, so the files don't necessarily have to reside on the IIS machine, but you will undoubtedly run into file access permissions hell. - These instructions assume that the IIS
wwwrootfolder is located atc:\inetpub\wwwroot. Change these instructions to match the actual path of yourwwwroot. - Copy all executable files from the CVSNT program files directory to a directory in your PATH
- Extract the diff distribution to a directory in your PATH
- If you wish to allow anonymous access,
- Set the LockDir option and give the users
IUSR_andIWAM_"Full control" permissions to the lock folder and its subfolders e.g.,c:\locks - If you don't set a a locks directory, you must give the users
IUSR_andIWAM_"Full control" permissions to all files and folders in the CVS repository - Give the users
IUSR_andIWAM_"Full control" overc:\winnt\tempor where ever the systemTEMPandTMPenvironment variables are pointing - Give the users
IUSR_andIWAM_"execute" permissions tocvs.exeand "read" permissions to the folders that it's contained in - Give the users
IUSR_andIWAM_"execute" permissions to the files you extracted in step 3 (e.g.,rcs.exe) and "read" permissions to the folders that it's contained in - Make sure the users
IUSR_andIWAM_have at least "read" and "list contents" for all files and folders in the CVS repository
- Set the LockDir option and give the users
- Install Active Perl to
c:\perl- For Windows NT, install build 522 (warning: build 616 doesn't work properly on NT)
- For Windows 2000 you may install a later build. For example, build 617 seems to work fine on Windows 2000
- You may install Perl to any folder you like, but you will have to change the paths referenced in these instructions -- you must select "custom install."
- Install the Compress::Zlib
module. This is optional (yet recommended anyway, since it avoids
running an external process) unless you have
gzip.exein your path. If you use ActivePerl, this can be done by insalling "PPM" and running from the command line:
ppm
install Compress::Zlib - Extract all files from the cvsweb distribution to
c:\inetpub\wwwroot\cgi-bin\cvsweb(use folder names!) - Move the the folder
c:\inetpub\wwwroot\cgi-bin\cvsweb\iconstoc:\inetpub\wwwroot\icons - Copy your company logo to
c:\inetpub\wwwroot\icons\apache_pb.gif - Follow
the instructions listed in the cvsweb readme file, which are summarized
as follows. There are more instructions in the readme, these are the
basics:
- Set
%CVSROOTfolders inc:\inetpub\wwwroot\cgi-bin\cvsweb\cvsweb.conf.You must use a local path name, you can't use:cvsnt:or:pserver:or:local:. Use forward slashes instead of backslashes.And also change the next line which specifies the default repository name to use.
%CVSROOT = (
'Development' => 'c:/cvs/na',
'Admin' => 'c:/cvs/admin'
);
- Modify
c:\inetpub\wwwroot\cgi-bin\cvsweb\cvsweb.confand alter the line
#$ENV{'PATH'} = '/usr/local/bin';Remove the leading
#and enter a semicolon-delimited list of folders that containcvs.exeandrcs.exe(use forward slashes instead of backslashes).
$ENV{'PATH'} .= 'c:/cvsbin;c:/rcsbin'; - An alternative to (c) is to add the locations of
cvs.exeandrcs.exeto the SYSTEM path and reboot (you must reboot for this to take effect) - Modify
c:\inetpub\wwwroot\cgi-bin\cvsweb\cvsweb.cgi.Look for the line$config =early on in the file and change it to (use forward slashes instead of backslashes):
$config = $ENV{'CVSWEB_CONFIG'} || 'c:/inetpub/wwwroot/cgi-bin/cvsweb/cvsweb.conf'; - As an alternative to (e), set the
SYSTEMenvironment variableCVSWEB_CONFIGtoc:/inetpub/wwwroot/cgi-bin/cvsweb/cvsweb.conf(use forward slashes!) and reboot (you must reboot for this to take effect)
- Set
- Run Internet Services Manager
- Right-click on Default Web Site and click Properties
- Click "Home Directory"
- Click the Configuration.. button
- Click Add
- Executable:
C:\Perl\bin\perlis.dll - Extension:
cgi - Check "script engine"
- Uncheck "check that file exists"
- Executable:
- In Internet Services Manager, right-click on
cgi-bin/cvsweband select Properties - Under Application Settings, click the Create button
- For "Execute Permissions", choose "Scripts and Executables"
- For "Application Protection", select "Low (IIS Process)"
- If you performed all the steps correctly,
http://tiger/cgi-bin/cvsweb/cvsweb.cgi/should display the root folder of the CVS repository. If you omit the trailing slash you will get a page that says "Moved."
Authenticating Users on IIS
Instead of leaving CVSWeb and ViewCVS wide open to the public, you can have IIS authenticate users. IIS's integration with Windows domain security makes IIS advantageous over Apache. This method can also be used with NTFS permissions to control access to specific modules and folders.- This applies to CVSWeb only. If some users have read-only file access, you must change your CVS setup to specify the LockDir option. For example, if the repository is at
c:/cvs, put the locks inc:/locksand give the usersIUSR_andIWAM_"Full control" over the lock folder e.g.,c:/locks - Give all CVSWeb or ViewCVS users "full" control over
c:\winnt\temp - Run Internet Services Manager
- Navigate to the
cvswebfolder in thecgi-binfolder - Right-click on the
cvsweborviewcvsdirectory - Click properties
- Click the "Directory Security" tab
- In the Anonymous Access box, click edit
- Un-check Anonymous
- Check "Integrated Windows authentication" if your users are connected to the NT domain; otherwise check Basic authentication (you can check both)
- Click OK to close all the open dialog boxes
- If you experience problems, set the Application Protection setting for the
cgi-bin/cvsweborcgi-bin/viewcvsapplication is "Low (IIS Process)." - If you use basic authentication or if you want to protect your CVS files from packet sniffers, you should use
httpsto encrypt data- Run Internet Services Manager
- Right-click on "Default Web Site"
- Choose Properties
- Click the "Directory Security" tab
- Click on the Server Certificate... button
cvsweb can work with multiple repositories as long as the web server machine has access to the raw repository files. Refer to the documentation that ships with cvsweb.
What Does Annotate Do?
The annotate command (also in WinCVS 1.3) displays the selected revision, much like "download" does. Annotate displays the latest version that is responsible for each line. This feature is handy for seeing "who did what" to a particular revision. Click here for an example.
Known Issues
- Annotate doesn't work when option is specified
This is a known issue if you have theLockDiroption specified as part of your CVS repository configuration. This may be fixed in the latest version of cvswebnt.
Troubleshooting (IIS)
- If you experience problems, set the Application Protection setting for the application in
cgi-binto "Low (IIS Process)" Error: Failed to spawn GNU rlog
Change the application protection setting to "Low (IIS Process)" -- see above. After doing this you may still have this problem because, as far I know,rlogdoesn't work with filenames that contain spaces. If this continues to be a problem, copy all of the RCS executables toc:/winnt/system32.- Problems
authenticating users in IIS If "anonymous" is turned off, all users
need permissions to "log on" to the IIS server.
Go to Start/ Programs/ AdministrativeTools/ LocalSecurityPolicy
Open the item:
LocalPolicies/ UserRightsAssignment/ AccessThisComputerFromTheNetwork
Make sure that the checkboxes are filled in both for the 'Local Policy Setting' and 'Effective Policy Setting' for the users and groups that need access to CVSWeb. - When asking for diffs, the message
- No viewable Change -This is the same as"Failed to spawn GNU rlog"(see #1 above)Or, you're attempting to diff a binary file.
- IIS Lockdown Wizard
The page cannot be found
...
HTTP 404 File not found
Change the following line from 0 to 1 in URLSCAN.INI:AllowDotInPath=1 ; if 1, allow dots that are not file extensions
and restart IIS.
浙公网安备 33010602011771号