Gentoo Archives: gentoo-user

From: Alan McKinnon <alan.mckinnon@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Making sure I am a good netizen and secure.
Date: Sat, 05 Sep 2009 10:46:08
Message-Id: 200909051244.33464.alan.mckinnon@gmail.com
In Reply to: [gentoo-user] Making sure I am a good netizen and secure. by Dale
1 On Saturday 05 September 2009 11:56:09 Dale wrote:
2 > Hi,
3 >
4 > As some may know already, I recently got DSL. It's not a super fast
5 > connection by broadband standards but it does mean that my box may be
6 > easier to find for a hacker. So, I have a few questions about
7 > security. I think I am OK but want to make sure.
8 >
9 > 1: I have a good root password. It's not something someone would guess
10 > for sure. Nothing related to my history, birthdays or anything. It is
11 > still fairly easy for me to type tho.
12
13 Good. Also disable root login using sshd
14
15 > 2: I went to this link: https://www.grc.com/x/ne.dll?bh0bkyd2
16 > According to that site my ports are in "stealth" mode which is good from
17 > what I understand.
18
19 That's Gibson. Sometimes he talks sense and has good ideas, but he always
20 rambles. Wheat and chaff.
21
22 Run "netstat -atnup" and see what's open. Apply brainpower to what you see.
23 Learn how to drive nmap and throw it at localhost. Apply brainpower to what
24 you see.
25
26 > 3: I have no servers running here. No Apache, MySql, or any of that.
27 > I also have turned off/stopped ssh since I have only one box at the
28 > moment.
29
30 no services running by default is a sane starting point for personal use. But
31 you will likely need *some* services, so deploy them one by one and audit each
32 one before taking it live. Start them only when you need them.
33
34 > 4: I'm currently using this kernel: 2.6.25-gentoo-r9 I plan to
35 > upgrade that in the next day or so.
36
37 Kernel bugs exist of course, but in terms of numbers, it's far easier for
38 someone to access your box using other routes. Like php.
39
40 Pay attention to kernel bugs but you also have to prioritize by risk factor,
41 so that one is correspondingly lower on the list.
42
43 > The DSL modem I am using is the Motorola 2210. It seems to be a gateway
44 > thing. I have no router at the moment but if I build a new rig I will
45 > be getting one then. Most likely a Linksys or something. I'll post
46 > here before getting one anyway. ;-)
47 >
48 > Am I missing anything? If you need more info, let me know. I just want
49 > to make sure no one can get into my box without me knowing about it and
50 > getting into mischief.
51
52 By far the most common attack vector into home machines is users doing stupid
53 things with mail and dodgy links. This is how phishers work. So you need to
54 apply diligence in what you click and where you go. But, you are likely
55 exercising this already.
56
57 Top of my list is always to lock down things that give shell access. No
58 telnet, no root login, access for specific users only. I use "AllowGroups" in
59 sshd_config a lot - only that group's members may log in and one grep shows
60 you exactly who is in that group.
61
62 You deal with brute force attacks using packages like fail2ban and denyhosts.
63 The general idea is that if a certain number of failed attempts show up in the
64 logs in a short time, that IP is locked out for a few hours.
65
66 john the ripper is excellent at finding weak passwords. I don't know how much
67 benefit you will get - having only two users with passwords - but I use it
68 routinely on my servers. There's a certain satisfaction in attending security
69 forum meetings and telling some manager with a stick up his ass that you are
70 the one who trashed his access because you found his password in 38 seconds
71 :-)
72
73 --
74 alan dot mckinnon at gmail dot com

Replies

Subject Author
Re: [gentoo-user] Making sure I am a good netizen and secure. Dale <rdalek1967@×××××.com>