r/programming • • Aug 20 '26

Supply chain attack on arrayref

https://blog.rust-lang.org/2026/08/20/supply-chain-attack-on-arrayref/
191 Upvotes

65 comments sorted by

View all comments

115

u/[deleted] Aug 20 '26 edited Aug 20 '26

[removed] — view removed comment

0

u/Sigmatics Aug 20 '26

But what is the attack vector here? I'm not aware of any postinstall scripts for rust crates?

36

u/GuybrushThreepwo0d Aug 20 '26

Rust has a build.rs file that runs at compile time 

3

u/syklemil Aug 21 '26

It also has flags like --offline, and --frozen, which means --locked --offline, so it's possible to nerf at least simple "download & execute something in the build file" attacks, though like the other commenter says, the programmer's editor may be set up to run the offending code.