Linux - SecurityThis forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Hi, when I leave and come back to my computer, I findthat bash has closed. The first few times I thought I just closed it, but today when I went to my internship, I purposely left it open, and the top window, and when I came back, guess what, it was closed.
What in the world is going on here? Is it a hacker, or is there something wrong with bash? Only bash closes, no other windows close. This is really starting to concern me.
GNU bash, version 3.1.17(2)-release (i586-mandriva-linux-gnu)
Copyright (C) 2005 Free Software Foundation, Inc.
Distribution: Fedora x86 and x86_64, Debian PPC and ARM, Android
Posts: 4,500
Rep:
Your TMOUT environment variable is probably set to a non-zero value. To check,
echo $TMOUT
From the bash man page:
Quote:
TMOUT If set to a value greater than zero, TMOUT is treated as the
default timeout for the read builtin. The select command termi-
nates if input does not arrive after TMOUT seconds when input is
coming from a terminal. In an interactive shell, the value is
interpreted as the number of seconds to wait for input after
issuing the primary prompt. Bash terminates after waiting for
that number of seconds if input does not arrive.
It is probably set in your ~/.bashrc or ~/.bash_profile or /etc/profile.
Ok I tried that in all those files, and sourced them, and for each one, it gave an error message saying bash: TMOUT: readonly variable. I tried this as my regular user and as root.
I manned bash and found mention of a select command buried in there, do you think that's what it is? Though I searched all three of those files for that also, and found nothing. Will it be necessary to pass a parameter to bash on the command line just to have a window that doesn't close? Is this even possible? That sounds so dirty to do it that way, I hope there is a way to correct this.
My linux installation is on a 'high' security level. Previously, it was on a 'standard' security level. Would that play a role in this?
Aha, I had an apostrophe ' before set. It's fixed now. Do I have to log out, or restart or is there a way to run this file to set the new environment variable value? Also, after seeing the results of what you just suggested, this is the only file that has this line in it. I went to the F2 console and logged in as a different user, and did echo $TMOUT, and it was still set to 3600.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.