- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Environment variables of another user
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
Discussions
Discussions
Forums
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
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-14-2003 11:22 PM
тАО05-14-2003 11:22 PM
Environment variables of another user
Take into account that we don't have the root password, nor the password of the user of which we want to know the variables.
Is this easily to do ??
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-14-2003 11:26 PM
тАО05-14-2003 11:26 PM
Re: Environment variables of another user
let say if u can see it.then it becomes the security risk.
High a potential security threat to the systems.
radhakrishnan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-14-2003 11:29 PM
тАО05-14-2003 11:29 PM
Re: Environment variables of another user
$cat /etc/passwd|grep
$cd
$ls -la .profile .cshrc .login
.profile -->ksh or sh
.login and .cshrc--->csh
If you have read access you can open these files and find out the value for the variables
Revert
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-14-2003 11:33 PM
тАО05-14-2003 11:33 PM
Re: Environment variables of another user
As well answered already these are user specific variables and you can only see them if the user will give them to you.
The user needs to agree and do set or env
to a file and give you file access
To be able to take them would make you very insecure systemwise.
/etc/profile $HOME/.profile and .dtprofile all make a difference plus any env files like
.kshrc
Steve Steel
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-15-2003 03:13 AM
тАО05-15-2003 03:13 AM
Re: Environment variables of another user
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-18-2003 10:43 PM
тАО05-18-2003 10:43 PM
Re: Environment variables of another user
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-18-2003 11:51 PM
тАО05-18-2003 11:51 PM
Re: Environment variables of another user
Indeed .
You need to be able to login as the user or need to have read/execute access to the users .profile and thus to extrapolate the values.
If you have access to any scripts use dby the user you could always put
set > /tmp/$LOGNAME".env"
In it and then wait.
Steve Steel
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-18-2003 11:53 PM
тАО05-18-2003 11:53 PM
Re: Environment variables of another user
even having the root password would only allow seeing how the user's setup is immediately after login. If the user has shell access, he/she can change the environment variables of his/her own shell at any time after login.
As already stated: you have to get the information from the user him/herself.
regards,
John K.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-18-2003 11:57 PM
тАО05-18-2003 11:57 PM
Re: Environment variables of another user
1. global login profiles such as /etc/profile for POSIX shells like /usr/bin/sh, ksh and bash and /etc/csh.login for csh users,
2. local profiles such as .profile and perhaps .kshrc
3. Changes made to the user's local enviroment by sourcing scripts or typing shell commands.
So you can see the environment a specific user might have setup by running the same profiles that the user has. This requires that the user's local profiles are readable by your login.
Other than logging in as the user or using su - user-name to truly login, there is no way to accurately see what a specific users environment might be. Why don't you ask the user to login and print these two commands:
set (all variables)
env (exported variables)
(this assumes the user has a POSIX type shell)
Bill Hassell, sysadmin