![]() |
|
![]() |
|
I don't think PowerShell is a big improvement, though. Still allows no signature checking of functions. Shells are optimized for fast entry, not for writing comprehensible (or even secure) programs.
|
![]() |
|
Conan is a package manager for C/C++, written in Python. See: https://conan.io/. The way it works is that you can provide "recipes", which are Python scripts, that automate the process of collecting source code (usually from a remote Git repository, or a remote source tarball), patching it, making its dependencies and transitive dependencies available, building for specific platform and architecture (via any number of build systems), then packaging up and serving binaries. There's a lot of complexity involved. Here are the two recipes I mentioned: libcurl: https://github.com/conan-io/conan-center-index/blob/master/r... OpenSSL v3: https://github.com/conan-io/conan-center-index/blob/master/r... Now, for the sake of this thread I want to highlight three things here: - Conan recipes are usually made by people unaffiliated with the libraries they're packaging; - The recipes are fully Turing-complete, do a lot of work, have their own bugs - therefore they should really be treated as software comonents themselves, for the purpose of OSS clearing/supply chain verification, except as far as I know, nobody does it; - The recipes can, and do, patch source code and build scripts. There's supporting infrastruture for this built into Conan, and of course one can also do it by brute-force search and replace. See e.g. ZLib recipe that does it both at the same time: https://github.com/conan-io/conan-center-index/blob/7b0ac710... -- `_patch_sources` does both direct search-and-replace in source files, and applies the patches from https://github.com/conan-io/conan-center-index/tree/master/r.... Good luck keeping track of what exact code goes into your program, when using Turing-complete "recipe" programs fetched from the Internet, which fetch your libraries from somewhere else on the Internet. |
![]() |
|
or make.go, for some project it makes sense to not add another language for scripting and building tasks. It way easier for every one to have to master multiple language.
|
![]() |
|
> Blaming this on bash is like a smith blaming a hammer failing on a carpenter's shoddy haft... Not terribly convincing. If your hammer is repurposed shoe, it's fair to blame the tools. |
![]() |
|
Python makes it relatively hard to write inscrutable code, and more importantly, it's very non-idiomatic, and there would be pushback. WTFing at shell scripts is normal. |
![]() |
|
Where are you going to hide your monkey patching though? As long as your code is public, stuff like this is always going to stand out, because no one writes weird magic one liners in python.
|
![]() |
|
There are lints that will warn you, if your imported module does anything apart from define functions and classes. (Though not sure how fool-proof these are.) |
![]() |
|
Just wait for AI to start pumping spaghetti code everywhere. That's AI phase one Hey, I phase 2 is even better disguised exploit code hiding behind acres of seemingly plausible AI generated code |
![]() |
|
Yet it is python code which has the highest amount of security vulnerabilities found in public repos. And the most often times that pre-compiled code is commited as well.
|
![]() |
|
Some languages make you try harder, some less so. And not all languages are Turing complete in the first place. Not even all useful languages. |
![]() |
|
Every time someone explains to me autotools, the individual pieces sort of make sense, yet the result is always this inscrutable unreadable mess. I don't know why. |
![]() |
|
So if you ran build without test files it would fail. I get that this is hindsight thinking - but maybe removing all non essential files when packaging/building libraries reduces the surface area.
|
![]() |
|
Let me reword that for you: >No one has any business saying they know what something does until they've actually read it. Beneath the placid surface of abstraction is the den of the devil. |
![]() |
|
The devil is in the detail and nothing obscures details like complexity. Same reason why I don't like TypeScript in its current form. It's not worth the extra complexity it brings. |
![]() |
|
The distributions often run the same tests after it’s built to make sure it’s working correctly as built in the distribution environment. This can and does find real problems.
|
![]() |
|
Besides for verifying that the compiled program works on the target, tests are also required to compile with PGO because you need to have a runtime example to optimize for.
|
![]() |
|
Because, despite containing some amount of generated autoconf code, they are still source tarballs. You want to be able to run the tests after compiling the code on the destination machine.
|
![]() |
|
Hi, I'm the author of such PR. My purpose was to trim down the size of the initram files by removing unneeded dependencies. I couldn't imagine that liblzma had a backdoor. |
![]() |
|
There were also changes to systemd happening around that time which would have prevented the backdoor from working. See the timeline article by the same author linked in this one.
|
![]() |
|
Can it be to enlarge/or obfuscate parts of the compressed test file? Perhaps without the repetitions the compressed file has some strange binary triggering some security or antivirus software?
|
![]() |
|
IFUNC is supported on several architectures, including ARM64. The malicious code that the xz backdoor inserts into the library is a compiled x86_64 object file so it only is targeting one platform. |
![]() |
|
Who designates it as critical? If someone makes a library and other people start using it, are they forced to reveal their identity? Do the maintainers get paid? |
![]() |
|
Right, we don’t know that, but we have yet to hear of one case where a supply chain attack on a FOSS project resulted in someone getting arrested.
|
![]() |
|
face to face, background checks. they are all superficial. A smooth talker can get you to relax your guard. Identity can be faked, especially if you have a nation state backing you. |
![]() |
|
On open source projects you can vet people based on whether you can personally identify them as real people. Moving forward be suspicious of anonymity for core contributions.
|
![]() |
|
It's kind of tragically amusing how heinously complex and unnecessarily inscrutable modern technology is, and it's only getting worse. I think developers sadistically enjoy it.
|
![]() |
|
Imagine paying for a security scanning service such as Snyk and finding that it never scanned source code for injection attacks. How many millions of dollars went down the drain?
|
![]() |
|
> The internal build tool is Blaze (Bazel is the open-source cousin). I was under the impression that Blaze is Google's Bazel deployment, i.e. that they're the same code. Is that not correct? |
![]() |
|
Ugly and broken build systems are most of the reason why Gentoo's 'sandbox' feature and equivalent for other distributions exists.[1] These sandboxing features have mostly been used in the past to prevent an ugly shell script in the build process for libuselesscruft from doing something similar to "rm -rf" on the build system. More recently these sandboxing features are helpful in encouraging reproducible builds by alerting maintainers to build processes which try and obtain non-deterministic information from the operating system environment such as the operating system name and version, host name and current time stamp. There are a few gaps I think xz-utils highlights: - Repositories containing a mixture of source code, build scripts, test frameworks, static resources and documentation generation scripts are all considered to be a single security domain with no isolation between them. If you look to Gentoo's src_prepare function as an example, we perhaps should instead split this into build_src_prepare, doc_src_prepare, test_src_prepare and install_src_prepare instead. If source code is being built and binaries generated, the sandboxed build directory should perhaps not contain test files and documentation generation scripts. If the package is being installed with "make install" (or equivalent) then static resources (such as a timezone database) should be available to copy to /usr/, but build scripts used to generate the binaries or documentation do not need to be available to "make install" (or equivalent). - Sandboxing used for package building hasn't traditionally been implemented for security reasons in the past. Sandboxing should perhaps be hardened further with modern and more complex approaches such as seccomp to further protect build systems from the likes of libbackdoored that are targeted towards package maintainers/Linux distribution build systems. As a further example to seccomp, Gentoo's 'sandbox' has Linux namespace isolation built in, but not yet enabled whilst it is tested. - There is a lack of automated package management tools (including dashboards / automatic bug creation) for comparing source trees in Git to released tarballs and making discrepancies more visible and easier for maintainers to review. - There is a lack of automatic package management tools (including dashboards / automatic bug creation) for detecting binary and high entropy files in source trees and confirming they are validly formatted (e.g. invalid tag in a TLV file format) and confirming that test and example files contain nothing-up-my-sleeve content. There has already been an accelerated move in recent years towards modern and safer build systems (such as meson and cargo) as 80's/90's C libraries get ripped out and replaced with modern Rust libraries, or other safer options. This is a lot of work that will take many years though, and many old 80's/90's C libraries and build systems will be needed for many more years to come. And for this reason, sandboxing/isolation/safety of old build systems seemingly needs to be improved as a priority, noting that old build systems will take years or decades to replace. [1] https://devmanual.gentoo.org/general-concepts/sandbox/index.... [2] https://devmanual.gentoo.org/ebuild-writing/functions/src_pr... |
![]() |
|
Google gets to decide what platform they want to support for their backend. I wonder what their build code would look like if they tried to support the top-10 common OS from the last 30 years.
|
![]() |
|
Read IOCCC entries. Now realize, those are people having FUN. What is your chance of catching nation state level maliciousness in a codebase? Pretty low. |
![]() |
|
Others have answered your question about APT but FWIW I don't understand the downvotes. You were respectful and simply sought to clear up a misunderstanding.
|
I worry about all the con/pro-sumer hardware makers, from Philips Hue to Alexas, from the SumUps to the camera makers, from Netgear to TP-Link. All their products are packed with open-source libraries. And I am 100% certain that most of their dev teams do not spend time scanning these for obscure injection vectors.