image
image

Go Back   macosx.com > Mac Help Forums > Mac OS X System & Mac Software

Reply
 
LinkBack Thread Tools
  #1  
Old May 19th, 2005, 12:17 AM
Registered User
 
Join Date: May 2005
Posts: 73
Thanks: 0
Thanked 0 Times in 0 Posts
jzdziarski is on a distinguished road
Widget Authentication Hijacking Vulnerability

I looked around and didn't see any invitation from Apple to report vulnerabilities, so for now I guess I'll post here and leave it to someone with a paid developer's account to tell them.

Date: May 19, 2005
Description: OSX 10.4 Dashboard Permits Hijacking of Authenticated Credentials

Versions Affected:
OSX 10.4.0
OSX 10.4.1

About Dashboard:
Mac OSX 10.4 includes a feature called Dashboard, which provides an environment for mini-applications, called Widgets, to run. Widgets are commonly freely available for download from a number of trusted and untrusted sources. Users running Apple's native browser, Safari, may have downloaded and installed widgets to their dashboard without even knowing it due to another security flaw.

About the Vulnerability:
Dashboard widgets allow system commands to be executed, which is normally not considered a vulnerability as they run with the user's permissions. If the user has recently authenticated to perform a super-user function, however, Dashboard widgets can hijack these credentials by calling the system's built-in "sudo" command and execute arbitrary functions with full administrative privileges. Because the sudo command trusts users based on username and tty, the widget is never prompted for a sudo password, but immediately authenticated based on the user's previous manual authentication for whatever other task they were performing. Because Dashboard widgets can be modified to run in the background, they can also sit and wait for a user to authenticate, executing malicious commands when this occurs.

Workarounds:
There is presently no workaround available other than to carefully examine new widgets and their source code prior to installation, or to avoid using the Dashboard entirely. Examining code isn't a guarantee, however, as some widgets may contain code in binary form. To prevent the auto-installation of widgets (and the potential malicious applications of this function), disable the "Open Safe Files" checkbox in Safari's General preferences.
Reply With Quote
  #2  
Old May 19th, 2005, 04:04 AM
Satcomer's Avatar
In Geostationary Orbit
 
Join Date: Jul 2002
Location: Northern Virginia
Posts: 7,117
Thanks: 34
Thanked 190 Times in 185 Posts
Satcomer is a jewel in the roughSatcomer is a jewel in the roughSatcomer is a jewel in the roughSatcomer is a jewel in the rough
Already covered here and a simple fix suggested by me.
__________________
Mac Pro Dual 2.8 Quad (1st gen), 14G Ram, Two DVD-RW Drives, OS X 10.6.2
Mac Book Pro Core 2 Duo 2.16Ghz, SuperDrive, ATI X1600, 2GB RAM, OS X 10.6.2
2TB Time Capsule
32G iPhone 3GS Black
Reply With Quote
  #3  
Old May 19th, 2005, 05:21 AM
fryke's Avatar
Super Moderator
 
Join Date: Sep 2000
Location: macosx.com
Posts: 14,084
Thanks: 13
Thanked 90 Times in 85 Posts
fryke is a jewel in the roughfryke is a jewel in the roughfryke is a jewel in the roughfryke is a jewel in the rough
If you carefully read the first post, this is different, satcomer. This is not about the automatic installing of widgets, rather it's about the user authenticating as administrator somewhere else in the system, and if that authentication is still active (hasn't timed out), and you invoke dashboard, a malicious widget could run commands on the shell as superuser.
In the really worst case, this could mean that an otherwise "good" widget (i.e. one you want to run), checks for sudo-ability in the background whenever dashboard is active, and only if it _can_ run commands as superuser, it might alter/remove/run files that only root/su should be able to run. this _is_ an issue still not solved.
__________________
iMac 24" 2.4 GHz, 4 GB RAM, 320 GB HD. Mac OS X 10.6.2
MacBook Air 13" 1.6 GHz, 2 GB RAM, 80 GB HD. Mac OS X 10.6.2
Mac mini 1.83 GHz, 2 GB RAM, 80 GB HD. Mac OS X 10.6.2
MacBook nano (Lenovo S10e white) 1.6 GHz, 2 GB RAM, 250 GB HD. Mac OS X 10.6.2
iPhone 3GS 32 GB white.

