how safe are environment variables?

P

perl coder

Is it possible for a (non-admin) user to somehow retrieve the
environment variables of a running process? (either a service or a
program in use by another user).

I'm mainly concerned about passwords.
 
S

Shenan Stanley

perl said:
Is it possible for a (non-admin) user to somehow retrieve the
environment variables of a running process? (either a service or a
program in use by another user).

I'm mainly concerned about passwords.

Of a running process or global variables?

Environment variables are not inherently safe.
 
P

Pegasus \(MVP\)

Each process inherits the environmental variables of the
parent that launches it. It then creates its own local
environmental variables. They are invisible to any other
process (unless you manage to write a program that
manages to access the memory space used by another
application). When a process terminates, its environmental
variables die.

You can easily demonstrate this by launching a number
of Command Processors and setting some variables.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top