Prevent history entry


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers Prevent history entry
# 1  
Old 12-30-2004
Prevent history entry

Is there anyway to prevent a command from being logged in the history file?

I share a system with others (log in with same account) and I would like to prevent any passwords from being logged in the history file. Some of the commands that I run require username/password on the command line during execution.

Thanks.
# 2  
Old 12-30-2004
Quote:
Is there anyway to prevent a command from being logged in the history file?
export HISTSIZE=0

Quote:
I would like to prevent any passwords from being logged in the history file.
Passwords are NOT logged in to the history file.
# 3  
Old 12-30-2004
That didn't seem to work.

I'm actually concerned about a password I need to supply for the command execution of a file.

ie. filename user1/password
# 4  
Old 12-30-2004
Is yr history file not having "read" permission to you only.

If it is setup that way ... except 'root' nobody can read
that file and noway to find passwds of yr history.


Try change to 400 permissions to history file if it has not been done. yet
# 5  
Old 12-30-2004
I think his point is that multiple people use the same login ID, and therefore can access the history of that ID. I'm not sure how to prevent writing to history.

You also have another problem on your hands -- anyone can just get your username/password from a process grep. Many programs have a way of getting around that problem, like sqlplus.
# 6  
Old 12-30-2004
That's correct. The account is shared and my hopes are to preclude the writing of the command to the history file.

I'm aware of the process grep and can accomodate for that.
# 7  
Old 12-30-2004
The bourne shell does not have history. So run a bourne shell, type your command, then exit the bourne shell.
 
Login or Register to Ask a Question

Previous Thread | Next Thread

8 More Discussions You Might Find Interesting

1. What is on Your Mind?

The Great History of UNIX (1969-1999) | 30 Years of UNIX History | YouTube Video

I am pleased to announce this new video in 1080 HD for UNIX lovers honoring thirty years of UNIX history spanning from 1969 to 1999 presented in 150 seconds (two and a half minutes) in 1080 HD, celebrating the 50th anniversary of UNIX. The Great History of UNIX (1969-1999) | 30 Years of UNIX... (8 Replies)
Discussion started by: Neo
8 Replies

2. Shell Programming and Scripting

How to replace multiple "&nbsp;" entry with in <td> tag into single entry using sed?

I have the input file like this. Input file: 12.txt 1) There are one or more than one <tr> tags in same line. 2) Some tr tags may have one <td> or more tna one <td> tags within it. 3) Few <td> tags having "<td> &nbsp; </td>". Few having more than one "&nbsp;" entry in it. <tr> some td... (4 Replies)
Discussion started by: thomasraj87
4 Replies

3. How to Post in the The UNIX and Linux Forums

Help me, write a bash script to delete parent entry with all their child entry in LDAP UNIX server

Hi All, Please help me and guide me to write a bash/shell script on Linux box to delete parent entry with all their child entries. example: Parent is : ---------- dn: email=yogesh.kumar@wipro.com, o=wipro, o=in child is: ---------- dn: cn: yogesh kumar, email=yogesh.kumar@wipro.com,... (1 Reply)
Discussion started by: Chand
1 Replies

4. UNIX for Advanced & Expert Users

How to prevent Accidents 'rm -rf *'?

When invoking unix commands from other third party tools (IBM ETL), we run the rm / mv commands with the folder as argument been passed. Eg rm -rf {folder}/* when the parameter {folder} did not pass rightly or becomes blank, the command becomes dangerous to execute rm -rf /* How to prevent... (9 Replies)
Discussion started by: deepakwins
9 Replies

5. UNIX for Dummies Questions & Answers

History to Another file [local user history , but root access]

Hi all, My need is : 1. To know who , when , which command used. 2. Local user should not delete this information. I mean , with an example , i can say i have a user user1 i need to give all the following permissions to user1, : a. A specific directory other than his home... (1 Reply)
Discussion started by: sriky86
1 Replies

6. UNIX for Advanced & Expert Users

History to Another file [local user history , but root access]

Hi all, My need is : 1. To know who , when , which command used. 2. Local user should not delete this information. I mean , with an example , i can say i have a user user1 i need to give all the following permissions to user1, : a. A specific directory other than his home... (3 Replies)
Discussion started by: linuxadmin
3 Replies

7. UNIX for Dummies Questions & Answers

How to review the history and the commands that has been done in this history?

Hello every body, Kindly inform me How Do i find out the time I executed a command previously on UNIX Solaris?? To be more specific and more clear about what i want to know is that I want a command the enables me to know the history and which command i run at this history/time. FYI I used... (5 Replies)
Discussion started by: ahmedamer12
5 Replies

8. Programming

how to prevent deadlock on this...

I am using linux termios structure to configure serial port and read the port by read function. For some reason, if I read the whole buffer, almost every time the buffer does not contain the correct reply message sequence from a device sending reply to my linux PC. So I use... (5 Replies)
Discussion started by: yimab
5 Replies
Login or Register to Ask a Question