Bug 76483 - lpoptions does no input validation on option values
lpoptions does no input validation on option values
Status: CLOSED WONTFIX
Product: Red Hat Linux
Classification: Retired
Component: cups (Show other bugs)
8.0
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Tim Waugh
: FutureFeature
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2002-10-22 06:03 EDT by Robert P. J. Day
Modified: 2008-05-01 11:38 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2002-10-22 06:04:05 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Robert P. J. Day 2002-10-22 06:03:58 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.0.1) Gecko/20020830

Description of problem:
  the "lpoptions" command does not appear to do any input
validation on option values, allowing the user to set
meaningless option values, such as:

  $ lpoptions -o scaling=fred
  $ lpoptions -o number-up=barney

these values are faithfully stored in the user's
~/.lpoptions file.  while there may be some value in
allowing the definition of completely arbitrary options
and their values, the online docs explicitly talk about
acceptable values for the predefined options, such as 
that "CUPS supports 1, 2, 4, 6, 9, and 16-Up formats;
the default format is 1-Up."

  if there is a restricted set of possible values, then
input validation should be done and error messages should
be generated.



Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1.lpoptions -o scaling=fred
2.
3.
	

Actual Results:  it took it and did not complain

Expected Results:    input validation should reject an unacceptable value for
a predefined CUPS option

Additional info:
Comment 1 Tim Waugh 2002-10-22 06:07:24 EDT
This is by design (source: cups mailing list).

Note You need to log in before you can comment on or make changes to this bug.