<?xml version="1.0"?>
<rss version="2.0">
	<channel>
		<title>[Linux/UNIX] Configure /etc/sudoers to ask for password only on some command</title>
		<link>http://www.allegro.cc/forums/view/589428</link>
		<description>Allegro.cc Forum Thread</description>
		<webMaster>matthew@allegro.cc (Matthew Leverton)</webMaster>
		<lastBuildDate>Sat, 06 Jan 2007 23:57:54 +0000</lastBuildDate>
	</channel>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>I need to configure my /etc/sudoers file to ask for a password when running anything except /etc/init.d/ssh.</p><p>At the moment I have:</p><div class="source-code snippet"><div class="inner"><pre>Defaults env_reset, env_keep <span class="k3">=</span> DISPLAY

Cmnd_Alias SSH <span class="k3">=</span> <span class="k3">/</span>etc<span class="k3">/</span>init.d<span class="k3">/</span>ssh

root ALL <span class="k3">=</span> <span class="k2">(</span>ALL<span class="k2">)</span> ALL

james ALL <span class="k3">=</span> NOPASSWD: SSH
</pre></div></div><p>

How would I configure to allow everything else to require a password?</p><p>Thanks.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (James Stanley)</author>
		<pubDate>Fri, 05 Jan 2007 22:26:32 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p><span class="source-code">james ALL <span class="k3">=</span> <span class="k2">(</span>ALL<span class="k2">)</span> ALL</span>
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (CGamesPlay)</author>
		<pubDate>Fri, 05 Jan 2007 22:58:28 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>That still asks for a password on /etc/init.d/ssh.</p><p>EDIT:<br />Actually, I can&#39;t prove that yet. It still remembers my password and I need it to timeout. I think that&#39;s what i had before and it always required a password, although the command alias for SSH wasn&#39;t at the top before. I&#39;ll see.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (James Stanley)</author>
		<pubDate>Fri, 05 Jan 2007 23:04:35 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>You added it as a separate line? What&#39;s <tt>sudo -l</tt> say?</p><p>[append]<br /><tt>sudo -k</tt> clears the timeout.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (CGamesPlay)</author>
		<pubDate>Fri, 05 Jan 2007 23:09:08 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Why do you need to be root to run ssh and why is your ssh in /etc/init.d?
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Evert)</author>
		<pubDate>Fri, 05 Jan 2007 23:18:13 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>I replaced the line I already had with yours. Is that right?</p><p>sudo -l said:</p><p>User james may run the following commands on this host:<br />    (ALL) ALL</p><p>You need to be root to start the SSH server. The startup script for the SSH server is in /etc/init.d because that is where it goes. To be honest, I don&#39;t entirely know why. I think it is so that init knows to run it.</p><p>EDIT:</p><p>sudo -V said:</p><p>Sudo version 1.6.8p12
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (James Stanley)</author>
		<pubDate>Fri, 05 Jan 2007 23:22:41 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Can&#39;t you just tell it to startup via init instead? As all daemons should be?
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Thomas Fjellstrom)</author>
		<pubDate>Fri, 05 Jan 2007 23:30:34 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>It does start via init. I guess I should have explained:</p><p>Occasionally I need to SSH to my computer. Also, I like to turn off the server after I have used it. But if I do that through SSH I can&#39;t get back in, so I have set up a filter in KMail. Whenever I receive an email with some special information in it, it runs sudo /etc/init.d/ssh start, then I can ssh in. Once I&#39;m done, I send myself another email with some different data in it and it stops the server.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (James Stanley)</author>
		<pubDate>Fri, 05 Jan 2007 23:33:47 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Ah! It&#39;s called sshd on my system.<br />Anyway, I&#39;m not sure allowing normal users to start or stop sshd like that is a good idea, security-wise. I understand what you&#39;re trying to do, but can&#39;t you send an e-mail to the root user instead? Even then, I&#39;m not sure it&#39;s such a good idea.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Evert)</author>
		<pubDate>Fri, 05 Jan 2007 23:44:52 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Root is never logged on, so would not receive the message.</p><p>Why is it not a good idea? I am the only person who uses the computer. If I find that it won&#39;t connect, I can start it, if I find it has been started by somebody then it is no different to leaving it on all the time.</p><p>EDIT:<br />Yeah, the executable is called sshd on mine too. I just prefer to use /etc/init.d/ssh to start and stop it (I don&#39;t know why).
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (James Stanley)</author>
		<pubDate>Fri, 05 Jan 2007 23:47:32 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
