"enable" command


 
Thread Tools Search this Thread
Top Forums UNIX for Advanced & Expert Users "enable" command
# 1  
Old 07-03-2006
"enable" command

Hi

I'm root on a SCO 5.0.5 Unix system. My printer 'enable' command can only be executed by root. On other versions of Unix I've used, ordinary users can use enable/disable on their own printer requests.

Is there a way of allowing all users to execute 'enable'?

At the moment they get "Insufficient authorization for attempted operation." This response seems to be hard-coded into the enable program file, so it is not a matter of setting permissions. I've tried setting 4755 permission on a shell script to run enable, but it still knows when the user is not root.

Thanks in anticipation
# 2  
Old 07-03-2006
what is the enable command, I havent ever seen it. However is the setuid bit in the permissions of the executable set?
# 3  
Old 07-03-2006
the 'force' method when nothing helps is to wrap this script with another named 'enabled' that is placed earlier in $PATH and executes original with the help of sudo /.../enable

Do not forget to add appropriate entry in /etc/sudoers
# 4  
Old 07-04-2006
Thanks for those replies.

SCO Unix does not have a sudo option. I suspect this is a Linux utility.

The enable command, along with disable, is part of the lp set used to enable and disable printers. It can be used to temporarily hold print jobs, and unlike accept/reject, still allows print jobs to be spooled.

I've tried setting the suid bit and putting the command inside another script with full execute permission, but it appears that the requirement that it is run by root is hard-coded into the executable.

Any other ideas?
# 5  
Old 07-04-2006
The main idea is to run command under root, may be in wrapper script use
Code:
su - -c enable

But how to pass password to the su command?
# 6  
Old 07-04-2006
Haven't used SCO for about 3 years but on OpenServer 5 I did set up a few users with printer admin permissions. There was a character based gui'ish utility for adding and removing users' permissions - called something like scoadmin?
Hope this helps you to find it.
cheers
# 7  
Old 07-04-2006
Ah now then. I've had a prowl through scoadmin, but it doesn't seem to allow me to change privilidges as it is greyed out. But you have pointed me in the direction of "authorisatoins and protected subsystems". Seems there might be something in there that might allow me to give users more access to control of lp functions.
Just got to get my head round the usual obtuse description in the book!

Thanks for your input Steve.
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Bash script - Print an ascii file using specific font "Latin Modern Mono 12" "regular" "9"

Hello. System : opensuse leap 42.3 I have a bash script that build a text file. I would like the last command doing : print_cmd -o page-left=43 -o page-right=22 -o page-top=28 -o page-bottom=43 -o font=LatinModernMono12:regular:9 some_file.txt where : print_cmd ::= some printing... (1 Reply)
Discussion started by: jcdole
1 Replies

2. UNIX for Dummies Questions & Answers

Using "mailx" command to read "to" and "cc" email addreses from input file

How to use "mailx" command to do e-mail reading the input file containing email address, where column 1 has name and column 2 containing “To” e-mail address and column 3 contains “cc” e-mail address to include with same email. Sample input file, email.txt Below is an sample code where... (2 Replies)
Discussion started by: asjaiswal
2 Replies

3. AIX

How to enable "TCP MD5 Signatures" and "https" on AIX?

I have searched many times but nothing found. Somebody help please :(:(:( (1 Reply)
Discussion started by: bobochacha29
1 Replies

4. Solaris

"Enable" command location?

HI- I am troubleshooting a printer problem in Solaris 8. New to this. From the printer server, the printer is accepting requests but it is disabled. I try # enable hpsc211 I get /usr/lib/enable: not found enable is found in /usr/bin not /usr/lib. Why can I not... (2 Replies)
Discussion started by: learnit
2 Replies

5. UNIX for Dummies Questions & Answers

Unix "look" Command "File too large" Error Message

I am trying to find lines in a text file larger than 3 Gb that start with a given string. My command looks like this: $ look "string" "/home/patrick/filename.txt" However, this gives me the following message: "look: /home/patrick/filename.txt: File too large" So, I have two... (14 Replies)
Discussion started by: shishong
14 Replies

6. Shell Programming and Scripting

awk command to replace ";" with "|" and ""|" at diferent places in line of file

Hi, I have line in input file as below: 3G_CENTRAL;INDONESIA_(M)_TELKOMSEL;SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL My expected output for line in the file must be : "1-Radon1-cMOC_deg"|"LDIndex"|"3G_CENTRAL|INDONESIA_(M)_TELKOMSEL"|LAST|"SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL" Can someone... (7 Replies)
Discussion started by: shis100
7 Replies

7. Shell Programming and Scripting

Command Character size limit in the "sh" and "bourne" shell

Hi!!.. I would like to know what is maximum character size for a command in the "sh" or "bourne" shell? Thanks in advance.. Roshan. (1 Reply)
Discussion started by: Roshan1286
1 Replies

8. UNIX for Advanced & Expert Users

Command Character size limit in the "sh" and "bourne" shell

Hi!!.. I would like to know what is maximum character size for a command in the "sh" or "bourne" shell? Thanks in advance.. Roshan. (1 Reply)
Discussion started by: Roshan1286
1 Replies

9. UNIX for Dummies Questions & Answers

Command Character size limit in the "sh" and "bourne" shell

Hi!!.. I would like to know what is maximum character size for a command in the "sh" or "bourne" shell? Thanks in advance.. Roshan. (1 Reply)
Discussion started by: Roshan1286
1 Replies
Login or Register to Ask a Question