Subject: Trouble with regular-expressions for path-filter (linux vs. solar is 2.6)

From: gc_team28 <[email-masked]>
Date: Mon, 26 Jul 1999 18:59:05 +0200

A big hello to everybody!

I've got a problem with some regular expressions in the path-filter - statement.

I want to limit the guests to upload only specific types of files.
I use:

path-filter     guest   /usr/local/etc/msgs/pathmsg ^[-A-Za-z0-9_]*(\.html|\.htm|\.txt|\.gif|\.jpg|\.jpeg|\.tar|\.zip)$ ^\. ^-

with Linux and it works.

Now i've set up wu-ftp on sparc solaris 2.6 and the same statement does not work anymore.
Can anybody help me out? 

CU
André lüpke

---

From: Gregory A Lundberg <[email-masked]>
Date: Mon, 26 Jul 1999 13:37:08 -0400

On Mon, Jul 26, 1999 at 06:59:05PM +0200, gc_team28 wrote:

> I want to limit the guests to upload only specific types of files.  I
> use:
> 
> Now i've set up wu-ftp on sparc solaris 2.6 and the same statement does
> not work anymore.  Can anybody help me out? 

I don't have a Solaris box, but I'd say you're not using a regular
expression library which supports this.  I'd try installing the GNU library
and linking with it.

-- 

Gregory A Lundberg              WU-FTPD Development Group
1441 Elmdale Drive              [email-masked]
Kettering, OH 45409-1615 USA    1-800-809-2195

---

From: Greg Mortensen <[email-masked]>
Date: Mon, 26 Jul 1999 18:58:41 -0400 (EDT)

> expression library which supports this.  I'd try installing the GNU library

If you're using GNU regex v0.12, put regex.h and regex.c in the wu-ftpd
src directory, and apply the attached patch.  You'll also get [:space:]
support, as well.

  Regards,
    Greg

\|/   ___   \|/        [email-masked]        +----- 2048/83C90191 -----+
 @~./'O o`\.~@                                   | 0B 65 E0 58 F3 F9 81 F5 |
/__( \___/ )__\  Crypto, Security, and Phrack:   | F0 72 75 FA 1E BD C9 66 |
   `\__`U_/'       http://world.std.com/~loki    +--- via Finger or WWW ---+
*** extensions.c.orig	Mon Jul 12 12:01:36 1999
--- extensions.c	Mon Jul 12 12:03:09 1999
***************
*** 85,90 ****
--- 85,94 ----
  #include <regex.h>
  #endif
  
+ #ifdef HAVE_GNU_REGEX_H
+ #include "regex.h"
+ #endif
+ 
  #if defined(REGEX) && defined(SVR4) && ! (defined(NO_LIBGEN))
  #include <libgen.h>
  #endif
*** config/config.sol.orig	Mon Jul 12 11:49:55 1999
--- config/config.sol	Mon Jul 12 14:01:11 1999
***************
*** 19,25 ****
  #define HAVE_SYSCONF
  #undef  HAVE_UT_UT_HOST
  #define HAVE_VPRINTF
! #define REGEX
  #define SHADOW_PASSWORD
  #define SOLARIS_2
  #define SVR4
--- 19,27 ----
  #define HAVE_SYSCONF
  #undef  HAVE_UT_UT_HOST
  #define HAVE_VPRINTF
! #undef  REGEX
! #define REGEXEC
! #define HAVE_GNU_REGEX_H
  #define SHADOW_PASSWORD
  #define SOLARIS_2
  #define SVR4
*** makefiles/common.orig	Mon Jul 12 12:05:28 1999
--- makefiles/common	Mon Jul 12 12:06:14 1999
***************
*** 1,10 ****
  
  SRCS   = ftpd.c ftpcmd.c glob.c logwtmp.c popen.c vers.c access.c extensions.c \
           realpath.c acl.c private.c authenticate.c conversions.c hostacc.c \
!          sigfix.c routevector.c restrict.c
  OBJS   = ftpd.o ftpcmd.o glob.o logwtmp.o popen.o vers.o access.o extensions.o \
           realpath.o acl.o private.o authenticate.o conversions.o hostacc.o \
!          sigfix.o routevector.o restrict.o
  
  all: ftpd ftpcount ftpshut ckconfig
  
--- 1,10 ----
  
  SRCS   = ftpd.c ftpcmd.c glob.c logwtmp.c popen.c vers.c access.c extensions.c \
           realpath.c acl.c private.c authenticate.c conversions.c hostacc.c \
!          sigfix.c routevector.c restrict.c regex.c
  OBJS   = ftpd.o ftpcmd.o glob.o logwtmp.o popen.o vers.o access.o extensions.o \
           realpath.o acl.o private.o authenticate.o conversions.o hostacc.o \
!          sigfix.o routevector.o restrict.o regex.o
  
  all: ftpd ftpcount ftpshut ckconfig