Alert on inbound SSH

Discussion in 'Mac Basics and Help' started by ebt, Jan 19, 2011.

  1. ebt macrumors newbie

    Joined:
    Jan 19, 2011
    #1
    Hi All,

    My first post to the board, after a few weeks of lurking/reading. Im new to Mac, but a pretty quick learner (you'd shudder at how much I've been poking around in terminal).

    Anyway, I need to find a way to generate an audible and screen based alert (preferably a window that is persistent/has to be acknowledged) when an incoming SSH connection establishes.

    So far I've found a script that will send an email if root logs in and an app (who is connected), but neither quite do the job.

    Any suggestions?
     
  2. ebt thread starter macrumors newbie

    Joined:
    Jan 19, 2011
    #3
    Thanks, i had a look but snitch seems to be based around sessions that send from me to outside world (Im looking for something that spots ssh connections from outside to me)..... unless I've been stupid and not read the snitch documents properly :)
     
  3. mulo macrumors 68020

    mulo

    Joined:
    Aug 22, 2010
    Location:
    Behind you
    #4
    your exactly right, it wont do it.
     
  4. aussiedj macrumors regular

    Joined:
    Dec 31, 2008
    Location:
    Brisbane
    #5
    Correct, Little Snitch is for outgoing connections, not incoming.
     
  5. ebt thread starter macrumors newbie

    Joined:
    Jan 19, 2011
    #6
    ok, so I've tinkered a bit with growlnotify, which seems to do 1/2 of what I need. I guess I could combine it with a loginhook for whichever account logs in, but then I wouldnt get alerts for failled SSH attempts.

    Is there any way or triggering an event from receipt of a packet on a certain port (22)? .... ideally from the command line so I could whack it into a script.
     
  6. aussiedj macrumors regular

    Joined:
    Dec 31, 2008
    Location:
    Brisbane
    #7
    Ahhh, I can see your going to be right at home here! :)

    And GREAT to see a new mac user not afraid to grab the bull by the horns and with your "there HAS TO BE a solution" attitude, you are a pro already. So refreshing to see! And welcome to the mac community!

    Can't help you with your question though. But this is currently in "basics" section. I suggest you ask in mac programming as they should be able to point you in the right direction.
     
  7. ebt thread starter macrumors newbie

    Joined:
    Jan 19, 2011
    #8
    Good advise, thanks.....

    ...but dont mistake being stubborn for anything other than it is ;)
     
  8. aussiedj macrumors regular

    Joined:
    Dec 31, 2008
    Location:
    Brisbane
    #9
    Haha, most certainly not. I'm exactly the same, and I almost ALWAYS find the solution eventually. :D
     
  9. LPZ macrumors 65816

    Joined:
    Jul 11, 2006
    #10
    Why do you want to do this?
     

Share This Page