I just prefer to use /etc/init.d/ssh to start and stop it (I don&#39;t know why).
</p></div></div><p>Because it&#39;s the init script, and it won&#39;t be shut down properly (automatically) if you don&#39;t.</p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
To be honest, I don&#39;t entirely know why. I think it is so that init knows to run it.
</p></div></div><p>Convention; sshd can be run without using that script, but you can&#39;t have it start automatically without it.</p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
Occasionally I need to SSH to my computer. Also, I like to turn off the server after I have used it. But if I do that through SSH I can&#39;t get back in, so I have set up a filter in KMail. Whenever I receive an email with some special information in it, it runs sudo /etc/init.d/ssh start, then I can ssh in. Once I&#39;m done, I send myself another email with some different data in it and it stops the server.
</p></div></div><p>I hope you know you don&#39;t actually gain any security from this. Think about it logically: if someone wanted to hack into your machine, they would no doubt be monitoring your internet traffic. The email with the &quot;special information&quot; is sent in clear, so it can easily be reproduced (unless you are using a 1-time key, which I know you aren&#39;t <img src="http://www.allegro.cc/forums/smileys/rolleyes.gif" alt="::)" />). Your SSH server itself is more secure than any email; why not just run it? If resources are a problem, run it using inetd.</p><p>Anyways, assuming you are doing it just for fun:</p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
I replaced the line I already had with yours. Is that right?
</p></div></div><p>No, you need to be able to access all commands, and additionally you need to be able to access ssh without a password. Stated in sudoers-ish:
</p><div class="source-code snippet"><div class="inner"><pre>james ALL <span class="k3">=</span> <span class="k2">(</span>ALL<span class="k2">)</span> ALL
james ALL <span class="k3">=</span> NOPASSWD: SSH
</pre></div></div><p>
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (CGamesPlay)</author>
		<pubDate>Fri, 05 Jan 2007 23:58:05 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
Root is never logged on
</p></div></div><p>
So what? The message is still received by the system, you can respond to that (try man procmail, for instance).</p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
Why is it not a good idea?
</p></div></div><p>
Because you&#39;re adding a possible vulnerability where there wasn&#39;t one before. If a normal user normally shouldn&#39;t be able to do something, then you should think twice before changing that.</p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
I am the only person who uses the computer.
</p></div></div><p>
So why not let sshd run normally?</p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
If I find that it won&#39;t connect, I can start it, if I find it has been started by somebody then it is no different to leaving it on all the time.
</p></div></div><p>
And if someone shuts it down while you&#39;re logged in?</p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
Yeah, the executable is called sshd on mine too. I just prefer to use /etc/init.d/ssh to start and stop it (I don&#39;t know why).
</p></div></div><p>
That&#39;s what I meant. It&#39;s /etc/init.d/sshd on my machine.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Evert)</author>
		<pubDate>Sat, 06 Jan 2007 00:02:20 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Ah! Thank you. That works. I realised I wasn&#39;t gaining much security, but it&#39;s fun and I could apply to anything else I need to start while I&#39;m not at my computer.</p><p>Anyway, thanks.</p><p>EDIT:<br />Evert: OK. Sorry if I offended you.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (James Stanley)</author>
		<pubDate>Sat, 06 Jan 2007 00:04:28 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
OK. Sorry if I offended you.
</p></div></div><p>
Where did you get that idea from? <img src="http://www.allegro.cc/forums/smileys/huh.gif" alt="???" />
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Evert)</author>
		<pubDate>Sat, 06 Jan 2007 00:08:03 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>You just seemed angry, that&#39;s all.</p><p>I&#39;ve always been bad at judging emotion when the person isn&#39;t actually there...
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (James Stanley)</author>
		<pubDate>Sat, 06 Jan 2007 00:09:52 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
So what? The message is still received by the system, you can respond to that (try man procmail, for instance).
</p></div></div><p>His system isn&#39;t running an SMTP server. KMail is receiving it from his POP account.</p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
Because you&#39;re adding a possible vulnerability where there wasn&#39;t one before.
</p></div></div><p>James: the only vulnerability is that now any person, user or not, can activate your ssh server. Not a serious problem, in this case.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (CGamesPlay)</author>
		<pubDate>Sat, 06 Jan 2007 00:14:11 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Yeah, that&#39;s what I thought.</p><p>The only vulnerability might be if somebody knows how to get the SSH server to edit something that allows them to elevate privileges without passwords, but that&#39;s unlikely, and they&#39;d probably need access to the computer.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (James Stanley)</author>
		<pubDate>Sat, 06 Jan 2007 00:17:36 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
The only vulnerability might be if somebody knows how to get the SSH server to edit something that allows them to elevate privileges without passwords, but that&#39;s unlikely, and they&#39;d probably need access to the computer.
</p></div></div><p>That&#39;s a bug in ssh, and there is nothing you can do about it. Take comfort in the fact that hacking basically any other server on the net would be more profitable.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (CGamesPlay)</author>
		<pubDate>Sat, 06 Jan 2007 00:19:30 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Ha ha! OK. I wasn&#39;t going to worry about it. Nobody has ever tried to hack me before, anyway (AFAIK).
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (James Stanley)</author>
		<pubDate>Sat, 06 Jan 2007 00:27:32 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
You just seemed angry, that&#39;s all.
</p></div></div><p>
How so?<br />Also, what reason could I possibly have for being angry?
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Evert)</author>
		<pubDate>Sat, 06 Jan 2007 00:45:18 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>The way you keep questioning everything I say. I don&#39;t know what I said that could have made you angry, but you seemed it. End of discussion.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (James Stanley)</author>
		<pubDate>Sat, 06 Jan 2007 00:47:42 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
