Subject: kern/20112: MAXINTERP set far too low for modern scripts
To: None <gnats-bugs@gnats.netbsd.org>
From: None <tv@pobox.com>
List: netbsd-bugs
Date: 01/29/2003 15:30:36
>Number:         20112
>Category:       kern
>Synopsis:       MAXINTERP set far too low for modern scripts
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Wed Jan 29 12:32:00 PST 2003
>Closed-Date:
>Last-Modified:
>Originator:     Todd Vierling
>Release:        NetBSD 1.6_STABLE
>Organization:
	DUH.ORG:  Pointing out the obvious since 1994.

>Environment:
na

>Description:

#define MAXINTERP       64              /* max interpreter file name length */

The above is in <sys/param.h>.  It makes many modern scripts for
commercial packages (typically for binary emulation), which want
to do things like

#!/path/to/customized/perl/interpreter -I/path/to/custom/libs -I/path/to/more/libs

bomb.  This number really needs to be kicked up to at least 100 or so.
Or, better yet, kern_subr.c could check that the *interpreter path* is
the length actually checked, and leave its arguments out of the length
check.  Even so, interpreter pathnames may still be longer than 64....

>How-To-Repeat:

grep MAXINTERP /usr/include/sys/param.h

>Fix:

Increase the number for MAXINTERP.
>Release-Note:
>Audit-Trail:
>Unformatted: