On Fri, 27 Sep 2002, Rick Moen wrote:

> Quoting Ian C. Sison ([EMAIL PROTECTED]):
>
> > Slackware does not have any concept of dependencies, nor MD5 Checksums.
> > Those of you who have had the privelage of 'unrooting' a rooted box will
> > definitely appreciate the latter feature.
>
> I don't know about you, but I wouldn't trust a root-compromised box
> until it's been rebuilt from trusted media, regardless of which
> distribution it runs.  Relying on some check of MD5 checksums would
> be rash.

Not wanting to go into another set of detail picking on this issue, i'd
simply want to say that MD5 checking effectivity is accurate on a case to
case basis.  It will give you on occasion an idea that a box has been
rooted, and it will show you just which binaries and config files may be
compromised, but as with any other solution, is not the end all and
be-all of intrusion detection.  As you said, relying on it totally to fix
an intrusion would be rash.

Even a total reinstall from trusted media can give you a false sense of
security. If what you did is just simply reinstall, and copy over (for
instance) of your web pages with cgi scripts which contain
vulnerabilities, then you will be rooted again.


> There are lots of reasons.  For one thing, the intruder's actions might
> involve only your configuration files, not your binaries.  Your MD5 sums
> don't cover the former, do they?  If they do, that would be very


Yes they do.

An  'rpm -Va' will give md5 sum failures for files such as inittab or
httpd.conf if you even modified it from its original state.

> And that raises the question of where you have the MD5 sums _stored_.
> Would that be on the host itself, on media that aren't hardware
> write-protected?  Like, for example, /var/lib/rpm/* ?  If so, what
> reason do you have to trust that those MD5 sums haven't been changed by
> the intruder?

The only way an intruder can change that is to use RPM itself to 'update'
packages on your system.  Generally most rootkits come as tarballs, which
are recompiled on the host system.  So it's bad luck if your rooter
decides to integrate his compromise cleanly into your system \8(.

As i said, it's one of those tools, not a total solution.

> And what do you run to check those MD5 sums?  A utility that's on the
> compromised system?  What earthly reason do you have to expect it to
> give you results that haven't been specified _by_ the intruder?  Pretty
> much the only way you can avoid that risk is to boot from
> non-compromised media (e.g., a CDR or maintenance floppy) and run
> programs entirely from it.

Which is what something like chkrootkit suggests.  Again, it's another way
of detecting intrusion, and it's not a total solution.  It's just one of
the tools you use.

There are ways by which RPM can be useful in detecting certain roots.
One is to create a list of files in your system (executable files, that
is)  which do not belong to any RPM.  Such files are immediately suspect,
and on a well maintained system (no installs done via tarballs) can
immediately be identified.  If it does not flag any problem then maybe you
have a sophisticated LKM exploit, or your intruder simply integrated his
exploit into your system.

(+) results are good and may give you an idea of what is going on
(-) results do not conclude anything, and one must find other ways of
    detecting where the intrusion is.





_
Philippine Linux Users Group. Web site and archives at http://plug.linux.org.ph
To leave: send "unsubscribe" in the body to [EMAIL PROTECTED]

Fully Searchable Archives With Friendly Web Interface at http://marc.free.net.ph

To subscribe to the Linux Newbies' List: send "subscribe" in the body to 
[EMAIL PROTECTED]

Reply via email to