The way you keep questioning everything I say. I don&#39;t know what I said that could have made you angry, but you seemed it.
</p></div></div><p>A common mistake many people make when communicating online is incorrectly differentiating between being angry and being critical. Evert was just saying what he had to say without any emotion. Because that didn&#39;t agree with what you were saying, you assumed he was angry at you <img src="http://www.allegro.cc/forums/smileys/smiley.gif" alt=":)" /></p><p>Arguments don&#39;t have to be angry, they can be fun!</p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
End of discussion.
</p></div></div><p>Hah!
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (CGamesPlay)</author>
		<pubDate>Sat, 06 Jan 2007 00:56:11 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Wait a minute...<br />You said it was more profitable to hack nearly any other SSH server. Look what I just found:</p><p>Jan 3 16:25:07 derek sshd[20552]: Failed password for invalid user staff from 61.232.12.74 port 47970 ssh2<br />Jan 3 16:25:12 derek sshd[20554]: Failed password for invalid user sales from 61.232.12.74 port 56057 ssh2<br />Jan 3 16:25:19 derek sshd[20556]: Failed password for invalid user recruit from 61.232.12.74 port 34721 ssh2<br />Jan 3 16:25:23 derek sshd[20560]: Failed password for invalid user alias from 61.232.12.74 port 47259 ssh2<br />Jan 3 16:25:29 derek sshd[20562]: Failed password for invalid user office from 61.232.12.74 port 54685 ssh2<br />Jan 3 16:25:34 derek sshd[20566]: Failed password for invalid user samba from 61.232.12.74 port 35611 ssh2<br />Jan 3 16:25:40 derek sshd[20568]: Failed password for invalid user tomcat from 61.232.12.74 port 43391 ssh2<br />Jan 3 16:25:44 derek sshd[20570]: Failed password for invalid user webadmin from 61.232.12.74 port 54398 ssh2<br />Jan 3 16:25:50 derek sshd[20574]: Failed password for invalid user spam from 61.232.12.74 port 34716 ssh2<br />Jan 3 16:25:55 derek sshd[20576]: Failed password for invalid user virus from 61.232.12.74 port 44590 ssh2<br />Jan 3 16:26:00 derek sshd[20578]: Failed password for invalid user cyrus from 61.232.12.74 port 53034 ssh2<br />Jan 3 16:26:05 derek sshd[20582]: Failed password for invalid user oracle from 61.232.12.74 port 33049 ssh2<br />Jan 3 16:26:10 derek sshd[20584]: Failed password for invalid user michael from 61.232.12.74 port 41657 ssh2<br />Jan 3 16:26:15 derek sshd[20586]: Failed password for invalid user ftp from 61.232.12.74 port 49626 ssh2<br />Jan 3 16:26:20 derek sshd[20588]: Failed password for invalid user test from 61.232.12.74 port 58287 ssh2<br />Jan 3 16:26:26 derek sshd[20590]: Failed password for invalid user webmaster from 61.232.12.74 port 38132 ssh2<br />Jan 3 16:26:31 derek sshd[20592]: Failed password for invalid user postmaster from 61.232.12.74 port 47055 ssh2<br />Jan 3 16:26:37 derek sshd[20594]: Failed password for invalid user postfix from 61.232.12.74 port 55739 ssh2<br />Jan 3 16:26:42 derek sshd[20598]: Failed password for invalid user postgres from 61.232.12.74 port 37382 ssh2<br />Jan 3 16:26:47 derek sshd[20600]: Failed password for invalid user paul from 61.232.12.74 port 45001 ssh2<br />Jan 3 16:26:51 derek sshd[20604]: Failed password for root from 61.232.12.74 port 53053 ssh2<br />Jan 3 16:26:57 derek sshd[20608]: Failed password for invalid user guest from 61.232.12.74 port 33028 ssh2<br />Jan 3 16:27:02 derek sshd[20610]: Failed password for invalid user admin from 61.232.12.74 port 42385 ssh2<br />Jan 3 16:27:09 derek sshd[20612]: Failed password for invalid user linux from 61.232.12.74 port 51860 ssh2<br />Jan 3 16:27:14 derek sshd[20614]: Failed password for invalid user user from 61.232.12.74 port 34882 ssh2<br />Jan 3 16:27:19 derek sshd[20616]: Failed password for invalid user david from 61.232.12.74 port 43296 ssh2<br />Jan 3 16:27:25 derek sshd[20618]: Failed password for invalid user web from 61.232.12.74 port 52584 ssh2<br />Jan 3 16:27:30 derek sshd[20622]: Failed password for invalid user apache from 61.232.12.74 port 33583 ssh2<br />Jan 3 16:27:35 derek sshd[20626]: Failed password for invalid user pgsql from 61.232.12.74 port 42544 ssh2<br />Jan 3 16:27:42 derek sshd[20628]: Failed password for invalid user mysql from 61.232.12.74 port 52363 ssh2<br />Jan 3 16:27:47 derek sshd[20632]: Failed password for invalid user info from 61.232.12.74 port 36526 ssh2<br />Jan 3 16:27:55 derek sshd[20634]: Failed password for invalid user tony from 61.232.12.74 port 45554 ssh2<br />Jan 3 16:28:02 derek sshd[20638]: Failed password for invalid user core from 61.232.12.74 port 60180 ssh2<br />Jan 3 16:28:08 derek sshd[20640]: Failed password for invalid user newsletter from 61.232.12.74 port 43810 ssh2<br />Jan 3 16:28:14 derek sshd[20644]: Failed password for invalid user named from 61.232.12.74 port 53885 ssh2<br />Jan 3 16:28:19 derek sshd[20646]: Failed password for invalid user visitor from 61.232.12.74 port 34720 ssh2<br />Jan 3 16:28:28 derek sshd[20650]: Failed password for invalid user ftpuser from 61.232.12.74 port 43796 ssh2<br />Jan 3 16:28:34 derek sshd[20654]: Failed password for invalid user username from 61.232.12.74 port 58307 ssh2<br />Jan 3 16:28:39 derek sshd[20658]: Failed password for invalid user administrator from 61.232.12.74 port 40039 ssh2<br />Jan 3 16:28:45 derek sshd[20662]: Failed password for invalid user library from 61.232.12.74 port 49491 ssh2<br />Jan 3 16:28:51 derek sshd[20664]: Failed password for invalid user test from 61.232.12.74 port 60543 ssh2<br />Jan 3 16:28:56 derek sshd[20666]: Failed password for root from 61.232.12.74 port 42015 ssh2<br />Jan 3 16:29:02 derek sshd[20668]: Failed password for root from 61.232.12.74 port 51793 ssh2<br />Jan 3 16:29:08 derek sshd[20694]: Failed password for invalid user admin from 61.232.12.74 port 33110 ssh2<br />Jan 3 16:29:13 derek sshd[20698]: Failed password for invalid user guest from 61.232.12.74 port 43066 ssh2<br />Jan 3 16:29:22 derek sshd[20702]: Failed password for invalid user master from 61.232.12.74 port 53343 ssh2<br />Jan 3 16:29:27 derek sshd[20704]: Failed password for root from 61.232.12.74 port 39298 ssh2<br />Jan 3 16:29:36 derek sshd[20708]: Failed password for root from 61.232.12.74 port 50226 ssh2<br />Jan 3 16:29:42 derek sshd[20712]: Failed password for root from 61.232.12.74 port 38921 ssh2<br />Jan 3 16:29:48 derek sshd[20714]: Failed password for root from 61.232.12.74 port 48867 ssh2<br />Jan 3 16:29:55 derek sshd[20718]: Failed password for root from 61.232.12.74 port 60474 ssh2<br />Jan 3 16:30:00 derek sshd[20722]: Failed password for invalid user admin from 61.232.12.74 port 43873 ssh2<br />Jan 3 16:30:10 derek sshd[20726]: Failed password for invalid user admin from 61.232.12.74 port 53147 ssh2<br />Jan 3 16:30:15 derek sshd[20728]: Failed password for invalid user admin from 61.232.12.74 port 40931 ssh2<br />Jan 3 16:30:22 derek sshd[20730]: Failed password for invalid user admin from 61.232.12.74 port 50321 ssh2<br />Jan 3 16:30:28 derek sshd[20732]: Failed password for root from 61.232.12.74 port 60204 ssh2<br />Jan 3 16:30:33 derek sshd[20734]: Failed password for root from 61.232.12.74 port 42430 ssh2<br />Jan 3 16:30:40 derek sshd[20736]: Failed password for invalid user test from 61.232.12.74 port 52732 ssh2<br />Jan 3 16:30:46 derek sshd[20740]: Failed password for invalid user test from 61.232.12.74 port 36377 ssh2<br />Jan 3 16:30:58 derek sshd[20744]: Failed password for invalid user webmaster from 61.232.12.74 port 45941 ssh2<br />Jan 3 21:14:33 derek sshd[24073]: Failed password for invalid user staff from 61.142.83.245 port 48583 ssh2<br />Jan 4 04:51:49 derek sshd[27135]: Failed password for root from 125.248.86.5 port 44088 ssh2<br />Jan 4 04:51:55 derek sshd[27137]: Failed password for invalid user sifak from 125.248.86.5 port 48097 ssh2<br />Jan 4 04:52:01 derek sshd[27139]: Failed password for invalid user slasher from 125.248.86.5 port 52529 ssh2<br />Jan 4 04:52:08 derek sshd[27141]: Failed password for invalid user fluffy from 125.248.86.5 port 57174 ssh2<br />Jan 4 04:52:14 derek sshd[27143]: Failed password for invalid user admin from 125.248.86.5 port 34434 ssh2<br />Jan 4 04:52:19 derek sshd[27145]: Failed password for invalid user test from 125.248.86.5 port 38912 ssh2<br />Jan 4 04:52:24 derek sshd[27147]: Failed password for invalid user guest from 125.248.86.5 port 43622 ssh2<br />Jan 4 04:52:29 derek sshd[27149]: Failed password for invalid user webmaster from 125.248.86.5 port 47444 ssh2<br />Jan 4 04:52:37 derek sshd[27151]: Failed password for invalid user mysql from 125.248.86.5 port 51329 ssh2<br />Jan 4 04:52:42 derek sshd[27153]: Failed password for invalid user oracle from 125.248.86.5 port 56331 ssh2<br />Jan 4 04:52:47 derek sshd[27155]: Failed password for invalid user library from 125.248.86.5 port 60746 ssh2<br />Jan 4 04:52:56 derek sshd[27157]: Failed password for invalid user info from 125.248.86.5 port 36366 ssh2<br />Jan 4 04:53:01 derek sshd[27159]: Failed password for invalid user shell from 125.248.86.5 port 42826 ssh2<br />Jan 4 04:53:07 derek sshd[27161]: Failed password for invalid user linux from 125.248.86.5 port 46849 ssh2<br />Jan 4 04:53:14 derek sshd[27163]: Failed password for invalid user unix from 125.248.86.5 port 50759 ssh2<br />Jan 4 04:53:26 derek sshd[27165]: Failed password for invalid user webadmin from 125.248.86.5 port 54377 ssh2<br />Jan 5 18:41:07 derek sshd[18880]: Failed password for james from 127.0.0.1 port 40283 ssh2
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (James Stanley)</author>
		<pubDate>Sat, 06 Jan 2007 22:49:40 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Thats most likely a bot scanning random computers for SSH and possible holes, to probably then install a backdoor for sending spam
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Thomas Fjellstrom)</author>
		<pubDate>Sat, 06 Jan 2007 23:00:07 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>I get those.<br />Don&#39;t worry about it, just be sure you don&#39;t pick too obvious passwords (especially the root password), make sure you keep the system up-to-date with security patches and limit what normal users can do (which is default anyway).</p><p>I think it would be possible to disable remote root logins if you&#39;re worried about that; it&#39;s something I&#39;ve been meaning to look into but haven&#39;t got round to yet.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Evert)</author>
		<pubDate>Sat, 06 Jan 2007 23:09:11 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
