|
|
#21 | ||||||||||||||||||||||||||||||||||||||||||||||
|
MVP
Join Date: Apr 2002
Posts: 2,112
|
No, what you did there was fine... inasmuch as that setuid binary named "Locum" (with parent pathname /System/Library/PrivateFrameworks/DesktopServicesPriv.framework/Versions/A/Resources/) does indeed appear on the list in article TS1448). I just feel that any reassuring references to article TS1448 should be accompanied with some words to the effect that behind all this is some tiny design flaw which needs to be addressed. It's just unfortunate we users are put in this position in the first place. But, we should not succumb to this situation or send signals to others that this current status quo in "DURP" is to be regarded as acceptable behavior. What good is all this fancy technology unless engineers and technicians take care to assemble it correctly? [e.g., it seems sorta pointless when various "code-signed" objects fail validation as shipped.]
Just to be aware. In the real world, a sentence containing both the words "warning" and "suid" is something to which one would normally need pay serious attention. As far as using some Terminal trick to "tweak" the named files themselves, it's not necessary. In 99.9% of these cases (i.e., false positives), the item itself is already correct... it's just that Disk Utility isn't getting the proper info, which would otherwise confirm that fact. [there might be some fancy "pkgutil --learn" footwork we could resort to, but i haven't gotten that advanced yet... anyway, rightfully that's Apple's job.] |
||||||||||||||||||||||||||||||||||||||||||||||
|
|
|
|
|
#22 | |||||||||||||||||||||||
|
MVP
Join Date: Apr 2002
Posts: 2,112
|
A fanciful tale... and so beautifully told. But unfortunately, none of that applies to the suid warning in post #1 (or anything else in the TS1448 list). If you took some time to actually *study* the situation (instead of fabricating plausible scenarios to pacify the proles), you'd see that the correct info already exists inside the package receipt itself!!! But for some as yet unknown reason (re: bug), sometimes -- seemingly randomly -- the software update process doesn't transfer that info from the bom inside the package to that "boms" folder in Receipts, and finally into the a.receiptdb file. Is any of this sinking in yet? -- No? Follow me...
So now... with your permission, i'll repair to the dining room. [note: i used a 'CodeResources' example here because all my suid items are fine (plus CodeResources represent the most prevalent offenders). If someone has some other *specific* file they want traced (or a false belief they need fixed), just post it so we can walk (or talk) it through.] Last edited by Hal Itosis; 11-10-2009 at 10:59 PM. |
|||||||||||||||||||||||
|
|
|
|
|
#23 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
MVP
Join Date: Apr 2002
Posts: 2,112
|
The hacker in me is ROTFLOL. Another way to view article TS1448 is: "H3y h4c|<0/2z... h3/23 i5 4 1i57 0f 537uid phi135 7h47 /V\4c ph4nb0y5 vvi11 n3v3/2 d0ub13-ch3c|<" [hey hackers, here is a list of setuid files that Mac fanboys will never double-check]
And wasn't its initial lack of 'design' the very reason that DU was totally revamped in Leopard? Have we conveniently forgotten MoAB already? Why do you suppose the message in post #1 appears in the first place? Did we ever see such a thing in Tiger or Panther (or earlier)? Perhaps a little historical perspective would help the readers. I.e., do that googly thing on:
The whole reason that DU now even bothers to examine suid files so closely is precisely because its previous versions were vulnerable in the sense that hackers could employ DU [or diskutil without any human involvement!] as their trusted assistant. One reason a permissions repair run takes so long in Leopard (compared to Tiger, etc) is that the SHA-1 digest of every single *Mac OSX* suid file (past and present) is being tracked. For example... the file in post #1: Code:
$ pkgutil -v --file-info /System/Library/PrivateFrameworks/DesktopServicesPriv.framework/Versions/A/Resources/Locum
volume: /
path: System/Library/PrivateFrameworks/DesktopServicesPriv.framework/Versions/A/Resources/Locum
pkgid: com.apple.pkg.BaseSystem
pkg-version: 10.5.0.1.1.1192168948
install-time: Thu Nov 29 14:04:37 2007
uid: 0 (root)
gid: 0 (wheel)
mode: 104755 (-rwsr-xr-x )
sha1: <5c083e59 550156ce 9c29dccd 2c1b03ee ee8de0f7>
pkgid: com.apple.pkg.update.os.10.5.1
pkg-version: 1.0.1.1191932192
install-time: Thu Nov 29 17:08:57 2007
uid: 0 (root)
gid: 0 (wheel)
mode: 104755 (-rwsr-xr-x )
sha1: <000b4eee d7abf1d1 9d7502c9 61aca444 b706dea5>
pkgid: com.apple.pkg.update.os.10.5.2.combo
pkg-version: 1.0.1.1191932192
install-time: Mon Feb 11 23:33:27 2008
uid: 0 (root)
gid: 0 (wheel)
mode: 104755 (-rwsr-xr-x )
sha1: <a838b099 24330fe8 d87a89c7 e7b44bfe b0a366cf>
pkgid: com.apple.pkg.update.os.10.5.3.combo
pkg-version: 1.0.1.1191932192
install-time: Wed May 28 21:17:57 2008
uid: 0 (root)
gid: 0 (wheel)
mode: 104755 (-rwsr-xr-x )
sha1: <575abe89 ee144cb7 dfaaa749 1d2f01dd 35e38a66>
pkgid: com.apple.pkg.update.os.10.5.4.combo
pkg-version: 1.0.1.1191932192
install-time: Wed Sep 3 18:37:32 2008
uid: 0 (root)
gid: 0 (wheel)
mode: 104755 (-rwsr-xr-x )
sha1: <cae6dc40 3ef89b9d b1a1defb 994acf13 01ccaf04>
pkgid: com.apple.pkg.update.os.10.5.5.combo
pkg-version: 1.0.1.1191932192
install-time: Mon Sep 15 22:24:16 2008
uid: 0 (root)
gid: 0 (wheel)
mode: 104755 (-rwsr-xr-x )
sha1: <2c865dcf de9932a1 9bb5ae68 31effef1 a095116d>
pkgid: com.apple.pkg.update.os.10.5.6.combo
pkg-version: 1.0.1.1191932192
install-time: Tue Dec 16 00:33:52 2008
uid: 0 (root)
gid: 0 (wheel)
mode: 104755 (-rwsr-xr-x )
sha1: <87ad1e1c a31cb18b 8debe905 1c6a4d3f a6790de1>
pkgid: com.apple.pkg.update.os.10.5.7.combo
pkg-version: 1.0.1.1191932192
install-time: Wed May 13 03:05:42 2009
uid: 0 (root)
gid: 0 (wheel)
mode: 104755 (-rwsr-xr-x )
sha1: <3f03100d 2c6e0fd0 42bafad9 647b15ce 91669189>
pkgid: com.apple.pkg.update.os.10.5.8.combo
pkg-version: 1.0.1.1191932192
install-time: Thu Sep 3 12:18:26 2009
uid: 0 (root)
gid: 0 (wheel)
mode: 104755 (-rwsr-xr-x )
sha1: <c59d0903 a901a3f1 4c5038b7 a4ae0493 65edc2a8>
Please OBSERVE: in the nine *different* versions of Locum listed above, not a single "permission" was ever changed. The file's *contents* did change however, with every update... and that's every bit as important (if not more so) than "permissions" [which is why DU no longer blindly fixes such items. But it doesn't disable them either... so users still need to keep their wits about them]. -- Review:
Questions:
Last edited by Hal Itosis; 11-11-2009 at 04:42 PM. |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
|
|
|
#24 | |||||||||||||||||||||||
|
Hall of Famer
Join Date: Apr 2007
Posts: 3,203
|
dude... whatever! there is obviously no way in hell I'm going to convince you to relax about this, so feel free to freak on it as much as you like without my assistance.
__________________
Philosophy is a battle against the bewitchment of our intelligence by means of language. -LW- |
|||||||||||||||||||||||
|
|
|
|
|
#25 | |||||||||||||||||||||||
|
All Star
Join Date: May 2004
Location: london on ca
Posts: 881
|
I'm still on 10.5, but are you saying they finally fixed this in "Snow Leopard"? That is such a relief. The most exasperating thing about arguing with the apologists on this subject was the fact that they are generally arguing without any clue whatsoever. Being unable to set them straight while having to tip-toe around the issue of the "repair permissions" flaws to avoid essentially divulging a "how to" on designing a trojan to root a Mac from the default account without a password, and trying to balance the need to educate others of the dangers without making the overall situation worse by increasing awareness of the details has been challenging. So yes, "repair permissions" in Leopard was a disaster. It refuses to unset a 'setuid' that wasn't supposed to be there. In other words, it refuses to "repair" the permissions, even though it knows they are incorrect, and in a less secure state. "Real world" outcome: People using 10.4 "repair permissions" on a Leopard machine pretty much hosed their system since the wrong files would have the 'setuid' bit set, and 10.5 wouldn't fix them. This included 'launchd', resulting in even "standard" users getting a "Finder" running as "root". Conversely, despite all of the protestations, 10.5 "repair permissions" would in fact restore the 'setuid' bit on executables even while recognizing that they have been "modified". It basically lies. Since some of those executables were in directories writable by "admin" members AND since "repair permissions" doesn't require authentication when executed from an "admin" account AND since the default account in OS X is "admin", the end result is that "root" is accessible to any process running in an "admin" account. So "repair permissons" doesn't fix what it should and fixes what it shouldn't. Earlier versions of "repair permissions" would at least fix what it should (although they were guilty of also fixing what they shouldn't). Except 10.5's version is worse -- in addition to the "admin" accessible directories, Leopard's "repair permission" also scans for 'setuid' files in world-writable directories so it's actually worse than what came before. While a standard user couldn't get "root" themselves, all they would have to do is put their own file at one of those paths and wait for the "admin" to "repair permissions" and they'd be set. Such a "standard" user, in designing a smart payload, would probably want to cover their tracks so that the SUID file "has been modified" messages don't keep popping up, but they wouldn't be able to avoid the initial SUID warning (the one that says it won't "repair" the permissions yet goes ahead to actually give the malware 'setuid' and an ownership of "root"). But thanks to TS1448, concerned users asking on a forum about this message will be told that it's safe to ignore the only warning they might actually see that their system has just been "rooted". The saddest part of all this is that MOAB was pre-Leopard and the developers were obviously working on addressing the issue (the fact that sha1 checks were implemented is an obvious clue, but also note that the permissions on the "a.receiptdb" file don't allow regular users access). But at some higher level, somebody didn't think it was important enough to let them finish, Leopard "repair permissions" has worse security flaws than what it replaced, and throughout the shipping life of Leopard, they still didn't fix it, and encouraged the proliferation of the attitude that modified setuid files aren't anything to be worried about, potentially increasing the effectiveness of anything exploiting the flaws. That's what the apologists were defending. |
|||||||||||||||||||||||
|
|
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|