- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- modem device file permission change
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-21-2009 03:57 AM
05-21-2009 03:57 AM
ls -l /dev/tty2a7
crw--w--w- 1 bin bin 44 0x020600 May 20 11:30 /dev/tty2a7
It is default permission i have change it to 777.Now i want to set it permanantly.Is this possible????Is this secure???/
Regards
Sunny
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-21-2009 04:17 AM
05-21-2009 04:17 AM
Re: modem device file permission change
Yes its possible to change the permission see the output below
mknod [OPTION]... NAME TYPE [MAJOR MINOR]
[root@rspc521 tmp]# mknod /tmp/abc c 44 0x020600
[root@rspc521 tmp]# ll abc
crw-r--r-- 1 root root 46, 0 May 21 17:50 abc
[root@rspc521 tmp]# chmod 622 abc
[root@rspc521 tmp]# ll abc
crw--w--w- 1 root root 46, 0 May 21 17:50 abc
Suraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-21-2009 04:25 AM
05-21-2009 04:25 AM
Re: modem device file permission change
Regards
Sunny
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-21-2009 04:54 AM
05-21-2009 04:54 AM
SolutionSetting it to 666 makes a bit more sense, but may be bad security: it allows everyone to access the modem, AND it allows everyone to eavesdrop on or terminate everyone else's connections.
The optimal setup is a bit more complicated:
(Note: if you are going to use UUCP, don't do this. UUCP was an old system of automating the transfer of email and files when using only modem connections. Today UUCP is very rarely used, but HP-UX still has the facilites for it included in the standard installation. If you are going to use it, read the man pages of the UUCP programs to find the instructions for the proper modem setup for UUCP. I'm assuming you don't need UUCP.)
You should create a new group (e.g. "groupadd modem"), then make the modem accessible by this group only:
chgrp modem /dev/tty2a7
chmod 660 /dev/tty2a7 # permissions crw-rw----
Then make a list of the programs your users are supposed to use with the modem, and add setgid modem permissions to these programs:
chgrp modem /some/application/somewhere
chmod g+s /some/application/somewhere
This special permission setting makes the user running the application become a member of the modem group *only when running this application*.
You should also change the group of the /var/spool/locks directory:
chgrp modem /var/spool/locks
The /var/spool/locks directory should be group writeable by default.
Many modem-using applications can create UUCP-style lock files when properly configured: in this case, the application should create a file named /var/spool/locks/LCK..tty2a7 when starting to use the modem, and delete it when done. The file should contain the PID number of the application process.
If the application detects this file already exists when the application is starting, it can verify that the PID listed in the lock file really exists. If it does, the application can display a message "the modem is in use by someone else" and either exit or wait for the modem to become free.
If the lock file exists but the PID number listed in it does not match any running process, the application that was using the modem before has apparently crashed. In this case (only) the new application can overwrite the lock file and start using the modem. Usually the application should notify the user in this situation. The typical message is something like "Stale lock file detected and removed."
MK
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-21-2009 05:27 AM
05-21-2009 05:27 AM
Re: modem device file permission change
Regards
Sunny
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2009 05:13 AM
05-22-2009 05:13 AM
Re: modem device file permission change
Unix operates with beer.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2009 06:34 AM
05-22-2009 06:34 AM
Re: modem device file permission change
Regards
Sunny