Rogue PyPI Library Solana Users, Steals Blockchain Wallet Keys

Share:

Cybersecurity researchers have discovered a new malicious package on the Python Package Index (PyPI) repository that masquerades as a library from the Solana blockchain platform but is actually designed to steal victims’ secrets.

“The legitimate Solana Python API project is known as ‘solana-py’ on GitHub, but simply ‘solana’ on the Python software registry, PyPI,” Sonatype researcher Ax Sharma said in a report published last week. “This slight naming discrepancy has been leveraged by a threat actor who published a ‘solana-py’ project on PyPI.”

The malicious “solana-py” package attracted a total of 1,122 downloads since it was published on August 4, 2024. It’s no longer available for download from PyPI.

The most striking aspect of the library is that it carried the version numbers 0.34.3, 0.34.4, and 0.34.5. The latest version of the legitimate “solana” package is 0.34.3. This clearly indicates an attempt on the part of the threat actor to trick users looking for “solana” into inadvertently downloading “solana-py” instead.

What’s more, the rogue package borrows the real code from its counterpart, but injects additional code in the “__init__.py” script that’s responsible for harvesting Solana blockchain wallet keys from the system.

This information is then exfiltrated to a Hugging Face Spaces domain operated by the threat actor (“treeprime-gen.hf[.]space”), once again underscoring how threat actors are abusing legitimate services for malicious purposes.

The attack campaign poses a supply chain risk in that Sonatype’s investigation found that legitimate libraries like “solders” make references to “solana-py” in their PyPI documentation, leading to a scenario where developers could have mistakenly downloaded “solana-py” from PyPI and broadened the attack surface.

“In other words, if a developer using the legitimate ‘solders’ PyPI package in their application is mislead (by solders’ documentation) to fall for the typosquatted ‘solana-py’ project, they’d inadvertently introduce a crypto stealer into their application,” Sharma explained.

“This would not only steal their secrets, but those of any user running the developer’s application.”

The disclosure comes as Phylum said it identified hundreds of thousands of spam npm packages on the registry containing markers of Tea protocol abuse, a campaign that first came to light in April 2024.

“The Tea protocol project is taking steps to remediate this problem,” the supply chain security firm said. “It would be unfair to legitimate participants in the Tea protocol to have their remuneration reduced because others are scamming the system. Also, npm has begun to take down some of these spammers, but the takedown rate does not match the new publication rate.”

Ravie Lakshmanan

Leave a Comment

Your email address will not be published. Required fields are marked *

loader-image
London, GB
12:12 pm, Jun 29, 2025
weather icon 26°C
L: 24° | H: 28°
scattered clouds
Humidity: 61 %
Pressure: 1025 mb
Wind: 2 mph
Wind Gust: 0 mph
UV Index: 0
Precipitation: 0 mm
Clouds: 34%
Rain Chance: 0%
Visibility: 10 km
Sunrise: 4:46 am
Sunset: 9:21 pm
DailyHourly
Daily ForecastHourly Forecast
Today 10:00 pm
weather icon
24° | 28°°C 0 mm 0% 5 mph 60 % 1025 mb 0 mm/h
Tomorrow 10:00 pm
weather icon
20° | 35°°C 0 mm 0% 8 mph 71 % 1021 mb 0 mm/h
Tue Jul 01 10:00 pm
weather icon
22° | 33°°C 0 mm 0% 12 mph 70 % 1017 mb 0 mm/h
Wed Jul 02 10:00 pm
weather icon
16° | 22°°C 1 mm 100% 11 mph 94 % 1017 mb 0 mm/h
Thu Jul 03 10:00 pm
weather icon
14° | 20°°C 1 mm 100% 12 mph 95 % 1026 mb 0 mm/h
Today 1:00 pm
weather icon
25° | 26°°C 0 mm 0% 5 mph 60 % 1025 mb 0 mm/h
Today 4:00 pm
weather icon
27° | 29°°C 0 mm 0% 3 mph 53 % 1024 mb 0 mm/h
Today 7:00 pm
weather icon
27° | 27°°C 0 mm 0% 4 mph 42 % 1022 mb 0 mm/h
Today 10:00 pm
weather icon
22° | 22°°C 0 mm 0% 3 mph 54 % 1021 mb 0 mm/h
Tomorrow 1:00 am
weather icon
21° | 21°°C 0 mm 0% 3 mph 65 % 1021 mb 0 mm/h
Tomorrow 4:00 am
weather icon
20° | 20°°C 0 mm 0% 4 mph 71 % 1020 mb 0 mm/h
Tomorrow 7:00 am
weather icon
22° | 22°°C 0 mm 0% 4 mph 62 % 1020 mb 0 mm/h
Tomorrow 10:00 am
weather icon
28° | 28°°C 0 mm 0% 5 mph 43 % 1019 mb 0 mm/h
Name Price24H (%)
Bitcoin(BTC)
€92,299.18
0.83%
Ethereum(ETH)
€2,096.05
1.22%
Tether(USDT)
€0.85
0.00%
XRP(XRP)
€1.87
0.08%
Solana(SOL)
€129.12
2.89%
USDC(USDC)
€0.85
0.00%
Dogecoin(DOGE)
€0.140257
1.03%
Shiba Inu(SHIB)
€0.000010
1.75%
Pepe(PEPE)
€0.000009
1.77%
Scroll to Top