Feeds

US Dept for Homeland Security shafted by trivial web bug

New year resolution: Go back to PHP school

Providing a secure and efficient Helpdesk

A US government website was broken into by hackers exploiting a directory traversal vulnerability, according to security researchers.

Hacktivist group NullCrew announced it compromised studyinthestates.dhs.gov, a US Department of Homeland Security website, on Friday. The site advises foreigners seeking permission to study at American schools, colleges and universities.

The website was vulnerable to a directory traversal vulnerability, a class of bug that allows visitors to poke around a website server's file system and access sensitive files, according to Paul Ducklin of Sophos.

This particular programming flaw allowed anyone to pull up a configuration file, which included a database password, for the WordPress blogging software used by the Study in the States website. The data was then dumped onto a public Pastebin page.

"In really bad cases, attackers might even be able to hoist themselves out of your web server's directory tree altogether, and into the rest of the filing system," said Ducklin, Sophos's head of technology for Asia Pacific. "This might give them access to password and configuration files for the operating system itself, or for other software running on the same server."

Ducklin went on to detail what is believed to be the vulnerability in the DHS web code:

Poor handling of upward-leading filenames seems to have been what was wrong on the Study in the States website. It looks as though a PHP script responsible for a download repository was incautious in its argument handling. A URL of the sort: http://example.org/known/dir/download.php?file=somename.dat could be abused with a request like this: http://example.org/known/dir/download.php?file=../../private.dat

This, it seems, caused the ill-configured download script to navigate upwards in the web server's directory tree, retrieving from the inside a file that would have been blocked if it had been downloaded directly from the outside.

The fault seems to have been patched now, but if NullCrew are to be believed (and let's assume they are), this hole was used to fetch the WordPress configuration file, apparently including the backend database location and password. This configuration file was then published on a publicly available drop site.

Ducklin added that, although the directory traversal vulnerability that apparently facilitated NullCrew's hack has been plugged, other problems remain: the Study in the States website is running Apache 2.2.3 on Red Hat and PHP 5.3.3. These are not the latest version numbers for the web server and scripting language platform and thus they may need up-to-date patches, plus other sites would do well to learn lessons from the minor DHS website's mistakes, Ducklin added. ®

Choosing a cloud hosting partner with confidence

More from The Register

next story
SMASH the Bash bug! Apple and Red Hat scramble for patch batches
'Applying multiple security updates is extremely difficult'
Shellshock: 'Larger scale attack' on its way, warn securo-bods
Not just web servers under threat - though TENS of THOUSANDS have been hit
Apple's new iPhone 6 vulnerable to last year's TouchID fingerprint hack
But unsophisticated thieves need not attempt this trick
Hackers thrash Bash Shellshock bug: World races to cover hole
Update your gear now to avoid early attacks hitting the web
Oracle SHELLSHOCKER - data titan lists unpatchables
Database kingpin lists 32 products that can't be patched (yet) as GNU fixes second vuln
Who.is does the Harlem Shake
Blame it on LOLing XSS terroristas
Researchers tell black hats: 'YOU'RE SOOO PREDICTABLE'
Want to register that domain? We're way ahead of you.
prev story

Whitepapers

A strategic approach to identity relationship management
ForgeRock commissioned Forrester to evaluate companies’ IAM practices and requirements when it comes to customer-facing scenarios versus employee-facing ones.
Storage capacity and performance optimization at Mizuno USA
Mizuno USA turn to Tegile storage technology to solve both their SAN and backup issues.
High Performance for All
While HPC is not new, it has traditionally been seen as a specialist area – is it now geared up to meet more mainstream requirements?
Beginner's guide to SSL certificates
De-mystify the technology involved and give you the information you need to make the best decision when considering your online security options.
Security for virtualized datacentres
Legacy security solutions are inefficient due to the architectural differences between physical and virtual environments.