Follow us on...
Follow us on Twitter Follow us on Facebook
Register
Results 1 to 4 of 4
  1. #1
    bbloke's Avatar
    bbloke is offline Registered User
    Join Date
    Jun 2002
    Location
    UK
    Posts
    1,613
    Thanks
    1
    Thanked 31 Times in 25 Posts

    Exclamation Alarming Terminal app behavior (10.1.5)

    I recently sent this post to the Apple Discussions pages because I am somewhat concerned by the Terminal's behavior under 10.1.5. I'm sure it did not used to do this and I want to see if people on this forum can duplicate my findings and find a solution!


    "I have noticed something a little worrying when using the Terminal under 10.1.5, where users are not being logged off properly. To duplicate what I have observed, try the following:

    1) Open the Terminal app

    2) Type "w" (and Return) to show a list of those logged on. You will see at least two users, one using the console ("co") and one using the Terminal window you have open (eg ttyp1 is "p1").

    3) Now open a new Terminal window, so that you have two open. You will see the terminal session labeled in the title bar (eg "(ttyp2)").

    4) Type "w" again in the first Terminal window and see at least three sessions now (one console, two terminals).

    5) Log out of the second Terminal window (type "logout" or "exit" or "control-d")

    6) Go back to the first terminal window and type "w" again. You will see the second Terminal window was not logged out properly...

    My workaround for this was to run XDarwin and open as many xterm windows as I had Terminal Windows open, and logging out from each xterm properly logs me out for each one...

    So, is the Terminal app not properly logging users out any more?!"

  2. #2
    kilowatt's Avatar
    kilowatt is offline mach-o mach-o man
    Join Date
    Mar 2001
    Posts
    987
    Thanks
    0
    Thanked 0 Times in 0 Posts

    what shell?

    I'm using the bash shell, and it seems to behave differently.

    When I open up many terminals (via terminal.app), using `w`, `who`, or `finger` produces the same result - one user logged in via the console, ttyp0.

    My guess is that your defauly shell is running as a login shell instead of just a shell.

  3. #3
    fperez is offline Registered User
    Join Date
    May 2001
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts

    I know, I know!!

    I noticed this problem months ago. I started a thread in this forum, but nobody seem to care about it. It is rather odd to type w and see users that are not longer logged in. I first noticed it when root appeared to be in the third terminal (tty3 or p3?).

    This was so annoying that I did a clean install of OS X, and not, it didn't solve anything. My only question is if this is a problem related to X 10.1 or is even older?

    I did some reading, and the problem seems to be that some file keeps the reccord of who is logged in and where...Terminal correctly adds an entry to this file (I think is called utmp), but does not remove the entry when users logout.

    My real worry is any security problem that might arise due to this behaviour.

    any comments will be appreciated


    drizzt

  4. #4
    bbloke's Avatar
    bbloke is offline Registered User
    Join Date
    Jun 2002
    Location
    UK
    Posts
    1,613
    Thanks
    1
    Thanked 31 Times in 25 Posts

    Further info...

    Yup, kilowatt, it looks like it was a login shell. I did switch to using tcsh at one point, but I must have reverted to the login shell either on purpose at some point or else an upgrade must have changed my default settings. Either way, I've now switched back to using tcsh, which is what I am used to in the office too. Now the behavior is similar to what you report using bash.

    When opening new Terminal windows, typing "w" always shows the same number of sessions: one. There always seems to be a session on the console. I should perhaps try logging in as a non-administrator and see if that affects things. By comparison, running XDarwin, opening xterms, and then using "w" does show separate sessions (on ttypx, where x is a number) rather than using the console! So the Terminal app is behaving differently from a terminal window using the X Window server.

    In case people are not aware (I've only been using Unix for about a year and a half), the "last" command can be used to show previous logins and accesses the /var/log/wtmp file.

    fperez, I'm sorry if I missed your earlier post. If it's any consolation, I too was beginning to wonder if no one was interested in this thread (until today!) and my original post on Apple's Discussion pages still has not had a reply. My concern, like yours, is whether or not this is a security issue. I have set feedback to Apple, but if others are concerned I suggest they do likewise.

    Thanks for the feedback and I'd like to keep this thread going, as we might be looking at something which is potentially important...

 

 

Similar Threads

  1. autostart terminal app on login
    By neo36 in forum Unix & X11
    Replies: 10
    Last Post: November 24th, 2002, 11:10 PM
  2. how to open a app as root with terminal
    By taewon in forum Mac OS X System & Mac Software
    Replies: 14
    Last Post: April 14th, 2002, 01:20 AM
  3. slow terminal app
    By prefect in forum Apple News, Rumors & Discussion
    Replies: 1
    Last Post: April 4th, 2002, 12:10 AM
  4. terminal app for USB serial port
    By tyc in forum Mac OS X System & Mac Software
    Replies: 4
    Last Post: March 5th, 2002, 10:40 PM
  5. Terminal app | root password
    By silversurfer30 in forum Mac OS X System & Mac Software
    Replies: 1
    Last Post: November 18th, 2001, 07:55 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •