Wilders Security Forums  

Go Back   Wilders Security Forums > Other Security Topics > other security issues & news
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
 
Thread Tools Search this Thread
  #1  
Old August 9th, 2009, 11:07 AM
crisp crisp is offline
Infrequent Poster
 
Join Date: Aug 2009
Posts: 5
Unhappy SRP easily bypassed :(

I've been running my XP system under a LUA with SRP for a while now, feeling nice and confident that nothing could run that hadn't been installed with my admin account.

Well it seems that was a false sense of security. You can completely bypass SRP with no password or anything.
If you have an executable that can't execute where it is because of SRP, simply using "runas /trustlevel:"Unrestricted"" will allow it to run. For example:

Code:
C:\Documents and Settings\crisp>c:\program.exe The system cannot execute the specified program. C:\Documents and Settings\crisp>runas /trustlevel:"Unrestricted" c:\program.exe

and up the program will come. You still have the protection of your LUA though so I guess thats something.
I even tried disabling the Secondary Login service, but just changing your trust level doesn't require that service and so it continues to work.

So do I need a fully fledged HIPS to achieve what I thought I had with SRP? I guess specifically blacklisting the runas program might work too.
  #2  
Old August 9th, 2009, 01:08 PM
Windchild's Avatar
Windchild Windchild is offline
Frequent Poster
 
Join Date: Jun 2009
Posts: 563
Default Re: SRP easily bypassed :(

Yeah, runas.exe does allow that mostly unknown trick. If you want to block it, the solution is quite simple: create rules that disallow runas.exe, and it can no longer be used to change trustlevel.

Still, nothing is perfect, and that applies to SRP, as well. But it's a pretty nice measure to take, and costs nothing.
__________________
Save your tears, for your tears will not save you :: Shameless LUA troll
  #3  
Old August 9th, 2009, 03:35 PM
zopzop's Avatar
zopzop zopzop is offline
Frequent Poster
 
Join Date: Apr 2006
Posts: 594
Default Re: SRP easily bypassed :(

Yeah, like wildchild said, it's nothing to worry about. You can easily add a disallow rule and the problem is solved. In fact, I had the following already blocked by SRP :
  • cscript.exe
  • wscript.exe
  • command.com
  • cmd.exe
  • regedit.exe
  • format.com
  • runas.exe
__________________
Current Security Apps -
Desktop/Laptop : SRP + LUA + KAFU, Antivir (free - on demand)

LUA+SRP+KAFU = WIN!!!111
  #4  
Old August 9th, 2009, 04:10 PM
Sully Sully is offline
Massive Poster
 
Join Date: Dec 2005
Posts: 3,696
Default Re: SRP easily bypassed :(

Rename runas.exe also is simple solution.

Sul.
  #5  
Old August 9th, 2009, 05:10 PM
crisp crisp is offline
Infrequent Poster
 
Join Date: Aug 2009
Posts: 5
Default Re: SRP easily bypassed :(

Its good to know it can be blocked; are there any other windows programs that work similar to runas that also need to be blocked?

It would be good if this was more widely known about though, seeing as not specifically adding a block rule for runas results in your SRP being easily bypassable. I can hardly find any mention of it anywhere, not even in the recommended srp guides like http://www.mechbgon.com/srp/
  #6  
Old August 10th, 2009, 03:48 AM
Windchild's Avatar
Windchild Windchild is offline
Frequent Poster
 
Join Date: Jun 2009
Posts: 563
Default Re: SRP easily bypassed :(

Quote:
Originally Posted by crisp
Its good to know it can be blocked; are there any other windows programs that work similar to runas that also need to be blocked?

It would be good if this was more widely known about though, seeing as not specifically adding a block rule for runas results in your SRP being easily bypassable. I can hardly find any mention of it anywhere, not even in the recommended srp guides like http://www.mechbgon.com/srp/

Easily bypassable, if they know about it. And a lot of people do not.

But, as far as I know, there isn't anything else that can be used to change trustlevel to bypass SRP. There are, though, other ways that might work to bypass SRP. Those range from simple things like checking to see if the limited user can write anywhere in "Unrestricted" paths (in XP, for example, Windows\Temp can be written to and one can then launch programs from there in spite of SRP, since the default rule allows everything in the Windows folder and subfolders) to more complex attack that require actually coding something.
__________________
Save your tears, for your tears will not save you :: Shameless LUA troll
  #7  
Old August 10th, 2009, 06:07 AM
crisp crisp is offline
Infrequent Poster
 
Join Date: Aug 2009
Posts: 5
Default Re: SRP easily bypassed :(

Quote:
Originally Posted by Windchild
But, as far as I know, there isn't anything else that can be used to change trustlevel to bypass SRP.

I read this: http://blog.didierstevens.com/2008/0...rp-whitelists/

It appears that you can bypass SRP without using Runas. The depressing thing about that link is it shows running an executable from within a VBA script as the example. So it seems there's no way of relying on SRP to protect you from unknown executables being run. Bummer.

I'll have to look at some of the anti executables software that's recommended on these forums, like trust-no-exe or anti-executable.
  #8  
Old August 10th, 2009, 06:40 AM
Windchild's Avatar
Windchild Windchild is offline
Frequent Poster
 
Join Date: Jun 2009
Posts: 563
Default Re: SRP easily bypassed :(

Quote:
Originally Posted by crisp
I read this: http://blog.didierstevens.com/2008/0...rp-whitelists/

It appears that you can bypass SRP without using Runas. The depressing thing about that link is it shows running an executable from within a VBA script as the example. So it seems there's no way of relying on SRP to protect you from unknown executables being run. Bummer.

I'll have to look at some of the anti executables software that's recommended on these forums, like trust-no-exe or anti-executable.

If you read that article, you'll find that it assumes that SRP is set to apply only to EXE files, not DLL libraries as well. If you apply SRP to all executable files, including libraries, then this method is no longer possible - it doesn't work.

People, try to read carefully when you read something. Otherwise, there's no point in reading.

Now, like I said, there are still other ways SRP might be bypassed. For example: http://blog.didierstevens.com/2008/0...-restrictions/ Note that this method requires you to run an untrusted Office macro. Don't run untrusted macros. Problem solved. Nothing is perfect. But in real life, SRP works very well to protect you from unknown executables running. You can choose to use third party execution prevention products if you want, but they have their own problems.
__________________
Save your tears, for your tears will not save you :: Shameless LUA troll
  #9  
Old August 10th, 2009, 02:12 PM
Mrkvonic Mrkvonic is offline
Linux Systems Expert
 
Join Date: May 2005
Posts: 7,433
Default Re: SRP easily bypassed :(

It's a local bypass and requires that you:

1) how to run that command
2) actually run the command

So, it's really nothing to worry about unless you have untrusted local users, but then, someone with local access ... game over.

Mrk
__________________
http://www.dedoimedo.com

All your base are belong to us

Linux Systems Expert / Systems Programmer, Linux System Administrator, LPIC-1, LPIC-2 (WIP), GSEC, CCHD, CCHA
 

Wilders Security Forums > Other Security Topics > other security issues & news « Previous Thread | Next Thread »

Thread Tools Search this Thread
Search this Thread:

Advanced Search

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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -4. The time now is 05:25 AM.


Powered by vBulletin® Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Copyright ©2002 - 2013, Wilders Security Forums