diff -urN rssh-2.3.2/configure.ac rssh-2.3.2-patched-kdough/configure.ac
--- rssh-2.3.2/configure.ac	2006-01-03 12:27:53.000000000 -0500
+++ rssh-2.3.2-patched-kdough/configure.ac	2006-10-19 14:06:26.000000000 -0400
@@ -169,6 +169,23 @@
 	AC_MSG_WARN([specified rsync binary does not exist])
 fi
 
+# Check for svnserve binary
+
+AC_ARG_WITH(svnserve,
+[  --with-svnserve              specify path to svnserve binary],
+[svnserve_path="$withval"], [svnserve_path=""])
+
+AC_PATH_PROG(svnserve_path, svnserve, [], [])
+if test -z "$svnserve_path"; then
+	AC_MSG_WARN([can't find svnserve - using /usr/bin/svnserve.  Use --with-svnserve to override])
+	svnserve_path=/usr/bin/svnserve
+fi
+
+if ! test -x "$svnserve_path"; then
+	AC_MSG_WARN([specified svnserve binary does not exist])
+fi
+
+
 
 # disable static configuration
 
@@ -200,6 +217,7 @@
 AC_SUBST(cvs_path)
 AC_SUBST(rdist_path)
 AC_SUBST(rsync_path)
+AC_SUBST(svnserve_path)
 AC_SUBST(prefix)
 AC_SUBST(sysconfdir)
 AC_SUBST(libexecdir)
diff -urN rssh-2.3.2/main.c.in rssh-2.3.2-patched-kdough/main.c.in
--- rssh-2.3.2/main.c.in	2006-01-03 12:25:05.000000000 -0500
+++ rssh-2.3.2-patched-kdough/main.c.in	2006-10-19 14:06:26.000000000 -0400
@@ -214,6 +214,8 @@
 			argvec[1] = "4";
 		else if ( !(strcmp(*cmd, PATH_RSYNC)) )
 			argvec[1] = "5";
+		else if ( !(strcmp(*cmd, PATH_SVNSERVE)) )
+			argvec[1] = "6";
 		else {
 			log_set_priority(LOG_ERR);
 			log_msg("fatal error identifying the correct command "
diff -urN rssh-2.3.2/pathnames.h.in rssh-2.3.2-patched-kdough/pathnames.h.in
--- rssh-2.3.2/pathnames.h.in	2003-08-08 17:49:28.000000000 -0400
+++ rssh-2.3.2-patched-kdough/pathnames.h.in	2006-10-19 14:06:26.000000000 -0400
@@ -34,6 +34,7 @@
 #define PATH_SFTP_SERVER	"@sftp_path@"
 #define PATH_SCP		"@scp_path@"
 #define PATH_CVS		"@cvs_path@"
+#define PATH_SVNSERVE		"@svnserve_path@"
 #define PATH_RDIST		"@rdist_path@"
 #define PATH_RSYNC		"@rsync_path@"
 
diff -urN rssh-2.3.2/rssh.1 rssh-2.3.2-patched-kdough/rssh.1
--- rssh-2.3.2/rssh.1	2006-01-03 12:32:01.000000000 -0500
+++ rssh-2.3.2-patched-kdough/rssh.1	2006-10-19 14:06:26.000000000 -0400
@@ -18,7 +18,7 @@
 allowing a user whose shell is configured to
 .B rssh
 to use one or more of the command(s) \fBscp\fP(1), \fBsftp\fP(1)
-\fBcvs\fP(1), \fBrdist\fP(1), and \fBrsync\fP(1), and 
+\fBcvs\fP(1), \fBrdist\fP(1), \fBrsync\fP(1), and \fBsvnserve\fP(8) and 
 .I only
 those commands.  It is intended primarily to work with OpenSSH (see
 http://www.openssh.com), but may work with other implementations.
diff -urN rssh-2.3.2/rssh_chroot_helper.c rssh-2.3.2-patched-kdough/rssh_chroot_helper.c
--- rssh-2.3.2/rssh_chroot_helper.c	2006-01-03 12:36:47.000000000 -0500
+++ rssh-2.3.2-patched-kdough/rssh_chroot_helper.c	2006-10-19 14:06:26.000000000 -0400
@@ -254,6 +254,9 @@
 	case 5:
 		cmd_path = PATH_RSYNC;
 		break;
+	case 6:
+		argv[3] = PATH_SVNSERVE;
+		break;
 	default:
 		log_msg("invalid command specified");
 		exit(2);
diff -urN rssh-2.3.2/rssh.conf.5.in rssh-2.3.2-patched-kdough/rssh.conf.5.in
--- rssh-2.3.2/rssh.conf.5.in	2005-11-28 11:54:56.000000000 -0500
+++ rssh-2.3.2-patched-kdough/rssh.conf.5.in	2006-10-19 14:06:26.000000000 -0400
@@ -50,6 +50,11 @@
 Tells the shell that rsync is allowed.
 .RE
 .P
+.B allowsvnserve
+.RS
+Tells the shell that svnserve is allowed.
+.RE
+.P
 .B umask
 .RS
 Sets the umask value for file creations in the scp/sftp session.  This is
@@ -124,8 +129,8 @@
 .B access bits
 .RS
 Five binary digits, which indicate whether the user is allowed to use rsync,
-rdist, cvs, sftp, and scp, in that order.  One means the command is allowed,
-zero means it is not.
+rdist, cvs, sftp, scp, and svnserve, in that order.  One means the command 
+is allowed, zero means it is not.
 .RE
 .B path
 .RS
diff -urN rssh-2.3.2/rsshconf.c rssh-2.3.2-patched-kdough/rsshconf.c
--- rssh-2.3.2/rsshconf.c	2005-11-27 17:35:43.000000000 -0500
+++ rssh-2.3.2-patched-kdough/rsshconf.c	2006-10-19 14:10:57.000000000 -0400
@@ -71,6 +71,7 @@
 	"allowcvs",
 	"allowrdist",
 	"allowrsync",
+	"allowsvnserve",
 	"chrootpath",
 	"logfacility",
 	"umask",
@@ -94,6 +95,9 @@
 int process_allow_scp( ShellOptions_t *opts, const char *line, 
 		       const int lineno );
 
+int process_allow_svnserve( ShellOptions_t *opts, const char *line, 
+		       const int lineno );
+
 int process_allow_sftp( ShellOptions_t *opts, const char *line, 
 		        const int lineno );
 
@@ -217,21 +221,26 @@
 			return FALSE;
 		return TRUE;
 	case 6:
+		/* allow svnserve */
+		if ( !(process_allow_svnserve(opts, line + pos, lineno) ) )
+			return FALSE;
+		return TRUE;
+	case 7:
 		/* default chroot path */
 		if ( !(process_chroot_path(opts, line + pos, lineno) ) )
 			return FALSE;
 		return TRUE;
-	case 7:
+	case 8:
 		/* syslog log facility */
 		if ( !(process_log_facility(opts, line + pos, lineno) ) )
 			return FALSE;
 		return TRUE;
-	case 8:
+	case 9:
 		/* set the user's umask */
 		if ( !(process_umask(opts, line + pos, lineno) ) )
 			return FALSE;
 		return TRUE;
-	case 9:
+	case 10:
 		/* user */
 		if ( !(process_user(opts, line + pos, lineno) ) )
 			return FALSE;
@@ -553,6 +562,33 @@
 	return TRUE;
 }
 
+/* 
+ * process_allow_svnserve() - make sure there are no tokens after the keyword,
+ *                        other than a possible comment.  If there are
+ *                        additional tokens other than comments, there is a
+ *                        syntax error, and FALSE is returned.  Otherwise, the
+ *                        line is ok, so opts are set to allow svnserve, and TRUE
+ *                        is returned.
+ */
+int process_allow_svnserve( ShellOptions_t *opts, 
+		       const char *line,
+		       const int lineno )
+{
+	int pos;
+
+	if ( !(pos = eat_comment(line)) ){
+		if (log) log_msg("line %d: syntax error parsing config file", 
+				lineno);
+		return FALSE;
+	}
+	if (log){
+		log_set_priority(LOG_INFO);
+		log_msg("allowing svnserve to all users");
+	}
+	opts->shell_flags |= RSSH_ALLOW_SVNSERVE;
+	return TRUE;
+}
+
 
 int process_chroot_path( ShellOptions_t *opts, 
 		         const char *line,
@@ -851,6 +887,7 @@
 	bool	allow_cvs;
 	bool	allow_rdist;
 	bool	allow_rsync;
+	bool	allow_svnserve;
 
 	/* make space for user options */
 	if ( !(temp = (char *)malloc(CFG_LINE_LEN + 1)) ){
@@ -923,7 +960,7 @@
 		return FALSE;
 	}
 	if ( !validate_access(axs, &allow_sftp, &allow_scp, &allow_cvs,
-			      &allow_rdist, &allow_rsync) ){
+			      &allow_rdist, &allow_rsync, &allow_svnserve) ){
 		if (log){
 			log_set_priority(LOG_ERR);
 			log_msg("syntax error parsing access bits, line %d", lineno);
@@ -997,6 +1034,10 @@
 		if (log) log_msg("allowing rsync to user %s", user);
 		opts->shell_flags |= RSSH_ALLOW_RSYNC;
 	}
+	if ( allow_svnserve ){
+		if (log) log_msg("allowing svnserve to user %s", user);
+		opts->shell_flags |= RSSH_ALLOW_SVNSERVE;
+	}
 	if ( path ){
 		if (log) log_msg("chrooting %s to %s", user, path);
 		opts->shell_flags |= RSSH_USE_CHROOT;
diff -urN rssh-2.3.2/rssh.h rssh-2.3.2-patched-kdough/rssh.h
--- rssh-2.3.2/rssh.h	2003-08-08 15:02:02.000000000 -0400
+++ rssh-2.3.2-patched-kdough/rssh.h	2006-10-19 14:06:26.000000000 -0400
@@ -46,6 +46,7 @@
 #define RSSH_ALLOW_CVS   (1 << 2)
 #define RSSH_ALLOW_RDIST (1 << 3)
 #define RSSH_ALLOW_RSYNC (1 << 4)
-#define RSSH_USE_CHROOT	 (1 << 5)
+#define RSSH_ALLOW_SVNSERVE (1 << 5)
+#define RSSH_USE_CHROOT	 (1 << 6)
 
 #endif /* _rssh_h */
diff -urN rssh-2.3.2/util.c rssh-2.3.2-patched-kdough/util.c
--- rssh-2.3.2/util.c	2006-01-03 12:37:39.000000000 -0500
+++ rssh-2.3.2-patched-kdough/util.c	2006-10-19 14:06:26.000000000 -0400
@@ -79,6 +79,7 @@
 	if ( flags & RSSH_ALLOW_SFTP ) size += 5;
 	if ( flags & RSSH_ALLOW_CVS ) size += 4;
 	if ( flags & RSSH_ALLOW_RDIST ) size += 6;
+	if ( flags & RSSH_ALLOW_SVNSERVE ) size += 10; 
 	if ( flags & RSSH_ALLOW_RSYNC ) size += 5; /* last one, no space */
 
 	/* create msg indicating what is allowed */
@@ -101,6 +102,8 @@
 			strncat(cmd, "rdist ", size);
 		if ( flags & RSSH_ALLOW_RSYNC )
 			strncat(cmd, "rsync", size);
+		if ( flags & RSSH_ALLOW_SVNSERVE )
+			strncat(cmd, "svnserve", size);
 	}
 
 	/* print error message to user and log attempt */
@@ -245,6 +248,9 @@
 		return PATH_RSYNC;
 	}
 
+	if ( check_command(cl, opts, PATH_SVNSERVE, RSSH_ALLOW_SVNSERVE) )
+		return PATH_SVNSERVE;
+
 	return NULL;
 }
 
@@ -309,11 +315,11 @@
  *                     same name, and returns FALSE if the bits are not valid
  */
 int validate_access( const char *temp, bool *allow_sftp, bool *allow_scp,
-	       	     bool *allow_cvs, bool *allow_rdist, bool *allow_rsync )
+	       	     bool *allow_cvs, bool *allow_rdist, bool *allow_rsync, bool *allow_svnserve )
 {
 	int	i;
 
-#define NUM_ACCESS_BITS 5
+#define NUM_ACCESS_BITS 6
 
 	if ( strlen(temp) != NUM_ACCESS_BITS ) return FALSE;
 	/* make sure the bits are valid */
@@ -325,6 +331,7 @@
 	*allow_cvs   = temp[2] - '0';
 	*allow_sftp  = temp[3] - '0';
 	*allow_scp   = temp[4] - '0';
+	*allow_svnserve = temp[5] - '0';
 	return TRUE;
 }
 
diff -urN rssh-2.3.2/util.h rssh-2.3.2-patched-kdough/util.h
--- rssh-2.3.2/util.h	2006-01-03 12:37:55.000000000 -0500
+++ rssh-2.3.2-patched-kdough/util.h	2006-10-19 14:06:26.000000000 -0400
@@ -37,7 +37,7 @@
 char *extract_root( char *root, char *path );
 int  validate_umask( const char *temp, int *mask );
 int validate_access( const char *temp, bool *allow_sftp, bool *allow_scp,
-	       	     bool *allow_cvs, bool *allow_rdist, bool *allow_rsync );
+	       	     bool *allow_cvs, bool *allow_rdist, bool *allow_rsync, bool *allow_svnserve );
 bool opt_exist( char *cl, char opt );
 char *get_username( void );
 
