Okla. agency site plugs coding error that left data exposed
Data had been left vulnerable for three years
Computerworld - It's rare that someone looking to steal personal data from a Web site need only submit their own SQL query to pull the data of his choice from the underlying database.
But for the past three years -- until this week -- that's just what anyone with a basic knowledge of SQL could do while visiting the Oklahoma Department of Corrections Web site.
That's according to security blogger Alex Papadimoulis, who earlier this week wrote about how he had exploited a fundamental programming error on the site to download more than 10,500 records with Social Security numbers. The records involved people listed in the Oklahoma's Sexual and Violent Offender Registry.
Also exposed were records containing Social Security numbers and personal data on other types of offenders, as well as employees working at the department.
In an interview, Papadimoulis said the coding error, which now appears to have been fixed, affected the search pages of the Sexual and Violent Offender Registry and the General Offender registry. "The main problem was that the URL contained the computer code required to display data on the page, which is a big vulnerability," he said. "Anybody could change the code and have the page display whatever he would like it to display."
Papadimoulis posted screenshots of the records he had captured to prove his point.
Papadimoulis said it took less than a minute for him to figure out how to modify the code to download records containing data from the site. Instead of validating the request or even considering the user input, the site was designed to blindly execute whatever code a user might tell it to execute, he said. "This is the most extreme case of not validating user input. It really is the most basic of errors," he said.
According to Papadimoulis, the flaw allowed anyone to craft queries to access data in the offender databases as well as from other data stores they might be linked to. It could have even allowed for records to be modified, deleted or added. "I didn't try that," he said. "What I did was I told them this was really, really bad."
The first attempt at fixing the issue was not very successful, Papadimoulis noted in his blog. "Their brilliant developers plugged this pothole with a pebble by doing nothing more than a case-sensitive search/replace of 'social_security_number' with 'doc_number,'" Papadimoulis said.
When Papadimoulis again demonstrated how that fix did little to alleviate the problem, Oklahoma Department of Corrections officials finally pulled the site down for maintenance and corrected the issue.
Jerry Massie, public information officer for the agency, today confirmed the flaw and said it has been fixed. "[Papadimoulis] notified us on Thursday evening that he had been able to manipulate the database," Massie said. "There was a weakness in the application." He did not elaborate further.
Massie noted that the records in the sex offender database were all public records anyway, and that the only protected information involved the Social Security numbers.
"We shut the site down on Friday and put in a fix that we thought would work," Massie said.
Papadimoulis noted that the Oklahoma Department of Corrections has put out a request for proposals (download PDF) for consulting services interested in helping the agency acquire a new offender management system. He added that it is not clear whether that move is related to the recently disclosed breach. Massie was unable to clarify that as well.
The request for proposals is dated April 4, one day after Papadimoulis pointed out the problem to the department.
Read more about Security in Computerworld's Security Topic Center.



- Excel 2010 Cheat Sheet
- Register for this Computerworld Insider Cheat Sheet and gain access to hundreds of premium content articles, guides, product reviews and more.
- Overcome Top 7 Admin Challenges of Active Directory
- As Active Directory's role in the enterprise has drastically increased, so has the need to secure the data. Gain insight on creating repeatable,...
- Insiders Can Ruin Your Company. Take Action.
- Did you know that 80 percent of threats to an organization come from the inside? The threat from insiders is often overlooked in...
- Top Solutions and Tools to Prevent Devastating Malware
- Custom malware frequently goes undetected. According to Forrester Research, the best way to reduce risk of breach is to deploy file integrity monitoring...
- X-Ray of the PCI Process-4 Proactive Steps
- This white paper from Forrester Research Inc., helps break PCI into understandable components. Security and risk professionals will gain knowledge and insight into...
- Identity Governance: The Business Imperatives
- This white paper describes the business challenges and opportunities that are driving interest in Identity Governance while discussing considerations your organization should make... All Security White Papers
- Live Webcast
Playing Defense: Staying on Top of Your Disaster Recovery Game - When it comes to disaster recovery, rapidly growing data volumes, distributed computing models, and new technologies all combine to present an ever-changing playing...
- Introduction to VMware vCenter Site Recovery Manager 5
- Traditional disaster recovery solutions are often too expensive, complex and unreliable to meet business requirements. As a result, IT departments are hesitant to...
- The Top Ten Secrets to Avoiding SAN Performance Problems
- Maintaining peak performance while simultaneously addressing the root cause of SAN errors is challenging. Learn the most common SAN problems and explore new...
- Deduplication Without Compromise
- Go inside Quantum's scalable, high-performance, multi-protocol new DXi deduplication appliances, designed to make backup much more effective. Discover how the new future-proof DXi6700...
- Director of Disk Products Discusses DXi6700
- Discover how the new DXi 6700 series of deduplication appliances provide investment protection and a future-proof feature set, all while delivering fast, scalable,...
- Playing Defense: Staying on Top of Your Disaster Recovery Game
- When it comes to disaster recovery, rapidly growing data volumes, distributed computing models, and new technologies all combine to present an ever-changing playing... All Security Webcasts