Mac user since 1987, Apple Sales Professional 2009, Apple Product Professional 2007-2009, Apple Certified Support Professional 10.5 & 10.6, Apple Certified Pro Aperture 2 (Level 1)
Reply With Quote
  #4  
Old May 19th, 2005, 06:46 AM
Tetano's Avatar
Registered User
 
Join Date: May 2004
Location: Italy
Posts: 355
Thanks: 0
Thanked 0 Times in 0 Posts
Tetano is on a distinguished road
Quote:
Originally Posted by jzdziarski
If the user has recently authenticated to perform a super-user function, however, Dashboard widgets can hijack these credentials by calling the system's built-in "sudo" command and execute arbitrary functions with full administrative privileges. Because the sudo command trusts users based on username and tty, the widget is never prompted for a sudo password, but immediately authenticated based on the user's previous manual authentication for whatever other task they were performing.
but does this phrase mean that in order to allow this vulnerability to be exploited I should have authenticated as root, or just as administrator?
__________________
iBook G3 800 MHz
384 MB SDRAM
Tiger
4G iPod, 20 GB
Reply With Quote
  #5  
Old May 19th, 2005, 08:17 AM
Registered User
 
Join Date: May 2005
Posts: 73
Thanks: 0
Thanked 0 Times in 0 Posts
jzdziarski is on a distinguished road
It appears that if you authenticate anywhere on the system using sudo, the Widget can take advantage of it. This, of course, opens the door for worms, hackers, drones, spyware, and anything else you can think of - whether the widget was auto-installed or not.

Don't feel bad Satcomer, you're not the only one who didn't read the advisory completely - I'm getting bombarded with email from people telling me this has been known about for several days. Makes me wonder if anybody reads anything these days.
Reply With Quote
  #6  
Old May 19th, 2005, 08:39 AM
Registered User
 
Join Date: May 2005
Posts: 73
Thanks: 0
Thanked 0 Times in 0 Posts
jzdziarski is on a distinguished road
Here's a workaround suggested by someone on the full disclosure list. Remove the sudo grace period by adding:

Defaults:ALL timestamp_timeout=0

To /etc/sudoers. Why this was not made the default I don't know.
Reply With Quote
  #7  
Old May 19th, 2005, 09:29 AM
lurk's Avatar
Mitä?
 
Join Date: Mar 2002
Location: Land o' skeeterz
Posts: 2,087
Thanks: 0
Thanked 0 Times in 0 Posts
lurk is on a distinguished road
Quote:
Originally Posted by jzdziarski
I looked around and didn't see any invitation from Apple to report vulnerabilities, so for now I guess I'll post here and leave it to someone with a paid developer's account to tell them.
Just a point of information. You can submit bugs with the FREE online developer membership, you do not have to pay anything.

mumble... mumble... lies... mumble... damn lies... mumble... and internet FUD...
Reply With Quote
  #8  
Old May 19th, 2005, 10:37 AM
Registered User
 
Join Date: May 2005
Posts: 73
Thanks: 0
Thanked 0 Times in 0 Posts
jzdziarski is on a distinguished road
yeah I tried that. After logging into the ADC, I tried to use the bug reporting tool. I was told I didn't have permission to access that application.

Someone gave me this url,however...

http://www.apple.com/support/security/
Reply With Quote
Reply

Bookmarks

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Weather Widget Scottfab Mac OS X System & Mac Software 2 May 17th, 2005 11:15 AM


All times are GMT -5. The time now is 09:06 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.3.2
Copyright 2000-2010 DigitalCrowd, Inc.