Security Market Segment LS
Thursday, 08 April 2021 08:43

PHP project says security hiccup likely due to leak of main database Featured

By
PHP project says security hiccup likely due to leak of main database Image by OpenClipart-Vectors from Pixabay

The PHP project has issued an update about the security problem it made public on 30 March, saying that it was now believed that the git.php.net server was not compromised.

Instead, developer Nikita Popov said in a detailed post, the issue was probably due to a leak of the master.php.net database.

As iTWire reported, the project moved its operations from its own git server to the Microsoft-owned software code repository GitHub after two malicious commits were discovered in the php-srx repository in the name of founder Rasmus Lerdorf and Popov.

PHP is a general-purpose scripting language and the most widely used on the Web, with popular content management systems like WordPress, Drupal and Joomla! all being written using it.

Popov said that master.php.net had now been moved to a new system, main.php.net. "All php.net passwords have been reset. Go to https://main.php.net/forgot.php to set a new password," he added. "git.php.net and svn.php.net are both read-only now, but will remain available for the time being."

Elaborating on what had happened, Popov said when the first malicious commit was made under Lerdorf's name, the change was reverted and commit access to Lerdorf's account revoked on the assumption that this was an individual account compromise.

"In hindsight, this action didn't really make sense, because there was (at the time) no reason to believe that the push occurred through Rasmus' account in particular," he wrote. "Any account with access to the php-src repository could have performed the push under a false name."

Once the second malicious commit was noticed, Popov said he took a close look at the logs of the project's gitolite installation to try and find out which account had been used to carry out these commits.

But while all adjacent commits were accounted for, no git-receive-pack entries were present for the two malicious commits. This was taken to mean that these two commits bypassed the gitolite infrastructure entirely and hence was interpreted as indicating a server compromise.

"Shortly after that, we made the decision to discontinue git.php.net and make GitHub our primary repository host instead. Retaining our own git infrastructure would have required setting up a new git.php.net server after determining the root cause of the compromise," Popov said.

"This would take a lot of time and disrupt PHP development in the meantime. A basic migration to GitHub could be performed much more quickly, as most repositories were already mirrored there.

"At this point, a lot of development was already going through GitHub anyway, and our own git infrastructure was mostly a security liability and complication to the development workflow, so it was not a hard decision to make the switch."

He said he was unaware at the time that git.php.net (intentionally) supported pushing changes not only via SSH (using the gitolite infrastructure and public key cryptography), but also via HTTPS.

"The latter did not use gitolite, and instead used git-http-backend behind Apache2 Digest authentication against the master.php.net user database," he said. "I'm not sure why password-based authentication was supported in the first place, as it is much less secure than pubkey authentication."

Popov provided an excerpt of the access logs, from which he said it could be determined that the commits were pushed using HTTPS and password-based authentication.

Of the commits, he observed: "It is notable that the attacker only makes a few guesses at usernames, and successfully authenticates once the correct username has been found. While we don't have any specific evidence for this, a possible explanation is that the user database of master.php.net has been leaked, although it is
unclear why the attacker would need to guess usernames in that case."

Popov said a number of changes had been made to beef up security:

  • "master.php.net was migrated to a new system (running PHP 8) and renamed to main.php.net at the same time. Among other things, the new system supports TLS 1.2, which means you should no longer see TLS version warnings when accessing this site;
  • "The implementation has been moved towards using parameterised queries, to be more confident that SQL injections cannot occur;
  • "Passwords are now stored using bcrypt; and
  • "Existing passwords were reset (use main.php.net/forgot.php to generate a new one)."
Read 1701 times

Please join our community here and become a VIP.

Subscribe to ITWIRE UPDATE Newsletter here
JOIN our iTWireTV our YouTube Community here
BACK TO LATEST NEWS here




IDC WHITE PAPER: The Business Value of Aiven Data Cloud Solutions

According to IDC, Aiven enables your teams to perform more efficiently, reduce direct infrastructure costs, and provide improved database performance, agility and scalability.

Find out how Aiven makes teams 48% more efficient, allowing staff to focus on high-value activities that drive real business results:

340% 3-year ROI – break even in 5 months (average)

37% lower 3-year cost of operations

78% reduction in staff time for database deployments


Download the IDC White Paper now

DOWNLOAD WHITE PAPER!

PROMOTE YOUR WEBINAR ON ITWIRE

It's all about Webinars.

Marketing budgets are now focused on Webinars combined with Lead Generation.

If you wish to promote a Webinar we recommend at least a 3 to 4 week campaign prior to your event.

The iTWire campaign will include extensive adverts on our News Site itwire.com and prominent Newsletter promotion https://itwire.com/itwire-update.html and Promotional News & Editorial. Plus a video interview of the key speaker on iTWire TV https://www.youtube.com/c/iTWireTV/videos which will be used in Promotional Posts on the iTWire Home Page.

Now we are coming out of Lockdown iTWire will be focussed to assisting with your webinars and campaigns and assistance via part payments and extended terms, a Webinar Business Booster Pack and other supportive programs. We can also create your adverts and written content plus coordinate your video interview.

We look forward to discussing your campaign goals with you. Please click the button below.

MORE INFO HERE!

BACK TO HOME PAGE
Sam Varghese

Sam Varghese has been writing for iTWire since 2006, a year after the site came into existence. For nearly a decade thereafter, he wrote mostly about free and open source software, based on his own use of this genre of software. Since May 2016, he has been writing across many areas of technology. He has been a journalist for nearly 40 years in India (Indian Express and Deccan Herald), the UAE (Khaleej Times) and Australia (Daily Commercial News (now defunct) and The Age). His personal blog is titled Irregular Expression.

Share News tips for the iTWire Journalists? Your tip will be anonymous

Subscribe to Newsletter

*  Enter the security code shown:

WEBINARS & EVENTS

CYBERSECURITY

PEOPLE MOVES

GUEST ARTICLES

Guest Opinion

ITWIRETV & INTERVIEWS

RESEARCH & CASE STUDIES

Channel News

Comments