The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Operating Systems > SUN Solaris
.
google unix.com



SUN Solaris The Solaris Operating System, usually known simply as Solaris, is a free Unix-based operating system introduced by Sun Microsystems .

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
how to get passwd command again if it is deleted by usin rm command venkata.ganesh Linux 5 02-13-2009 11:56 AM
Passwd in the line command sandba Shell Programming and Scripting 1 08-22-2006 11:33 AM
How do I parse passwords into passwd command. gilberteu Shell Programming and Scripting 0 03-28-2006 11:26 AM
passwd command not working rahulrathod UNIX for Dummies Questions & Answers 5 12-09-2004 03:46 PM
comparable command in OpenBSD for linux's "passwd -l (name)" xyyz BSD 1 09-11-2003 07:08 PM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 06-18-2007
shahnazurs shahnazurs is offline
Registered User
  
 

Join Date: Jul 2005
Posts: 59
passwd command search

Hi.

When i execute
which passwdit is showing /usr/bin/passwd, eventhough i set my path as

PATH=/etc:$PATH

i just checked the permission for the passwd under /usr/bin

-r-sr-sr-x

what exactly happening? and what is that s signifies

Thanks.
  #2 (permalink)  
Old 06-18-2007
sysgate's Avatar
sysgate sysgate is offline Forum Advisor  
Unix based
  
 

Join Date: Nov 2006
Location: Bulgaria
Posts: 1,318
are you root ot normal user ? are you sure that you set the $PATH in correct file ? /etc/bashrc or your home folder ?
Quote:
export PATH=$PATH:/etc:$PATH
or
Quote:
For tcsh or csh:
set PATH = ($PATH /usr/sbin /usr/local/bin)
  #3 (permalink)  
Old 06-18-2007
shahnazurs shahnazurs is offline
Registered User
  
 

Join Date: Jul 2005
Posts: 59
Thanks for reply, i am a normal user and my shell in korn shell. I am working under SunOs5.9

Thanks.
  #4 (permalink)  
Old 06-18-2007
ennstate ennstate is offline
Registered User
  
 

Join Date: Mar 2007
Location: Chennai
Posts: 222
Hi,
Code:
$ ls -l /etc/passwd
-rw-r--r--    1 root     root         1395 Jun  9 20:15 /etc/passwd
Here /etc/passwd is a file which has read-write access only root user.This file contains the encrypted password details.
Code:
$ ls -l /usr/bin/passwd
-r-s--x--x    1 root     root        16336 Feb 14  2003 /usr/bin/passwd
The /usr/bin/passwd is the set-uid program,which enable normal users to accomplish tasks which would otherwise require privileged access.Whenever this program is run it will run with root user privilege.

Thus the passwd program allows normal users to change password,which requires ability to write to /etc/passwd file.


Thanks
Nagarajan Ganesan.
  #5 (permalink)  
Old 06-19-2007
shahnazurs shahnazurs is offline
Registered User
  
 

Join Date: Jul 2005
Posts: 59
Thanks Nagaraj for your explanation

is there any situation we need to go for set uid? then what is the purpose of set gid?
clear me with some more examples

Thanks.
  #6 (permalink)  
Old 06-19-2007
ennstate ennstate is offline
Registered User
  
 

Join Date: Mar 2007
Location: Chennai
Posts: 222
Please see the thread,

Unix File Permissions
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 12:14 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0