Dark Reading is part of the Informa Tech Division of Informa PLC

This site is operated by a business or businesses owned by Informa PLC and all copyright resides with them.Informa PLC's registered office is 5 Howick Place, London SW1P 1WG. Registered in England and Wales. Number 8860726.

Application Security

Leaked Development Secrets a Major Issue for Repositories

Every day, more than 5,000 private keys, database connection strings, certificates, and passwords are leaked to GitHub repositories, putting applications at risk.

More than 5,000 passwords, private keys, and other development "secrets" are leaked every day when programmers push code to online repositories — a year-over-year increase of 20%  that also makes the software and the developer's infrastructure more susceptible to attack, according to a new report by security firm GitGuardian.

The company, which scans public GitHub repositories daily and analyzes the latest committed code, found that API keys for Google Cloud resources, for a variety of development tools — such as the Django web framework and Okta authentication framework — and for database access made up almost 60% of all leaked secrets. Developers from India, Brazil, and the United States most often leaked secrets, the company found.

Related Content:

Research Finds Nearly 800,000 Access Keys Exposed Online

Special Report: How IT Security Organizations Are Attacking the Cybersecurity Problem

New From The Edge: Realistic Patch Management Tips, Post-SolarWinds

Overall, while the number of leaked secrets is only about 0.2% of the public commits scanned each day, leaking an application secret can be devastating, enabling attackers to gain easy access to applications or the back-end databases, says Jeremy Thomas, CEO of GitGuardian.

"Cybersecurity is largely about human mistakes," he says. "This is still a rare event that we are preventing but a serious one, and developers have to assume that they are going to make mistakes."

Development activity on GitHub has skyrocketed in the past year, with the number of repositories jumping by 35% during the pandemic and the average active user contributing 25% more to open source projects, according to the GitHub "State of the Octoverse" report published in December. 

While companies may believe that keys leaked in open source repositories do not affect their security posture, 94% of JavaScript projects rely on open source components, as do 81% of Python projects, according to GitHub's report. 

"Open source is the connective tissue for much of the information economy," GitHub stated in the security portion of its main report. "You would be hard-pressed to find a scenario where your data does not pass through at least one open source component. Many of the services and technology we all rely on, from banking to healthcare, also rely on open source software."

In addition, GitGuardian stresses in its new report that developers often use the same account for personal development and corporate development, raising the possibility of cross-contamination in repositories. Eighty-five percent of leaked secrets occur in the personal repositories of developers, while 15% affected the public repositories owned by businesses, the company states.

"Secrets present in all these repositories can be either personal or corporate and this is where the risk lies for organizations as some of their corporate secrets are exposed publicly through their current or former developers’ personal repositories," states the report, published today.

The most common types of secrets leaked in public repositories include Google keys, which accounted for 28% of leaked secrets, development tools at 16%, and databases and data storage keys at 15%. 

Python developers most often leaked secrets, according to GitGuardians' analysis of the file extensions associated with leaked data. Python files accounted for 28% of leaks, while JavaScript accounted for 19%, and environment configuration files accounted for almost 10% of published secrets, according to the data. 

"It was a bit surprising for us as well," Thomas says. "I have no real idea why Python developers leak the most, but one reason may be, if I'm guessing, that Python is more often used on the back end, while JavaScript is used on the front end."

Back-end technology includes databases and website logic, so secrets are more common, he says.

Often developers work with code and keep keys and passwords for various resources in an insecure location to make it easier to change the code, but doing so often results in the information mistakenly being published, Thomas says. Cybercriminals and nation-state actors often scan GitHub and other repositories to find inadvertently leaked information. 

"Keeping secrets encrypted and tightly wrapped makes it harder for developers to both access and distribute them," GitGuardian states in the report. "This can lead developers to choose the path of least resistance when handling them which may include hardcoding them into source code, distributing them through email or messaging systems like Slack, saving them directly into config files and storing them inside internal wikis."

GitGuardian points to several reports of leaked secrets leading to information exposure, including a leaked JumpCloud API key that exposed Starbucks' data in 2019 and leaked credentials to a third-party data service that exposed information at Equifax in 2019.

Veteran technology journalist of more than 20 years. Former research engineer. Written for more than two dozen publications, including CNET News.com, Dark Reading, MIT's Technology Review, Popular Science, and Wired News. Five awards for journalism, including Best Deadline ... View Full Bio
 

Recommended Reading:

Comment  | 
Print  | 
More Insights
Comments
Newest First  |  Oldest First  |  Threaded View
News
US Formally Attributes SolarWinds Attack to Russian Intelligence Agency
Jai Vijayan, Contributing Writer,  4/15/2021
News
Dependency Problems Increase for Open Source Components
Robert Lemos, Contributing Writer,  4/14/2021
News
FBI Operation Remotely Removes Web Shells From Exchange Servers
Kelly Sheridan, Staff Editor, Dark Reading,  4/14/2021
Register for Dark Reading Newsletters
White Papers
Video
Cartoon Contest
Write a Caption, Win an Amazon Gift Card! Click Here
Latest Comment: click on all the semaphores 
Current Issue
2021 Top Enterprise IT Trends
We've identified the key trends that are poised to impact the IT landscape in 2021. Find out why they're important and how they will affect you today!
Flash Poll
How Enterprises are Developing Secure Applications
How Enterprises are Developing Secure Applications
Recent breaches of third-party apps are driving many organizations to think harder about the security of their off-the-shelf software as they continue to move left in secure software development practices.
Twitter Feed
Dark Reading - Bug Report
Bug Report
Enterprise Vulnerabilities
From DHS/US-CERT's National Vulnerability Database
CVE-2021-22540
PUBLISHED: 2021-04-22
Bad validation logic in the Dart SDK versions prior to 2.12.3 allow an attacker to use an XSS attack via DOM clobbering. The validation logic in dart:html for creating DOM nodes from text did not sanitize properly when it came across template tags.
CVE-2021-27736
PUBLISHED: 2021-04-22
FusionAuth fusionauth-samlv2 before 0.5.4 allows XXE attacks via a forged AuthnRequest or LogoutRequest because parseFromBytes uses javax.xml.parsers.DocumentBuilderFactory unsafely.
CVE-2021-3287
PUBLISHED: 2021-04-22
Zoho ManageEngine OpManager before 12.5.329 allows unauthenticated Remote Code Execution due to a general bypass in the deserialization class.
CVE-2021-31547
PUBLISHED: 2021-04-22
An issue was discovered in the AbuseFilter extension for MediaWiki through 1.35.2. Its AbuseFilterCheckMatch API reveals suppressed edits and usernames to unprivileged users through the iteration of crafted AbuseFilter rules.
CVE-2021-31548
PUBLISHED: 2021-04-22
An issue was discovered in the AbuseFilter extension for MediaWiki through 1.35.2. A MediaWiki user who is partially blocked or was unsuccessfully blocked could bypass AbuseFilter and have their edits completed.