What is /dev/tty /dev/null and /dev/console


 
Thread Tools Search this Thread
Operating Systems Solaris What is /dev/tty /dev/null and /dev/console
# 1  
Old 01-03-2008
What is /dev/tty /dev/null and /dev/console

Hi, Anyone can help

My solaris 8 system has the following

/dev/null , /dev/tty and /dev/console

All permission are lrwxrwxrwx

Can this be change to a non-world write ??

any impact ??
# 2  
Old 01-03-2008
Quote:
Originally Posted by civic2005
My solaris 8 system has the following

/dev/null , /dev/tty and /dev/console
All Unix systems have them.
Quote:
All permission are lrwxrwxrwx
Nope, the initial 'l' tell the remaining permissions are meaningless.
Use "ls -lL" to display the real permissions.
Quote:
Can this be change to a non-world write ??
Yes.
Quote:
any impact ??
I suspect your machine will rapidly crash and probably become unusable unless the O/S fix the broken permission at boot time.
# 3  
Old 01-03-2008
Thank , but what should I reply to my auditors , which they
are asking me to tighten the permission of each (/dev/tty , /dev/null and
/dev/console !!!!
# 4  
Old 01-03-2008
Them them that the files are links and changing permissions will have no effect, the permissions set on the file to which the symlink points control the access rights
# 5  
Old 01-03-2008
Quote:
Originally Posted by reborg
Them them that the files are links and changing permissions will have no effect
Actually not. Changing permissions on a symlink affect the target, not the link, so the chmod would have disastrous effects.
# 6  
Old 01-03-2008
Quote:
Originally Posted by civic2005
but what should I reply to my auditors , which they
are asking me to tighten the permission of each (/dev/tty , /dev/null and
/dev/console !!!!
Tell them that they are mistaken in their audit, and they are mistaken in their understanding of how Unix works. /dev/tty is a different device depending on who the user accessing it is. Read and write permissions to /dev/null pose absolutely no security risk.
/dev/console real permissions are already secure.
# 7  
Old 01-03-2008
Quote:
Originally Posted by jlliagre
Actually not. Changing permissions on a symlink affect the target, not the link, so the chmod would have disastrous effects.
Note, I did not say running chmod on the link, I said chaning the permissions of the link and was speaking hypotetically. Running chmod on the link would as you said change the file, but there would still be no effect on the link itself: it would still be 777. The point being that changing the link is a pointless exercise, the actual target should be modified directly if this is required for some reason, but I cannot see a reason for changing any of the ones suggested.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. HP-UX

Dev/urandom and dev/random missing in HP-UX

Hi, In our HP-UX B.11.11. I could not find dev/urandom and dev/random Are all pseudo-devices implemented as device drivers, or in need to run /configure some package to install the package to have dev/urandom. Please help (4 Replies)
Discussion started by: rashi
4 Replies

2. Red Hat

Changing grub from /dev/sda to /dev/sdb

Hi, Please suggest steps to change grub from /dev/sda to /dev/sdb, (1 Reply)
Discussion started by: manoj.solaris
1 Replies

3. Shell Programming and Scripting

Automating partitioning setup of /dev/sda on /dev/sdc

Objective: To recreate the partitioning setup of /dev/sda on /dev/sdc How would I parse the below information and initialize variables (an array?) that can be used to build sgdisk commands in a script, regardless of the number of partitions? Something along the lines of: sgdisk -n... (12 Replies)
Discussion started by: RogerBaran
12 Replies

4. AIX

Problem in /dev/hd1 and /dev/hd9var

Hello AIXians, I can't boot my AIX, it hangs and stops at the code error: 0518 After searching google, I knew the problem is due to problems in File Systems. So the solution is booting from any bootable media, then run these commands in maintenance mode: #fsck -y /dev/hd4 #fsck -y... (3 Replies)
Discussion started by: Mohannad
3 Replies

5. AIX

Difference between /dev/hdisk and /dev/rhdisk

Hi, How can i check that i am using RAW devices for storage in my AIX machine... Also after adding a LUN from storage to a aix host, when i check /dev in the host, i can see both rhdisk and hdisk with same number eg: dcback1(root):/dev>ls -lrt | grep disk12 crw------- 1 root ... (4 Replies)
Discussion started by: jibujacob
4 Replies

6. Solaris

Lun remove, stuck in /dev/dsk and /dev/rdsk

So, we removed a LUN from the SAN and the system is refusing to remove the references to it in the /dev folder. I've done the following: devfsadm -Cv powermt -q luxadm -e offline <drive path> luxadm probe All those commands failed to remove the path. The drive stills shows up as <drive... (13 Replies)
Discussion started by: DustinT
13 Replies

7. Shell Programming and Scripting

Redirecting standard out to /dev/null goes to file "/dev/null" instead

I apologize if this question has been answered else where or is too elementary. I ran across a KSH script (long unimportant story) that does this: if ; then CAS_SRC_LOG="/var/log/cas_src.log 2>&1" else CAS_SRC_LOG="/dev/null 2>&1" fithen does this: /usr/bin/echo "heartbeat:... (5 Replies)
Discussion started by: jbmorrisonjr
5 Replies

8. UNIX for Dummies Questions & Answers

Reading password from /dev/tty

hi, From the below script: ##########################################pwd_auth.sh######################################################################################## #Author: Pandeeswaran Bhoopathy #Written on:26th Jan 2012 2:00PM #This script describes the feature of stty and illustrates... (3 Replies)
Discussion started by: pandeesh
3 Replies

9. UNIX for Dummies Questions & Answers

/dev/null 2>&1 Versus /dev/null 2>1

How are these two different? They both prevent output and error from being displayed. I don't see the use of the "&" echo "hello" > /dev/null 2>&1 echo "hello" > /dev/null 2>1 (3 Replies)
Discussion started by: glev2005
3 Replies

10. Programming

sniff /dev/tty

hello all, Being root, I would like to log user activity (also multiple root activity), i don't really like history file based logging, lets assume that users have access to their .profile. I would like to write a monitoring daemon in C that would capture /dev/ttys, so I need to do a... (0 Replies)
Discussion started by: wayward
0 Replies
Login or Register to Ask a Question