On Tue, Mar 02, 2010 at 08:47:54PM +0530, Ravindra Patil wrote:
>    just add "."(dot in the path) as follows.
>    export PATH=$PATH:.
>    On Tue, Mar 2, 2010 at 8:38 PM, Echooff3 <[1][email protected]>
>    wrote:
> 
>      Hi,
>      I was just curious, is there any one line trick to add my pwd to my
>      path? Something to the effect of:
>      export PATH=$PATH:<pwd
> 
>      So, if my present working directory was ~/Documents that would get
>      appended to the path.
>      --
>      You received this message because you are subscribed to the Linux Users
>      Group.
>      To post a message, send email to [2][email protected]
>      To unsubscribe, send email to
>      [3][email protected]
>      For more options, visit our group at
>      [4]http://groups.google.com/group/linuxusersgroup
> 
>    --
>    Thanks & Regards,
>    Ravindra M. Patil
> 
>    --
>    You received this message because you are subscribed to the Linux Users
>    Group.
>    To post a message, send email to [email protected]
>    To unsubscribe, send email to [email protected]
>    For more options, visit our group at
>    [5]http://groups.google.com/group/linuxusersgroup
> 
> References
> 
>    Visible links
>    1. mailto:[email protected]
>    2. mailto:[email protected]
>    3. mailto:[email protected]
>    4. http://groups.google.com/group/linuxusersgroup
>    5. http://groups.google.com/group/linuxusersgroup
Just to clarify the two responses - Jerry took you literally and told
you how to add the directory you're in now to the path. Ravindra told
you how to make sure the pwd is always in your path.

Now let me explain why this second one can be dangerous.  Let's say that you
frequently use gpg on the command line, and somebody knows this. Now
let's say that person has regular user access to your system (generally
considered mostly harmless). Now, if you go to /tmp and decide to
encrypt or sign a file there, it would be painfully simple for them to
have placed a 'gpg' standin in /tmp, with world execute. So, while in
tmp you would run *their* gpg instead of the system one.  You are
effectively opening yourself to accidental arbitrary code execution. Now
if their program intercepted your passphrase and sent your private key
off to some nefarious server, they can now sign files as you, and
decrypt documents meant for you.


-- 
You received this message because you are subscribed to the Linux Users Group.
To post a message, send email to [email protected]
To unsubscribe, send email to [email protected]
For more options, visit our group at 
http://groups.google.com/group/linuxusersgroup

Reply via email to