Jan 5 18:41:07 derek sshd[18880]: Failed password for james from 127.0.0.1 port 40283 ssh2
</p></div></div><p>

<img src="http://www.allegro.cc/forums/smileys/cheesy.gif" alt=":D" />
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (LennyLen)</author>
		<pubDate>Sat, 06 Jan 2007 23:12:28 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>I disabled root logins the second I read my log. I now only allow logins by james. I emailed the ISP of the 61 address and hopefully they&#39;ll stop his connection. I couldn&#39;t get in touch with the other.</p><p>If you want to disable root logins it is &#39;PermitRootLogin no&#39;</p><p>There is also,</p><p>AllowUsers user1 user2 etc<br />AllowGroups group1 group2 etc<br />DenyUsers user1 user2 etc<br />DenyGroups group1 group2 etc</p><p>EDIT:
</p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
</p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
Jan 5 18:41:07 derek sshd[18880]: Failed password for james from 127.0.0.1 port 40283 ssh2
</p></div></div><p>
</p></div></div><p>

I should have removed that one before posting... <img src="http://www.allegro.cc/forums/smileys/smiley.gif" alt=":)" /></p><p>I was testing the email activation thing and I typed my password wrong <img src="http://www.allegro.cc/forums/smileys/smiley.gif" alt=":)" />
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (James Stanley)</author>
		<pubDate>Sat, 06 Jan 2007 23:12:56 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
