A little history of the problem:
I have built a Perl/TK GUI that I will use to connect to several different sun stations. When I first launch the GUI, I login in with my
user/pass which is the
user/pass I will use to connect to all sun stations. When I click a button, the GUI launches a:
system("xterm -e /PATH/TO/LOGIN_PERL_SCRIPT &");
The
LOGIN_PERL_SCRIPT uses Expect.pm to automatically log me in.
LOGIN_PERL_SCRIPT has the
user/pass because the GUI writes it to a file and then the
LOGIN_PERL_SCRIPT opens the file, gets the
user/pass, and deletes the file. This way no one can do a
ps -ef and grab the
user/pass if I were to use
my ($user,$pass)=@ARGV to get it from command line.
QUESTION:
How, if possible, can I set user/pass as Global Variable that be read by LOGIN_PERL_SCRIPT? Is it possible to write user/pass to a memory location that can be called by other programs, or something along these lines?
Thanks in advanced...
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.