If you're using Harbor as your container registry, bear in mind it can be hijacked with has_admin_role = True

Patch now before miscreants sail off with your apps, data

Video IT departments using the Harbor container registry will want to update the software ASAP, following Thursday's disclosure of a bug that can be exploited by users to gain administrator privileges.

Aviv Sasson, of Palo Alto Networks' Unit 42 security team, found that under its default settings, Harbor accepts an API call that can, inadvertently, elevate a normal user's permissions. If you can reach a vulnerable Harbor installation's web interface, you can potentially pwn it.

Seeing as Harbor is used by enterprises and cloud platforms to manage collections of Docker and Kubernetes containers, which themselves contain applications and other resources, gaining administrative access is a big deal: a rogue admin can swipe data from the registry, or tamper with containers to inject malware into services.

"The attacker can download all of the private projects and inspect them. They can delete all of the images in the registry or, even worse, poison the registry by replacing its images with their own," Sasson explained. "The attacker can create a new user and set it to be admin. After that, they can connect to Harbor registry via the Docker command line tool with the new credentials and replace the current images with anything they desire."

The flaw itself is in the code behind the registry's HTTP POST-based API. Sasson discovered that a miscreant can request the creation of a new account and enable an admin for this user all at the same time. This registration request is not properly screened, and the admin account creation is approved. It is as simple as setting a flag, has_admin_role, in the request to True.

"The problem," said Sasson, "is that we can send a request and add the parameter...

"has_admin_role" = “True”

...the user that will be created will be an admin. It’s as simple as that."

Here's a video demonstrating exploitation of this programming blunder:

Youtube Video

Admins can edit the default settings to prevent this from happening, though Sasson reckons that most are unaware of that. Of a scan of 2,500 online public-facing Harbor instances, 1,300 were found to be vulnerable.

The vulnerability is designated CVE-2019-16097. Sasson and Unit 42 opted not to brand it with a cute nickname. Good on them.

The bug was found in Harbor versions 1.7.0, 1.8.2, and prior. Sysadmins can close the vulnerability by updating to versions 1.7.6, 1.8.3 and later. ®

Other stories you might like

  • Cheers ransomware hits VMware ESXi systems
    Now we can say extortionware has jumped the shark

    Another ransomware strain is targeting VMware ESXi servers, which have been the focus of extortionists and other miscreants in recent months.

    ESXi, a bare-metal hypervisor used by a broad range of organizations throughout the world, has become the target of such ransomware families as LockBit, Hive, and RansomEXX. The ubiquitous use of the technology, and the size of some companies that use it has made it an efficient way for crooks to infect large numbers of virtualized systems and connected devices and equipment, according to researchers with Trend Micro.

    "ESXi is widely used in enterprise settings for server virtualization," Trend Micro noted in a write-up this week. "It is therefore a popular target for ransomware attacks … Compromising ESXi servers has been a scheme used by some notorious cybercriminal groups because it is a means to swiftly spread the ransomware to many devices."

    Continue reading
  • Twitter founder Dorsey beats hasty retweet from the board
    As shareholders sue the social network amid Elon Musk's takeover scramble

    Twitter has officially entered the post-Dorsey age: its founder and two-time CEO's board term expired Wednesday, marking the first time the social media company hasn't had him around in some capacity.

    Jack Dorsey announced his resignation as Twitter chief exec in November 2021, and passed the baton to Parag Agrawal while remaining on the board. Now that board term has ended, and Dorsey has stepped down as expected. Agrawal has taken Dorsey's board seat; Salesforce co-CEO Bret Taylor has assumed the role of Twitter's board chair. 

    In his resignation announcement, Dorsey – who co-founded and is CEO of Block (formerly Square) – said having founders leading the companies they created can be severely limiting for an organization and can serve as a single point of failure. "I believe it's critical a company can stand on its own, free of its founder's influence or direction," Dorsey said. He didn't respond to a request for further comment today. 

    Continue reading
  • Snowflake stock drops as some top customers cut usage
    You might say its valuation is melting away

    IPO darling Snowflake's share price took a beating in an already bearish market for tech stocks after filing weaker than expected financial guidance amid a slowdown in orders from some of its largest customers.

    For its first quarter of fiscal 2023, ended April 30, Snowflake's revenue grew 85 percent year-on-year to $422.4 million. The company made an operating loss of $188.8 million, albeit down from $205.6 million a year ago.

    Although surpassing revenue expectations, the cloud-based data warehousing business saw its valuation tumble 16 percent in extended trading on Wednesday. Its stock price dived from $133 apiece to $117 in after-hours trading, and today is cruising back at $127. That stumble arrived amid a general tech stock sell-off some observers said was overdue.

    Continue reading

Biting the hand that feeds IT © 1998–2022