I emailed the ISP of the 61 address and hopefully they&#39;ll stop his connection.
</p></div></div><p>

Unforunately, it&#39;s quite possible that&#39;s just a proxy server address.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (LennyLen)</author>
		<pubDate>Sat, 06 Jan 2007 23:15:09 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Oh yeah... I hadn&#39;t thought of that.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (James Stanley)</author>
		<pubDate>Sat, 06 Jan 2007 23:17:03 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
I disabled root logins the second I read my log.
</p></div></div><p>
I personally think you&#39;re being paranoid, but disallowing remote root logins is usually a good idea regardless.</p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
I now only allow logins by james.
</p></div></div><p>
I guess I&#39;m lucky that many ofthe &quot;obvious&quot; user names don&#39;t exist on my system. <img src="http://www.allegro.cc/forums/smileys/smiley.gif" alt=":)" /></p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
I emailed the ISP of the 61 address and hopefully they&#39;ll stop his connection.
</p></div></div><p>
It&#39;s quite possible that it traces back to a hijacked computer as well, in which case you have the wrong guy. </p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
If you want to disable root logins it is &#39;PermitRootLogin no&#39;
</p></div></div><p>
I know; I want to disable su and sudo except from users (well, me) that are logged in locally (ie, not remotely).</p><p>I used to get this once or twice per day a while back; at first I found it disturbing and unnerving (and it is annoying), but if you keep your system reasonably up to date and don&#39;t have any dodgy security holes (like activating the sshd daemon through e-mail <img src="http://www.allegro.cc/forums/smileys/wink.gif" alt=";)" />) you shouldn&#39;t have anything to worry about. <img src="http://www.allegro.cc/forums/smileys/smiley.gif" alt=":)" />
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Evert)</author>
		<pubDate>Sat, 06 Jan 2007 23:26:52 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>It can also help to have your firewall set to drop certian types of connections, like just the &quot;ACK&quot; part.. Well I mean, many scanners only ask to see if a port is open, and don&#39;t actually try and open it, its this type of check you can block to make it look like open ports really aren&#39;t open.</p><p>The only scans I see these days are lame NSBIOS/SMB crap.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Thomas Fjellstrom)</author>
		<pubDate>Sat, 06 Jan 2007 23:57:54 +0000</pubDate>
	</item>
</rss>
